Is there any known performance concern for query that spans multiple indexes?

I am considering creating a query that involves terms across two indexes in ElasticSearch. Is there any known performance concern for doing so?

For example, index1: termx. index2: terma

{
"indices" : {
"indices" : ["index1", "index2"],
"query" : {
"constant_score" : {
"filter" : {
"bool" : {
"must" : {
"term" : {"termx" : "100x600"}
},
"must" : {
"term" : {"terma" : "xyz"}
}
}
}
}
}
}
}

Would this work?

Thanks,
Connie

It would work, but it would be more efficient to just send this request to
two indices by specifying these indices explicitly on URL if you are using
REST API, or as indices parameter if you are using Java API:

curl localhost:9200/index1,index2/_search -d '{
"constant_score" : {
"filter" : {
"bool" : {
"must" : {
"term" : {"termx" : "100x600"}
},
"must" : {
"term" : {"terma" : "xyz"}
}
}
}
}
}'

On Tuesday, April 23, 2013 11:50:25 PM UTC+2, Connie Yang wrote:

I am considering creating a query that involves terms across two indexes
in
ElasticSearch. Is there any known performance concern for doing so?

For example, index1: termx. index2: terma

{
"indices" : {
"indices" : ["index1", "index2"],
"query" : {
"constant_score" : {
"filter" : {
"bool" : {
"must" : {
"term" : {"termx" : "100x600"}
},
"must" : {
"term" : {"terma" : "xyz"}
}
}
}
}
}
}
}

Would this work?

Thanks,
Connie

--
View this message in context:
http://elasticsearch-users.115913.n3.nabble.com/Is-there-any-known-performance-concern-for-query-that-spans-multiple-indexes-tp4033769.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Thanks Igor!

Just to be sure, the query should work even if tese two indices are of two
different types.

The attempt here is to find document primarily from index a based on a
condition that exists in both indices.

Connie
On Apr 24, 2013 1:48 AM, "Igor Motov-3 [via ElasticSearch Users]" <
ml-node+s115913n4033784h87@n3.nabble.com> wrote:

It would work, but it would be more efficient to just send this request to
two indices by specifying these indices explicitly on URL if you are using
REST API, or as indices parameter if you are using Java API:

curl localhost:9200/index1,index2/_search -d '{
"constant_score" : {
"filter" : {
"bool" : {
"must" : {
"term" : {"termx" : "100x600"}
},
"must" : {
"term" : {"terma" : "xyz"}
}
}
}
}
}'

On Tuesday, April 23, 2013 11:50:25 PM UTC+2, Connie Yang wrote:

I am considering creating a query that involves terms across two indexes
in
ElasticSearch. Is there any known performance concern for doing so?

For example, index1: termx. index2: terma

{
"indices" : {
"indices" : ["index1", "index2"],
"query" : {
"constant_score" : {
"filter" : {
"bool" : {
"must" : {
"term" : {"termx" : "100x600"}
},
"must" : {
"term" : {"terma" : "xyz"}
}
}
}
}
}
}
}

Would this work?

Thanks,
Connie

--
View this message in context: http://elasticsearch-users.**
115913.n3.nabble.com/Is-there-any-known-performance-concern-
for-query-that-spans-multiple-**indexes-tp4033769.htmlhttp://elasticsearch-users.115913.n3.nabble.com/Is-there-any-known-performance-concern-for-query-that-spans-multiple-indexes-tp4033769.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to [hidden email]http://user/SendEmail.jtp?type=node&node=4033784&i=0
.
For more options, visit https://groups.google.com/groups/opt_out.


If you reply to this email, your message will be added to the discussion
below:

http://elasticsearch-users.115913.n3.nabble.com/Is-there-any-known-performance-concern-for-query-that-spans-multiple-indexes-tp4033769p4033784.html
To start a new topic under ElasticSearch Users, email
ml-node+s115913n115913h86@n3.nabble.com
To unsubscribe from Is there any known performance concern for query that
spans multiple indexes?, click herehttp://elasticsearch-users.115913.n3.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=4033769&code=Y3liZXJjb25uaWVAZ21haWwuY29tfDQwMzM3Njl8LTIxMjk4ODk4MTQ=
.
NAMLhttp://elasticsearch-users.115913.n3.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html!nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers!nabble%3Aemail.naml-instant_emails!nabble%3Aemail.naml-send_instant_email!nabble%3Aemail.naml

Yes, these indices don't have to have the same mapping.

On Wednesday, April 24, 2013 3:50:41 PM UTC+2, Connie Yang wrote:

Thanks Igor!

Just to be sure, the query should work even if tese two indices are of two
different types.

The attempt here is to find document primarily from index a based on a
condition that exists in both indices.

Connie
On Apr 24, 2013 1:48 AM, "Igor Motov-3 [via ElasticSearch Users]" <[hidden
email] http://user/SendEmail.jtp?type=node&node=4033797&i=0> wrote:

It would work, but it would be more efficient to just send this request
to two indices by specifying these indices explicitly on URL if you are
using REST API, or as indices parameter if you are using Java API:

curl localhost:9200/index1,index2/_search -d '{
"constant_score" : {
"filter" : {
"bool" : {
"must" : {
"term" : {"termx" : "100x600"}
},
"must" : {
"term" : {"terma" : "xyz"}
}
}
}
}
}'

On Tuesday, April 23, 2013 11:50:25 PM UTC+2, Connie Yang wrote: I am
considering creating a query that involves terms across two indexes in
ElasticSearch. Is there any known performance concern for doing so?

For example, index1: termx. index2: terma

{
"indices" : {
"indices" : ["index1", "index2"],
"query" : {
"constant_score" : {
"filter" : {
"bool" : {
"must" : {
"term" : {"termx" : "100x600"}
},
"must" : {
"term" : {"terma" : "xyz"}
}
}
}
}
}
}
}

Would this work?

Thanks,
Connie

--
View this message in context: http://elasticsearch-users.**
115913.n3.nabble.com/Is-there-any-known-performance-concern-
for-query-that-spans-multiple-**indexes-tp4033769.htmlhttp://elasticsearch-users.115913.n3.nabble.com/Is-there-any-known-performance-concern-for-query-that-spans-multiple-indexes-tp4033769.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to [hidden email]http://user/SendEmail.jtp?type=node&node=4033784&i=0
.
For more options, visit https://groups.google.com/groups/opt_out.


If you reply to this email, your message will be added to the discussion
below:

http://elasticsearch-users.115913.n3.nabble.com/Is-there-any-known-performance-concern-for-query-that-spans-multiple-indexes-tp4033769p4033784.html
To start a new topic under ElasticSearch Users, email [hidden email]http://user/SendEmail.jtp?type=node&node=4033797&i=1
To unsubscribe from Is there any known performance concern for query that
spans multiple indexes?, click here.
NAMLhttp://elasticsearch-users.115913.n3.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html!nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers!nabble%3Aemail.naml-instant_emails!nabble%3Aemail.naml-send_instant_email!nabble%3Aemail.naml


View this message in context: Re: Is there any known performance concern
for query that spans multiple indexes?http://elasticsearch-users.115913.n3.nabble.com/Is-there-any-known-performance-concern-for-query-that-spans-multiple-indexes-tp4033769p4033797.html
Sent from the ElasticSearch Users mailing list archivehttp://elasticsearch-users.115913.n3.nabble.com/at Nabble.com.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.