"The connection has timed out" Error only on mobile app, not on browser

"The connection has timed out" Error only on mobile app, not on browser

  

The time out error only happens on mobile app, not on browser. How should i approach to debug the problem?



Error Detail
Back to Log
Id:
115cb0a5-76db-458c-94a4-3a6d7bbf5a6d
Time of Log:
2017-02-07 15:09:09
eSpace:
WinToto
Tenant:
Users
User:

Session Id:
No session
Server:
S1OAB-LT2DFN
Module:

Message:


The connection has timed out


Environment InformationeSpaceVer: 101 (Id=305, PubId=289, CompiledWith=10.0.200.2)
RequestUrl: https://toto.outsystemscloud.com/WinToto/moduleservices/log?1486480149666 (Method: POST)
AppDomain: /LM/W3SVC/68/ROOT/WinToto-251-131309526162868436
FilePath: C:\OutSystems\Sandboxes\BK4KH0065\Platform Server\running\WinToto\
ClientIp: 222.164.128.196
Locale: en-US
DateFormat: yyyy-MM-dd
PID: 44792 ('w3wp', Started='1/4/2017 11:53:56 AM', Priv=880Mb, Virt=18627Mb)
TID: 50
Thread Name:
.NET: 4.0.30319.42000
Client-Side Log
Stack:
Post
 Error
    at XMLHttpRequest.h.ontimeout (https://toto.outsystemscloud.com/WinToto/scripts/OutSystems.js?sdcuBcomxTNu8PYGfXaUiQ:7:2487)
    at https://toto.outsystemscloud.com/WinToto/scripts/OutSystems.js?sdcuBcomxTNu8PYGfXaUiQ:7:279

Hi Linguo,

Is that the full stack of the error? Do you know which endpoint might be failing?

Does it happen on OutSystems Now? You can try check OutSystems Now console logs to see more details.

i installed native app, the app is not working properly on outsystems now.

i found out the connection time out happens when the app is trying to call google web service, but when i test on browser, it does not happen. 

i first try to use client side action to call google web service, and later tried server side action to call, both case time out, even if i set the time out to 60 seconds, still happens.  on browser, it usually take less than 10 seconds to get the result back from google.

after change to server side action, below is the error details


Error Detail
Back to Log
Id:
283ce435-1315-4a09-abc6-89bb4c78f672
Time of Log:
2017-02-08 12:04:30
eSpace:
WinToto
Tenant:
Users
User:

Session Id:
No session
Server:
S1OAB-LT2DFN
Module:
REST (Expose)
Message:


The client is disconnected because the underlying request has been completed.  There is no longer an HttpContext available.


Environment InformationeSpaceVer: 108 (Id=313, PubId=297, CompiledWith=10.0.200.2)
RequestUrl: https://toto.outsystemscloud.com/WinToto/screenservices/WinToto/MainFlow/HomeScreen/ActionGetRawTextFmImageServer (Method: POST)
AppDomain: /LM/W3SVC/68/ROOT/WinToto-259-131310290176266331
FilePath: C:\OutSystems\Sandboxes\BK4KH0065\Platform Server\running\WinToto\
ClientIp: 118.200.144.76
Locale: en-US
DateFormat: yyyy-MM-dd
PID: 44792 ('w3wp', Started='1/4/2017 11:53:56 AM', Priv=781Mb, Virt=18626Mb)
TID: 89
Thread Name:
.NET: 4.0.30319.42000
Stack:
The client is disconnected because the underlying request has been completed.  There is no longer an HttpContext available.
   at System.Web.HttpBufferlessInputStream.Read(Byte[] buffer, Int32 offset, Int32 count)
   at System.Web.Http.WebHost.SeekableBufferedRequestStream.Read(Byte[] buffer, Int32 offset, Int32 count)
   at System.IO.StreamReader.ReadBuffer()
   at System.IO.StreamReader.ReadToEnd()
   at OutSystems.RESTService.Formatters.TextMediaTypeFormatter.ReadFromStreamAsync(Type type, Stream readStream, HttpContent content, IFormatterLogger formatterLogger)
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Net.Http.HttpContentExtensions.<ReadAsAsyncCore>d__0`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Web.Http.ModelBinding.FormatterParameterBinding.<ExecuteBindingAsyncCore>d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Web.Http.Controllers.HttpActionBinding.<ExecuteBindingAsyncCore>d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Web.Http.Controllers.ActionFilterResult.<ExecuteAsync>d__2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Web.Http.Filters.AuthorizationFilterAttribute.<ExecuteAuthorizationFilterAsyncCore>d__2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Web.Http.Controllers.ExceptionFilterResult.<ExecuteAsync>d__0.MoveNext()

i find out that the time out happens when the server side action is trying to return the result back to mobile app, how can i debug further to find the problem?



Id:
dd641d13-2b09-4758-af3a-ea1e0d65f257
Time of Log:
2017-02-11 04:39:43
eSpace:
WinToto
Tenant:
Users
User:

Session Id:
No session
Server:
S1OAB-LT2DFN
Module:

Message:


The connection has timed out


Environment InformationeSpaceVer: 118 (Id=344, PubId=326, CompiledWith=10.0.200.2)
RequestUrl: https://toto.outsystemscloud.com/WinToto/moduleservices/log?1486787983812 (Method: POST)
AppDomain: /LM/W3SVC/68/ROOT/WinToto-288-131312615361405685
FilePath: C:\OutSystems\Sandboxes\BK4KH0065\Platform Server\running\WinToto\
ClientIp: 222.164.128.196
Locale: en-US
DateFormat: yyyy-MM-dd
PID: 44792 ('w3wp', Started='1/4/2017 11:53:56 AM', Priv=843Mb, Virt=18648Mb)
TID: 67
Thread Name:
.NET: 4.0.30319.42000
Client-Side Log
Stack:
GetRawTextFmImageServer
 Error
    at XMLHttpRequest.h.ontimeout (https://toto.outsystemscloud.com/WinToto/scripts/OutSystems.js?sdcuBcomxTNu8PYGfXaUiQ:7:2487)
    at https://toto.outsystemscloud.com/WinToto/scripts/OutSystems.js?sdcuBcomxTNu8PYGfXaUiQ:7:279

after server action "GetRawTextFmImageServer", no result is passed back, time out happens


You'll have to increase the timeout of the GetRawTextfmImage action. Click on the action and change the timeout in properties.

i have changed it to 60 seconds and the error still happens, but in browser, it only take around 10seconds to get the result

It might depend on the network conditions.

network is ok and it happens 99% od the time when testing

How long does the server action takes to execute? Isn't it surpassing the 60 seconds timeout? Is there any proxy or firewall in the middle that might be causing that problem? How big is the response?

I am also getting the same error while login from mobile app, On browser its running fine. 

there is a server request timeout setting at module level, try change that