Skip to Content
0

SMP Logout without connection

Jun 20, 2017 at 08:22 AM

85

avatar image

Hello Everyone

I have been going through this very helpful blog on SMP onboarding using the Odata protocol - https://archive.sap.com/documents/docs/DOC-59555

I would like to know what the best way to handle the logout function is in the case where the user does not have a data connection and cannot reach the SMP server to delete his registration token.

Is there any harm to just leaving the token/registration there on the SMP server? As the user will simply get a new registration token when he logs in again.

Is there a better way to handle this scenario?

Thank you

Riaz

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Best Answer
Jitendra Kansal
Jul 12, 2017 at 02:24 PM
0

Hello Riaz,

Just to comment on this part:

I would like to know what the best way to handle the logout function is in the case where the user does not have a data connection and cannot reach the SMP server to delete his registration token

In my most of SMP projects,we implemented 'LogOut' functionalities only to be used when user has connectivity (calling DELETE REST API), it will delete respective SMP-AppCID

However, IMO (again), there is no harm leaving those registrations in SMP server (but yes as said by Akos its not a best way), however, you may go for 'automatic removal' option , where inactive registrations are removed automatically after a certain time.

https://help.sap.com/viewer/313e7789125149b3b5bb6f1c7e1ea322/3.0.13/en-US/cd411891b2e74310b5384426bf91f674.html

Regards,

Jitendra

Show 1 Share
10 |10000 characters needed characters left characters exceeded

Hi Jitendra

Thank you for pointing out that feature, I think its the best viable option for this scenario.

Regards

Riaz

0
Akos Grabecz
Jun 23, 2017 at 01:02 PM
1

Hello Riaz,

We don't really have a best practice for that. To leave a registration ID and always have a new one is not the best option as that can cause inconsistencies which are really hard to untie. At the comment section of the blog you are referring to there are some examples which are pretty good.

Best regards,

Ákos

Show 1 Share
10 |10000 characters needed characters left characters exceeded

Hello Akos

I had a look at the comments section in more detail but I still feel like it doesn't guide me to a best practice way of handling this situation.

Do you know if its possible to call the delete registration method before the registration method and in this way first delete an old registration that was unable to be deleted before due to connectivity?

Regards

Riaz

0