Wraf: Session

A session can be pictured as a discussion between the service and the agent, via the client. They both send information to each other. It will typically be the agent that request information from the service.

The node representing the session is called ls:Service and is a rdfs:subClassOf ls:Model.

The answer to requests depend on which interfaces the session has connected to.

A new session object starts by connecting to the Base interface. It will then (usually) connect to the DBI interface, used to store new statings. This means that the session metadata (mainly the creation time of the model) will be created in a IDS without the ability to store the data.

Wraf will keep track on all data belonging to the session and copy all unsaved data to the new IDS then the session connects to a new interface.

A future data addition followed by a storage will store all unsaved referenced data. This will save the session metadata the instance it is referenced by anything else. This also makes it possible to defere the database work until after the response has been sent to the client.

The plan is to keep the diffrent IDS caches syncronized was to make changes in one IDS expire the related items in the other IDS and let the updated value come from the appropriate interface.