Enabling Multiple Logins

We are having a few issues with users logging into the same account from different devices. They use the same users name and password and login through different devices.

Before turing on multiple logins through backendless, I wanted to get a little more information on whether that effects any other features. I was reading a post by Mark (see link below) that said “It is not recommended to use the “Multiple Logins” feature with disabled session timeout.”

http://support.backendless.com/t/unable-to-login-multiple-login-limit-for-the-same-user-account-has-been-reached-rest-api

Is there any way to have multiple sessions through the same user account but not have session timeout enabled? This is definitely something you should consider mentioning when a Backendless admin turns on multiple logins.

Essentially, we have a mobile app which should always remained logged. But if that same user wants to login through his/her iPad as well, they should be able to do that. Again, it should never log the user out on either device.

Another issue that we are having is that when a user logs into his/her account from one device and then logs into that same user account from another device. The first device gets logged out. When the user tries to make a new account on the first device instead of logging in with the same credentials, it gives us the error "Not existing user token - xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx. Relogin user to update your user preferences. Once this error message comes up, the only way for the user to proceed is either to login using the same credentials or delete the app and re-install it from the app store.

Is this a problem with something in our code or an issues on you end?

Hi, Nevin!

As Mark mentioned in the post you’ve referred to “When multiple logins are turned, the session duration is still present - The default duration is 30 days”. So even if you do not enable the session timeout in console effectively it will still be 30 days. If you need a bigger session timeout you can turn “Session time out” toggle on and specify the timeout yourself.

Getting an “Not existing user-token…” when trying to register a new account is a bug - I’ve opened an internal ticket BKNDLSS-13138 to fix it and we’ll notify you when it is ready.

Although I still have questions for you:
Do you have “Enable Multiple Logins” turned on and what is the maximum number of logins you’ve specified? If Multiple Logins are disabled and “Logout First user” checkbox is checked then the case you describe is valid.

When you get the “Not existing user token” error - are you able to logout and then login with another credentials without need to re-install the whole application from app store?

Perfect. Thanks. Is there any upper limit for the number of days we can set the session timeout to be?

When this issue was occurring, we had “Enable Multiple Logins” turned off. Because they were turned off, we didn’t have the option to select the “Logout First user” checkbox. “Session time out” were also off.

We are able to login with another user’s credentials. We are just not able to create another user account without getting that error message, “Not existing user-token…”.

When I tried to do this again today, I got a new error that read “Error” “License not found.”

As a solution, can I turn on “Enable Multiple Logins” and set the “Session time out” to 999 so that a user is allowed to login from multiple devices but can still be logged in for 999 days? By doing this, there is nothing that needs to be changed in our code right?

I would definitely recommend putting a note under the “Enable Multiple Logins” in the console which tells the Backendless admin that turning this feature on results in “Session time out” being set to 30 days.

I want to quickly follow up here to see if that is possible on our end?

The “License not found” error has been fixed in the latest build of the iOS SDK.

Yes, you can turn on “Enable Multiple Logins” and set the “Session time out” to 999 (days) .

Regards,
Mark

Perfect. Thanks!

The session time out option is only available for seconds. Should I set the number of seconds to be 86,313,600 (the equivalent of 999 days)? Is that value too high? What is the maximum I can set it to?

I want to quickly follow up here. Should we set a very high number of seconds to make this work? What is the maximum value we can set?

Maximum allowed value is 2147483647