cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
577
Views
0
Helpful
1
Replies

jabberwerx.util.saveApp/loadApp breaks client

christoph1
Level 1
Level 1

Hi,

I use the jabberwerx.ui library for building a chat client within my webapp. I want to support synchronized chats over mutiple browsertabs with the persistedApplication feature from jabberwerx.util. Therefore I call "jabberwerx.util.saveApp" when leaving tab A of my browser, and "jabberwerx.util.loadApp" is called when I open another tab B (containing my application).

This works so far when the whole application is loaded initially. SaveApp in tab A stores the client in the localstore and loadApp in tab B reads the serlalized data in the new tab and builds the application from it.

When I switch back to the old tab A, the same procedure should give me the latest state of my chat client which was saved when tab B has been left.

Somehow, my jabberwerx app instance is broken, once saveApp is called. LoadApp does not make it work again.

So far my use-case ...

The problem in short:

I create a jabberwerx.ui client, call saveApp and then loadApp -> my client does not work anymore. Some objects are not serialized back and only their guid reference string is found instead of the object itself.

Has anyone ever tried this? Is this supposed to work? (persistedauthdemo and persistedchatdemo do only store the app on unload. I need the application being reloaded in an active tab).

I would really appreciate any advice.

Chris

1 Reply 1

nenad.ivkovic
Level 1
Level 1

Hi there!

I have the same problem, explained previously by Chris.

It would be greate if someone could give us any advice.

Thanks in advance

Nenad