I have include the Geoespacial Query to check if a GeoPt is inside a Circle and I have created a index for it. When I try to deploy it to GAE, I'm getting the following error:
Creating an index failed for entity_type: "MyEntity" ancestor: falseProperty { name: "name"}Property { name: "location" mode: 3}: Permission denied for creating a search index
this is the code that I'm Executing
GeoPt center = new GeoPt((float) pLatitude, (float) pLongitude);
double radius = pDistanceKM*1000;
Query.Filter f = new StContainsFilter("location", new Circle(center, radius));
items = ofy().load().type(MyEntity.class).filter(f).filter("name", tmpName).list();
I have created an index according to the documentation:
This is my index:
<datastore-index kind="MyEntity" source="manual">
<property name="name" />
<property name="location" mode="geospatial"/>
</datastore-index>
Does anyone have any idea of what it could be this permission?
Using Java and Android Studio.
Ps: When I try to execute the code, the Logging in the GAE suggest me an index identical as my index
com.google.api.server.spi.SystemService invokeServiceMethod: exception occurred while calling backend method com.google.appengine.api.datastore.DatastoreNeedIndexException: no matching index found. The suggested index for this query is:
<datastore-index kind="MyEntity" source="manual">
<property name="name" />
<property name="location" mode="geospatial"/>
</datastore-index>
Geospatial search for Datastore is an Alpha release which has reached capacity for now. Looking at the error, it looks like you aren't part of the Alpha program.
Stay tuned for the Beta which will be open to everyone!