NoSuchElementException when querying multiple ES indexes

Hi,

My ES version is 6.8.3, Dremio version is 4.0.0-201909121834570395-c7a5071.

I have daily indexes that I try to query on using a wildcard but get “NoSuchElementException”.

The indexes looks like this:

ES.“x_events_y-2019.07.12”.“log”
ES.“x_events_y-2019.07.13”.“log”

The query that fails:

select * from ES.“x_events_y-*”.“log” limit 1;

Thanks,
Yoav

@yoav2020

Kindly share the job profile

Share Dremio Query Profile

Thanks
@balaji.ramaswamy

Attached.

Thank!

DremioProfile.zip (4.4 KB)

Hey Balaji

Did you have a chance to look into in our profile?

thanks
Yoav

Hey @balaji.ramaswamy,
I am having the same issue and also didn’t got response in my thread,
can you please assist to find the issue?
Thanks!

@YakobovLior @yoav2020

Looks like a condition we are not handling. Will work with our engineering team and provide an update

Hello @balaji.ramaswamy

any updates regarding this issue?

Thank you,
Lior

Same issue here. Interesting thing that It all works on es 6.8.6 running on Elastic Cloud, but not works on the local 6.8.6 docker installation. I’ve tested it on different es versions and it looks like this error starts from 6.7.0.
This log may help to fix the issue:
e[36mdremio_1 |e[0m com.dremio.common.exceptions.UserException: NoSuchElementException
e[36mdremio_1 |e[0m at com.dremio.common.exceptions.UserException$Builder.build(UserException.java:776) ~[dremio-common-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.planner.sql.SqlExceptionHelper.coerceException(SqlExceptionHelper.java:114) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.planner.sql.handlers.query.NormalHandler.getPlan(NormalHandler.java:60) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.planner.sql.handlers.commands.HandlerToExec.plan(HandlerToExec.java:70) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.work.foreman.AttemptManager.plan(AttemptManager.java:415) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.work.foreman.AttemptManager.lambda$run$0(AttemptManager.java:324) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.service.commandpool.CommandWrapper.run(CommandWrapper.java:62) ~[dremio-services-commandpool-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [na:1.8.0_232]
e[36mdremio_1 |e[0m at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [na:1.8.0_232]
e[36mdremio_1 |e[0m at java.lang.Thread.run(Thread.java:748) [na:1.8.0_232]
e[36mdremio_1 |e[0m Caused by: java.util.NoSuchElementException: null
e[36mdremio_1 |e[0m at com.google.gson.internal.LinkedTreeMap$LinkedTreeMapIterator.nextNode(LinkedTreeMap.java:538) ~[gson-2.2.4.jar:na]
e[36mdremio_1 |e[0m at com.google.gson.internal.LinkedTreeMap$EntrySet$1.next(LinkedTreeMap.java:565) ~[gson-2.2.4.jar:na]
e[36mdremio_1 |e[0m at com.google.gson.internal.LinkedTreeMap$EntrySet$1.next(LinkedTreeMap.java:563) ~[gson-2.2.4.jar:na]
e[36mdremio_1 |e[0m at com.dremio.plugins.elastic.ElasticDatasetMetadata.getAliasFilter(ElasticDatasetMetadata.java:203) ~[dremio-elasticsearch-plugin-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.plugins.elastic.ElasticDatasetMetadata.getAliasFilter(ElasticDatasetMetadata.java:177) ~[dremio-elasticsearch-plugin-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.plugins.elastic.ElasticDatasetMetadata.build(ElasticDatasetMetadata.java:107) ~[dremio-elasticsearch-plugin-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.plugins.elastic.ElasticsearchStoragePlugin.getDatasetMetadata(ElasticsearchStoragePlugin.java:369) ~[dremio-elasticsearch-plugin-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.DatasetSaver.save(DatasetSaver.java:110) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.DatasetSaver.save(DatasetSaver.java:154) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.DatasetManager.getTableFromPlugin(DatasetManager.java:349) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.DatasetManager.getTable(DatasetManager.java:209) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.CatalogImpl.getTable(CatalogImpl.java:130) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.SourceAccessChecker.lambda$getTable$3(SourceAccessChecker.java:103) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.SourceAccessChecker.checkAndGetTable(SourceAccessChecker.java:82) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.SourceAccessChecker.getTable(SourceAccessChecker.java:103) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.DelegatingCatalog.getTable(DelegatingCatalog.java:66) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.CachingCatalog.getTable(CachingCatalog.java:93) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.DremioCatalogReader.getTable(DremioCatalogReader.java:94) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.catalog.DremioCatalogReader.getTable(DremioCatalogReader.java:71) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.EmptyScope.getTableNamespace(EmptyScope.java:76) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.DelegatingScope.getTableNamespace(DelegatingScope.java:197) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.IdentifierNamespace.resolveImpl(IdentifierNamespace.java:102) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.IdentifierNamespace.validateImpl(IdentifierNamespace.java:120) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.AbstractNamespace.validate(AbstractNamespace.java:84) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.SqlValidatorImpl.validateNamespace(SqlValidatorImpl.java:943) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.SqlValidatorImpl.validateQuery(SqlValidatorImpl.java:924) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.SqlValidatorImpl.validateFrom(SqlValidatorImpl.java:2971) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.SqlValidatorImpl.validateFrom(SqlValidatorImpl.java:2956) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.SqlValidatorImpl.validateSelect(SqlValidatorImpl.java:3197) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.SelectNamespace.validateImpl(SelectNamespace.java:60) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.AbstractNamespace.validate(AbstractNamespace.java:84) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.SqlValidatorImpl.validateNamespace(SqlValidatorImpl.java:943) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.SqlValidatorImpl.validateQuery(SqlValidatorImpl.java:924) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.SqlSelect.validate(SqlSelect.java:226) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.SqlValidatorImpl.validateScopedExpression(SqlValidatorImpl.java:899) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at org.apache.calcite.sql.validate.SqlValidatorImpl.validate(SqlValidatorImpl.java:609) ~[calcite-core-1.16.0-201909031936280585-3f76472.jar:1.16.0-201909031936280585-3f76472]
e[36mdremio_1 |e[0m at com.dremio.exec.planner.sql.SqlConverter.validate(SqlConverter.java:229) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.planner.sql.handlers.PrelTransformer.validateNode(PrelTransformer.java:184) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.planner.sql.handlers.PrelTransformer.validateAndConvert(PrelTransformer.java:173) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.planner.sql.handlers.PrelTransformer.validateAndConvert(PrelTransformer.java:169) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m at com.dremio.exec.planner.sql.handlers.query.NormalHandler.getPlan(NormalHandler.java:43) ~[dremio-sabot-kernel-4.1.3-202001022113020736-53142377.jar:4.1.3-202001022113020736-53142377]
e[36mdremio_1 |e[0m … 7 common frames omitted
e[36mdremio_1 |e[0m 2020-01-17 12:38:18,063 [out-of-band-observer] INFO query.logger - {“queryId”:“21de5547-b220-4043-d601-23fd1a899500”,“schema”:"[es]",“queryText”:“select * from es.“filebeat*”.doc”,“start”:1579264695253,“finish”:1579264698044,“outcome”:“FAILED”,“username”:“root”}