Automatically generate indexes in datastore-indexs.xml using the Google App Engine

I had a problem developing an application using the Google app engine. On one screen of an application, I use filtering and a sorting method. In the development environment (on the local system), the screen works fine, but when we save my project in the working environment (in the Google engine cloud), I get an exception when accessing the same screen.

I searched the network to find a solution, I got a solution, but this is a very lengthy process. Here is my mistake:

 <datastore-index kind="Exception" ancestor="false" source="manual">
            <property name="packageName" direction="asc"/>
            <property name="model" direction="asc"/>
            <property name="exceptionDateTime" direction="desc"/>
     </datastore-index>

For this error, I created a file datastore-indexes.xmlin the web-inf folder, and the error is resolved in the working environment, but, like the error, I have many indexes to write to datastore-indexes.xml. Can someone give me clarifications and restrictions on writing all indexes or any other process to automatically create all indexes.

+4
source share
1 answer

The best scenario is to use both "final" datastore-indexes and datastore-indexes-auto.xml when creating an automatic index setting . (I don't know if this works using a standard maven-built war using src/main/webappthough).

, , .

dev . " ", .

, .

+3

Source: https://habr.com/ru/post/1537646/


All Articles