I wonder what we think about the Tuscany databinding framework and how it
could be used with Java-centric databindings (as opposed to say, XML-based
databindings).

Say I'm writing a binding which will use Java serialization to send/receive
data over the binding transport.

One approach would be to use the java.lang.Object databinding for my
binding's interface contract.

I've found that if I want to do this, it seems to be a lot easier if I
introduce a few very basic transformers:
   Simple2Object, Object2Simple, DataObject2Object,
with each doing no more than returning the input source object passed to
transform().

Otherwise I end up in transformer chains like:
  SimpleJavaType2Node, DOMNode2JavaBeanTransformer
which is unnecessary to simply pass along a Java primitive type.

I'm just wondering, though, how Raymond and others who've given the
databinding framework some thought would react to introducing those
transforms into the web of transformers.
Every entry "pollutes" the web a bit, of course.

An alternative approach is to do everything possible to avoid the Tuscany
databinding framework and to make sure a DataTransformationInterceptor is
not set up on the wire to/from the binding.
I wonder if that is the "preferred" approach Raymond had in mind??     Of
course the downside of this is that I lose the ability for my binding to
handle, say, a DOM Node, which Tuscany has a transform to Object for.

I realize that there's some other context in my situation I'm not
mentioning.   Namely, I'm partly doing things the way I am to workaround
JIRAS 1679,1680.

But still, maybe my question is worth addressing on its own.

Thanks,
Scott

Reply via email to