HTTP Request Action Gives Socket Timeout Exception
Moderator: Martin
HTTP Request Action Gives Socket Timeout Exception
I keep seeing socket timeout exceptions with the HTTP request action on 1.27. My flows haven't changed at all, but now I'm not always getting the response back from the phone when I trigger the flow. It seems like it's throwing the exception when it shouldn't. I'll capture a log when I can and update the post. Is there anyway to go back to 1.26 until there's a fix?
Re: HTTP Request Action Gives Socket Timeout Exception
Hi,
There was indeed a change in this area. A socket timeout exception or another exception that prevents the HTTP request from being sent to the server did not lead to an error on version 1.26 but simply set the response code to -1. Version 1.27 now properly detects the error and leads to an error. If you'd like to continue the flow without handling the error, you can do so by adding an exception-handling connection. To do this:
-add a new action like 'Vibrate' or 'Notification on Screen' to the flow
-connect the action 'HTTP request' to this action
-select the connection
-select edit
-change the type to 'Exception'
-connect the Vibrate action to the action of the flow you'd like to continue
Please send a log to me at info@automagic4android.com if this does not resolve the issue.
Regards,
Martin
There was indeed a change in this area. A socket timeout exception or another exception that prevents the HTTP request from being sent to the server did not lead to an error on version 1.26 but simply set the response code to -1. Version 1.27 now properly detects the error and leads to an error. If you'd like to continue the flow without handling the error, you can do so by adding an exception-handling connection. To do this:
-add a new action like 'Vibrate' or 'Notification on Screen' to the flow
-connect the action 'HTTP request' to this action
-select the connection
-select edit
-change the type to 'Exception'
-connect the Vibrate action to the action of the flow you'd like to continue
Please send a log to me at info@automagic4android.com if this does not resolve the issue.
Regards,
Martin