add continue in try-catch of createIndexRequest exception and move vars into loop