On Wed, Mar 5, 2008 at 9:46 AM, ant elder <[EMAIL PROTECTED]> wrote: > > > On Tue, Mar 4, 2008 at 6:19 PM, Jean-Sebastien Delfino < > [EMAIL PROTECTED]> wrote: > > > ant elder wrote: > > > Ok thanks. The <binding.ws> element is also extensible so this axis2 > > config > > > could be added as extra attributes or elements there couldn't it, eg < > > > binding.ws timeOut="300000" />? Which seems simpler if allowed so why > > is the > > > policySet approach better? > > > > > > > <binding.ws timeout="300000" connections="10"> will require you to go > > open your application jar and change the .composite provided by the > > application developer to adjust the timeout or number of connections. > > > > Policies allow you to configure and adjust qualities of service like > > timeouts, connection pools etc. without touching the logical > > composition. > > -- > > Jean-Sebastien > > > > > Ok that makes sense. But how does this compare to say the JMS binding > which does support configuring QOS related things (priority, time to live > etc) via binding attributes? > > ...ant >
No replies yet so I'll expand a little in case i was misunderstood, I'm trying to get better understanding of this area as there's been little on the ML to date and I'd guess it may not be just me thats a bit unclear. One issue is that currently the samples we have just include the definitions.xml file within the contribution so the point about being able configure things externally isn't being demonstrated, maybe this is just a point in time thing as its being implemented in Tuscany. Another issue i have with the policySet using an appliesTo xpath for the service is that it's invisible when looking at a contribution, maybe if there was good tooling it would get highlighted in some graphical display but from just looking at the contribution its not obvious so i don't like it so much. I can see I may want to change the timeout on a reference externally to the contribution but it feels like I'd much more often want to change the actual target endpoint uri on the WS binding but we don't have a way to do that without opening the contribution. The SOAP version is defined in the spec as using intents so if that is a valid approach I'm not sure i understand why a timeout intent is not? Even when i can see it would be useful to be able configure aspects of a binding externally to a contribution it does seem like it makes it more complicated than necessary for simple use, eg this: <binding.ws timeout="300000" /> is much much simpler than requiring a separate document containing: <sca:definitions xmlns="http://www.osoa.org/xmlns/sca/1.0" targetNamespace="http://www.osoa.org/xmlns/sca/1.0" xmlns:sca="http://www.osoa.org/xmlns/sca/1.0" xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.0"> <sca:policySet name="tuscany:Axis2ConnectionsConfPolicySet" provides="" appliesTo="sca:binding.ws" tuscany:alwaysAppliesTo="sca:[EMAIL PROTECTED]'SomeName']"> <ConnectionsConf> <TimeOut>300000</TimeOut> </ConnectionsConf> </sca:policySet> </sca:definitions> Part of whats causing this confusion is that the JMS binding seems to use policy in a different way to the WS binding. Instead of using intents or policySets for these type of parameters it does just define them as elements and attributes of the <binding.jms>, but then it also supports pointing to an external binding configuration that is in a definitions.xml document. For example: <binding.jms requestConnection="foo" /> and a definitions.xml containing: <definitions> <binding.jms name="foo" ...(the various config attributes and elements)... /> </definitions> (though it has to be said the JMS spec only allows some of the config options to be specified in that external definitions file, and ones that you'd think should be there like timeToLive are not allowed!) So any comments from those who've made it this far through the email? Is some of this just due to timings of when specs were written or not yet finished? Would it be wrong to support extra attributes on the binding as well as the policySet approach to make the simple use easier? Or also the support the JMS binding approach and have binding.ws name an external binding config thats in an external definitions.xml so that its more obvious there's some external config going on when looking in a contribution? ...ant
