Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Buffer requested actions while not connected #10

Open
aurelien-baudet opened this issue Dec 14, 2017 · 0 comments
Open

Buffer requested actions while not connected #10

aurelien-baudet opened this issue Dec 14, 2017 · 0 comments

Comments

@aurelien-baudet
Copy link

For example, I have an Angular app that routes the url #/user/:userId to the UserPage page. The first thing done by this page is to load user information (firstname, lastname, ...) from ZP using the SDK (call to getUserInfo()).

When I navigate through Angular, the application is already started and the user is already connected so calling the getUserInfo() works.
However, when I enter the url in the browser or when I hit F5, the Angular applications loads directly the page and the call to getUserInfo() fails because the user is not connected (message : "Illegal state: already disconnected").

So when no connection is opened, the SDK should "replace" the real call by storing channel and parameters into a FIFO. As soon as the connection is avaiable, reexecute the pending actions stored in the FIFO and allow to call the real functions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant