PDA

View Full Version : setting a poller by reference



vincentditlevinz
Sep 21st, 2009, 03:46 AM
Hi,

I would like to set a poller by reference in a chain instead of using a nested poller declaration. More, I don't want this poller to be the default one. My use case: I have a default application context with the poller default definition. I want to be able to change this poller by overriding it in a second application context loaded after the default one.

I don't find any straightforward mean to achieve this, I wonder if it's possible and in this case the best way to follow.

Vincent

iwein
Oct 4th, 2009, 03:09 AM
I don't think there is namespace support for that, but it makes a lot of sense to me. Can you open an issue?

Mark Fisher
Oct 4th, 2009, 06:39 AM
There is in fact a "ref" attribute available on an inner <poller/> element for this very purpose.

vincentditlevinz
Oct 5th, 2009, 03:08 AM
I work with SI v 1.0.3. For the chain element I can only specify a "poller" which is a "basePollerType", not a "innerPollerType". Thus I suppose I cannot use a ref attribute for a nested poller in a chain. Just to be sure, I tried to force a ref attribute in the nested poller element and it fails with the following trace:

nested exception is org.xml.sax.SAXParseException: cvc-complex-type.3.2.2: Attribute 'ref' is not allowed to appear in element 'poller'.

Mark Fisher
Oct 5th, 2009, 09:43 AM
Could you please open a JIRA issue for this and point to this forum thread?

Thanks,
Mark