I am trying to update the document using java sdk, when I run my code kuzzle status is connected, it update the fields but neither comes in onSuccess() nor onError(). when I again request to updateDocument(), kuzzle state change from connected to error. I debug the issue and found this exception. java.lang.RuntimeException: org.json.JSONException: JSONObject["_source"] not found.
as I am not getting "_source" in my code
kuzzle.collection("collection","testindex").updateDocument(obj.getDocumentId(), jsonObj, new ResponseListener<Document>() {
@Override
public void onSuccess(Document response) {
System.out.println("success"+response);
}
@Override
public void onError(JSONObject error) {
System.out.println("error"+error);
}
});