Just wanted to chime in on this. I think it's an excellent idea that
would would be of great benfit for long running session with many
small invocations.

That was the whole intention. The idea is to have a hybrid between a statically typed metaprotocol (like CORBA or RMI / reflection) and a dynamically typed metaprotocol (as Hessian is now) to get the best of both worlds:

The inter-language flexibility, simplicity and ease of use of dynamic type information.
Being able to avoid sending subsequent redundant type information

My first thought around this though was to have an
explicit session negotiation occuring, initiated by the peer that
wants to use a long running session. Just for the sake of being
explicit about the session and also allowing for fallback to
sessionless invocation. Although having the reciever request a resend
would probably work just as well.


I can see where you are coming from, but I was envisaging an idempotent type request that would simplify any state management. By doing this,

You don't have to maintain any pending work on the sending side.
Also, by taking a RESTful approach, you also don't have to bind your *Hessian session* to any transport layer session, meaning that you can break off communication and then rejoin and reuse the known types, if both peers have still retained this type information. If after recommencing the communication one peer has discarded the type information, it just requests a resend when the other peer sends instance information of this type.
It means the direction of the initiation of the *session* is irrelevant.

In saying all of this, I am trying to avoid using the word session to describe this interaction context or scope in order to keep things as simple as possible from a protocol perspective.

What I like the most about this approach is that you can do something similar to the non-java.io.Serialization implementations (e.g. JBoss Serialization, Coherence ExternalizableLite) that piggyback off the fact that the sender and receiver implicitly have the static type information they need, but you could do it in a language-neutral fashion.

HTH,

Ben

_______________________________________________
hessian-interest mailing list
[email protected]
http://maillist.caucho.com/mailman/listinfo/hessian-interest

Reply via email to