fetching a shape should not occur on separate thread

This commit is contained in:
Shay Banon 2012-09-26 23:47:27 +02:00
parent cfe7504d1c
commit 15453272f7
1 changed files with 1 additions and 1 deletions

View File

@ -58,7 +58,7 @@ public class ShapeFetchService extends AbstractComponent {
* @throws IOException Can be thrown while parsing the Shape Document and extracting the Shape * @throws IOException Can be thrown while parsing the Shape Document and extracting the Shape
*/ */
public Shape fetch(String id, String type, String index, String shapeField) throws IOException { public Shape fetch(String id, String type, String index, String shapeField) throws IOException {
GetResponse response = client.get(new GetRequest(index, type, id).preference("_local")).actionGet(); GetResponse response = client.get(new GetRequest(index, type, id).preference("_local").operationThreaded(false)).actionGet();
if (!response.exists()) { if (!response.exists()) {
throw new ElasticSearchIllegalArgumentException("Shape with ID [" + id + "] in type [" + type + "] not found"); throw new ElasticSearchIllegalArgumentException("Shape with ID [" + id + "] in type [" + type + "] not found");
} }