Closed andreineacsu closed 8 years ago
At the moment the sdk doesn't support retries. If it did you wouldn't be seeing this exception. There is some issues in handling retries in unity since the WWW does not give us the response body in case of an error.
So short answer No there is no way to get the the unprocessed items, I'll add it to feature requests/backlog and let you know once we have an update,
I could provide you with a WWW like class that will return the response body in case of both error and success. Would this help you in improving the SDK?
At the moment we are planning to move to UnityWebRequest API which would be available post Unity 5.3 on android and ios. That said i would love to take a look at the code and consider if your API is compatible. Do you have a github repo link? What is the license?
Just FYI here are couple of things that i'm looking for:
At the moment I can provide iOS and Android natively written plugins that would handle both SSL and HTTP errors. These plugins are written by me and does not imply a standard license.
We have checked out this issue on our end and we have found that WWW returns the server's response in case of an error. Please find bellow the code we have used to read the server's response in case of a non 2xx HTTP code:
WWW www = new WWW ("[YOUR URL]"); yield return www; string response = ""; if (www.error != null) { //contains the error message corresponding to the HTTP status code (E.g.: 500 = internal server error). response += www.error; } if(www.bytes != null) { response +=" Resp:" + System.Text.Encoding.UTF8.GetString(www.bytes); //contains the response received from the web server regardless if there was an error or not } resultText.text +=response; resultText.text +="\n";
We have tested this code on iOS 8 and 9 and the Unity Editor. I hope this helps.
right, but the problem is also that the this feature isn't supported broadly in all the unity versions that we support. In any case looking more into retries its possible to do retries without depending on the error. I'll add a feature to retry on exceptions.Will update this thread when the feature is out.
closed in 2.1.0.0
Test Scenario:
Can you please let me know how can I get the list of unprocessed items when ExecuteBatchWriteAsync fails?
Thanks, Andrei