XPages: A ClientSide State

I have created a ClientSide State for XPages, which allows horizontal scaling of XPages applications with a single click.

After installing the OSGi Plugin on the servers and the DDE, you can activate it with a single click:

2015-09-13 20_41_02-XPage Properties Editor - ClientStateDemo - IBM Domino Designer

Then, the State of the XPages application view is stored on client side (in the field „$$clientstate„), and not on the server anymore. The State is AES-128 encrypted and uses some random bytes for a higher security.

2015-09-13 20_52_11-Quelltext von_ http___localhost_ClientStateDemo.nsf_Test.xsp

You can find the code on GitHub.

P.S.

Parts of the code are shamelessly stolen from Jesse.

Dieser Beitrag wurde unter OSGi, Server, XPages abgelegt und mit , , , verschlagwortet. Setze ein Lesezeichen auf den Permalink.

7 Antworten zu XPages: A ClientSide State

  1. sean cull sagt:

    Hello Sven,

    could you tell us a bit more about why you needed to do this and what it does ( in simple terms ). Is it letting you use more XPage servers in parallel ? Did you hit a limit ?

    Thanks, Sean

    • Normally, the state of any XPages application view is stored on the server where the application is hosted (in memory or on disc). When the session and/or the application is timed out, this state is discarded. Or if you have multiple servers, you cannot switch between them (f.e. with Round Robin, or if one server crashes).

      With this solution, the state is now stored in the browser and is sent to the server during a request. If you store it in the local storage of the client, you could even shutdown the PC and continue your work some days later (To prevent a manipulation, the state is AES encrypted).

      The price for this is that the state has to be added to every request (and current ly to any response).

      Hope this gives you some insights.

  2. what is the „state“ of an application ?

  3. Sean Cull sagt:

    Hello Sven, I just came across this again today via Twitter – thanks for posting and gitting,

    https://twitter.com/seancull/status/1094991609811398656

    Has the code worked well for you over the years in between ?

    thanks, Sean

Schreibe einen Kommentar

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert.