The persistor is not making updating the documents immediately. I have written a test code where a document is retreived from the API by ID, a field is modified, and then persisted. Next, the code queries the API for the new field value, but the modified document is not found. However, if the code searches for the document by ID instead, then the modified document is found. It seems like the field value is not immediately persisted for API queries? If not, how can I ensure that persistence is done before I query again?
The queryItems GDS function is eventually consistent, meaning that if you query immediately after persisting something you may not see the results you expect. getItem on the other hand is immediately consistent; so if you retrieve the item by id rather than by querying, you should get the modified document in the response.