Hi, i'm looking at my applications error handling and have a question.
Right now, when a server request goes wrong for reasons specific to the logic of my application, i currently solve the communication this way:
1. i set status to STATUS_FAILURE
2. i call setData with a positive integer that has a meaning to my app so that it can react properly in the browser.
I was thinking that it perhaps was better that i set the DSResponse status to custom negative integer values instead, since it's more in line with how you do it... And that way, i can have global handling of my custom status codes in my custom RPCExceptionHandler.
However, it's hard to know from the documentation which integer range you use for your status codes
How do i figure out which integers are "safe" for me to use, or do you recommend a different approach?
Right now, when a server request goes wrong for reasons specific to the logic of my application, i currently solve the communication this way:
1. i set status to STATUS_FAILURE
2. i call setData with a positive integer that has a meaning to my app so that it can react properly in the browser.
I was thinking that it perhaps was better that i set the DSResponse status to custom negative integer values instead, since it's more in line with how you do it... And that way, i can have global handling of my custom status codes in my custom RPCExceptionHandler.
However, it's hard to know from the documentation which integer range you use for your status codes
How do i figure out which integers are "safe" for me to use, or do you recommend a different approach?
Comment