
When querying against Elasticsearch 6, gerrit uses the following URLs: http://elasticsearch:9200/gerrit_accounts_0010/accounts/_search http://elasticsearch:9200/gerrit_groups_0007/groups/_search whereas it should use: http://elasticsearch:9200/gerrit_accounts_0010/_doc/_search http://elasticsearch:9200/gerrit_groups_0007/_doc/_search The type is properly resolved through the index adapter, so use that to build the ElasticQuerySource instead of using hard coded constants for both accounts and groups indexes. Bug: Issue 10591 Change-Id: I90cd74da9246f56bc9b2ef8464587ab04152876b Signed-off-by: Jacek Centkowski <jcentkowski@collab.net>