Dom Converter id reference rename
Hi there,
I am currently trying to provide Rename support for my bean/service references.
For instance this is my test data :
<reference id="timeService" interface="foo.ITimeService" />
<camelContext xmlns="http://camel.apache.org/schema/blueprint">
<route>
<from uri="direct:foo"/>
<setHeader headerName="foo">
<method ref="timeService<caret>" method="getTime" />
</setHeader>
</route>
</camelContext>
After calling the rename I would like for both the ref attribute and id attribute to be renamed.
However currently after invoking a rename, only the XmlTag is renamed
<newName id="timeService" interface="foo.ITimeService" />
I am currently attempting to handle this rename within a Converter; However my handleElementRename isn't triggering...
I wonder if it is possible to resolve to to my Id attribute directly when performing renames etc, yet still provide access to the DomElement GenericAttributeValue<BlueprintBean>?
Cheers
Alan
Please sign in to leave a comment.
Does reference@id have @NameValue annotation? It should work out-of-the box using plain Converter.
Thanks for the reply Yann :)
Adding @NameValue not only allowed the target id to be renamed successfully, but it also caused the converter breakpoint to trigger too. Brilliant!