Date: 2005-01-14T10:19:16
Editor: SylvainWallez
Wiki: Cocoon Wiki
Page: FlowscriptAndSessionReplication
URL: http://wiki.apache.org/cocoon/FlowscriptAndSessionReplication
no comment
Change Log:
------------------------------------------------------------------------------
@@ -58,6 +58,8 @@
* As the scope has references to many Cocoon internal objects (see the
Cocoon object) serialization wouldn't work because many of them are not
serializable
* Serializing all the large objects would be very expensive
+
+How do session replicators work? What triggers the replication? I remember to
have read somewhere that it's triggered by the session.setAttribute() method,
in which case changing the state of a session attribute but not the attribute
itself causes problems.--[SylvainWallez]
=== Possible way to solve this problem? ===
(outlined by Christopher Oliver)
@@ -89,6 +91,8 @@
=== Description ===
Exchanging e.g. the {{{ContinuationsHolder}}} because only one Continuation
has been added, would be very expensive.
+Rather than having a single ContinuationHolder in the session that keeps all
continuations, it may be better to have each continuation stored as a separate
session attribute. That may both trigger the replication system and reduce the
replication load. --[SylvainWallez]
+
=== Possible solution ===
Add some kind of delta management into the serialization/deserialization
process. But how ...?
@@ -102,6 +106,8 @@
var y = cocoon.createObject("myObjectImplementingAvalonInterfaces");
}
}}}
+
+cocoon.getComponent() can return a serializable proxy, but
cocoon.createObject() must return a serializable object. There's also a problem
with CForms: a form contains its own data model, which can be serialized, but
also pointers to its definition, which is shared between form instances and can
contain arbitrary references to non-serializable objects and
components.--[SylvainWallez]
=== Possible solution ===
* Forbid the usage of components