| Summary: | FunCBRRules Method for XPath Broken in Tooling | ||
|---|---|---|---|
| Product: | [JBoss] JBoss Enterprise SOA Platform 5 | Reporter: | Brad Davis <brad.davis> |
| Component: | Tooling | Assignee: | Brian Fitzpatrick <bfitzpat> |
| Status: | CLOSED WONTFIX | QA Contact: | |
| Severity: | high | Docs Contact: | |
| Priority: | high | ||
| Version: | 5.0.2 | CC: | bfitzpat, scabanovich |
| Target Milestone: | --- | ||
| Target Release: | 5.2.0 GA | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| URL: | http://jira.jboss.org/jira/browse/SOA-2747 | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: |
JBoss Developer Studio 3.0.0.GA
|
|
| Last Closed: | 2011-11-15 17:07:04 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
Steps to Reproduce: Added: Create the following action in an action pipeline via the Source view.
<action class="org.jboss.soa.esb.actions.ContentBasedRouter" name="validateAndRoute">
<property name="cbrAlias" value="XPath"/>
<property name="destinations">
<namespace prefix="m" uri="http://amentra.com/mentoring" />
<route-to expression="//m:id > '0'"
service-category="student-esb-services" service-name="AsyncSetAdvisorGraduateStudentService"/>
</property>
</action>
Browse to the Tree view, and add an action after validateAndRoute.
Save the jboss-esb.xml
Browse to the Source view.
Note that the namespace tag within the destinations has been removed.
Link: Added: This issue depends JBIDE-9217 Created JBIDE-9217 to track this... Programmers Guide for the JBoss ESB describes properties of ContentBasedRouter action as follows:
destinations
Container property for the <route-to> configurations.
namespaces
Container property for the <namespace> configurations,
where required e.g. for the XPath ruleprovider.
That means that according to the specification, the code should be like this
{code}
<action class="org.jboss.soa.esb.actions.ContentBasedRouter" name="validateAndRoute">
<property name="cbrAlias" value="XPath"/>
<property name="destinations">
<route-to expression="//m:id > '0'" service-category="student-esb-services" service-name="AsyncSetAdvisorGraduateStudentService"/>
</property>
<property name="namespaces">
<namespace prefix="m" uri="http://amentra.com/mentoring"/>
</property>
</action>
{code}
It is supported by ESB editor.
I suspect that runtime just collects all child elements <route-to> and <namespace> wherever they are under ancestor <action> node, but that is not a documented feature; and supporting such a feature in ui would really make hard time for it since in implementing editor I relied heavily on structure described in Programmers Guide.
Brad, would you please consider if sticking to the version of the action that I suggest would solve the issue provided that it is ok in runtime?
I have found that ui inserts line <property name="ruleLanguage"/> - if it is a bug, it is easy to fix.
See the feedback on JBIDE-9217. But based on the feedback there, this is a configuration issue and not an editor issue. If you have further questions about the ESB configuration portion, we recommend putting it on the forum to get faster input from the ESB team. Release Notes Docs Status: Added: Not Required Writer: Added: dlesage |
Steps to Reproduce: Create the following action in an action pipeline via the Source view. <action class="org.jboss.soa.esb.actions.ContentBasedRouter" name="validateAndRoute"> <property name="cbrAlias" value="XPath"/> <property name="destinations"> <namespace prefix="m" uri="http://amentra.com/mentoring" /> <route-to expression="//m:id > '0'" service-category="student-esb-services" service-name="AsyncSetAdvisorGraduateStudentService"/> </property> </action> Browse to the Tree view, and add an action after validateAndRoute. Save the jboss-esb.xml Browse to the Source view. Note that the namespace tag within the destinations has been removed. Workaround: Workaround Exists Workaround Description: Do not use the XPath ContentBasedRouter within JBoss Developer Studio. project_key: SOA When adding an ContentBasedRouter with the following configuration in JBoss Developer Studio, switching between Tree and Source view will remove the namespace tag. <action class="org.jboss.soa.esb.actions.ContentBasedRouter" name="validateAndRoute"> <property name="cbrAlias" value="XPath"/> <property name="destinations"> <namespace prefix="m" uri="http://amentra.com/mentoring" /> <route-to expression="//m:id > '0'" service-category="student-esb-services" service-name="AsyncSetAdvisorGraduateStudentService"/> </property> </action> This results in the following after toggling and adding another action. <action class="org.jboss.soa.esb.actions.ContentBasedRouter" name="validateAndRoute"> <property name="cbrAlias" value="XPath"/> <property name="ruleLanguage"/> <property name="destinations"> <route-to expression="//m:id > '0'" service-category="student-esb-services" service-name="AsyncSetAdvisorGraduateStudentService"/> </property> </action> Note that the namespace tag under property "destinations" has been removed by the tooling.