Login failed: BackendlessException{ code: '3048', message: 'Session timeout.

Hi -

I have ‘Multiple login’ disabled and I kept getting this exception - until I changed "When a secondary login occurs, logout and notify: -> “Second User”.

Can you please explain the behavior - isn’t it possible to keep above configuration as ‘First User’ and login properly after ‘session expiry’ ?

Please note - I call a ‘Backend API’ - before calling login() on the user.

Thanks.

Getting this exception - even with ‘Notify second user’.

I do not get it always - but like 50-70% of time.

Any pointers on what could be wrong ??

There is no consistency - I get below exceptions too - sometimes .

Login failed: BackendlessException{ code: ‘14005’, message: ‘Service invocation failed by timeout’ }

Login failed: BackendlessException{ code: ‘0’, message: ‘Type:“java.lang.ThreadDeath”, Description:“exception during method invocation”
ExceptionClass:“ServiceException” {Msg:“none”, Cause:“none”}’ }

Is this due to load ?? I have to try 2-4 times for a single login - sometimes it works in first attempt .

Hi!
Please provide your request example which returns inconsistent errors.
(please send all useful information to support@backendless.com)

Was this issue ever resolved?

Yes, I believe so. Are you experiencing similar exceptions?

Yesterday I got the “java.lang.ThreadDeath” exception but it wasn’t consistent. I’m not sure if it was due to my use of the user service or some other part of my API service (which is mainly using the data service). If the exception happens again I’ll narrow down the part of my code where it’s happening and create a ticket.

As per my observation, these inconsistent exceptions happen when backend server code execution time is more than allowed limit i.e. > 5 sec for free version.

I took service pack to increase it to 20 sec - and its much better now.

I still get exception sometimes - but clearly only when I dont receive response for more than 20 sec from server.

So, sometimes my backend code finishes and returns response in 2 secs - sometimes not even in 20 sec and then exception.
As of now, I am hoping this is due to load on “free” backendless server instance.

Hi -

I have again started getting this issue today - and this time I am getting it always.

I am always getting below exception - and my backend server code is not getting hit.

I get this exception within 1 or 2 secs as response.

07-09 14:55:48.382 19348-19426/com.whyso.aditya.mytest E/MerchantUser: BackendlessException{ code: ‘3048’, message: ‘Session timeout. Url: <https://api.backendless.com/09667F8B-98A7-E6B9-FFEB-B2B6EE831A00/page/session_expiration/index.html>;’ }

It because the session of the user, that you are logged in was expired. so you should relogin the user