state machines and session size


General J2EE: state machines and session size

  1. state machines and session size (1 messages)

    In loan processing scenario, my application requires that i create a state machine for each loan application. Based on the user actions, state machine transitions the state of the application. The main problem is
    If i keep the state machine's data in memory , the session becomes heavy. Also, if user chooses to work on more than one application, more than one state machine would be active per user session. Also The net effect of few hundred concurrent user will result in heavy load on cluster because of session serialization.
    If i keep data needed for statemachine in database, then the construction of state machine is expensive. That is, for every user action, i would have to pull data required by state machine, initilize the machine with correct data and then process the request. This would result in slow performance again.
    Any ideas would be appreciated?
  2. state machines and session size[ Go to top ]

    Hi Maninder,

    Consider an alternative to storing the data in memory on the application instances such as in dedicated cache server JVMs. Our partitioned cache transparently partitions the cached data across the Coherence cluster nodes. This allows you to store support the large size of the dataset while still providing in-memory access speeds to the data.

    We also have functionality provided out-of-the-box to address the inefficiencies of native Serialization; the use of com.tangosol.util.ExternalizableLite can reduce the memory footprint of an object by more than 35%.

    Rob Misek
    Tangosol, Inc.
    Coherence: It just works.