We are using App server to generate session_id for user. I have question on multiple session for same user.
In the following dataflow when you make 2nd request to CreateSessionB, does CreateSessionA is still valid?
1st Request: User A -> Device A -> App Server -> SyncGateway -> CreateSessionA-> Send it back to Device A
2nd Request: User A -> Device B -> App Server -> SyncGateway -> CreateSessionB-> Send it back to Device B
Also, for using session_id on the client side. I am setting cookies with the session data.
What configuration I need on the SyncGateway? Currently we have GUEST login disabled, and all the documents have owners.
We are using custom authentication and creating SyncGateway users from the App Server using REST API.
How to configure SyncGateway(Gusest login is disabled) to use the session_id?
Follow up question as same user can have multiple sessions.
We are thinking about creating one SG user, all the documents will be own by one user. App User specific documents will be filtered by channels.
Any feedback/best practice on:-
One SG user for all App user
Vs
Separate SG User for each App User