1 2 3 4 5 Previous Next 64 Replies Latest reply on Oct 2, 2009 2:43 PM by kconner Go to original post
      • 45. Re: XPath Routing
        kconner

         

        "tfennelly" wrote:
        Kev... when you get a chance... outline the exact configuration you want to see for this please. Thanks.

        You seem to be doing a good enough job with what we have already discussed, what do you see missing?

        The current codebase does not have that many restrictions (if any), certainly nothing that concerns any xpath/regexp work, and there is no reason why you need to break what is there just to extend it.

        All we need to do is add the same capabilities as already exist for drools, evaluate the expressions to determine the target services and send the messages.

        Kev

        • 46. Re: XPath Routing
          burrsutter

          Kevin,

          Do you have any specific concerns with my proposed "short-cut"? Remove the destinations when using the XPath/Regex inline.

          <action class="org.jboss.soa.esb.actions.ContentBasedRouter" name="ContentBasedRouter">
           <property name="cbrClass" value="XPath"/>
           <property name="ruleSet">
           <rule target-service="OrderCategory:BlueService" expression="/order/header[@cat='blue']" />
           <rule target-category="OrderCategory" target-service="RedService"" expression="/order/header[@cat='red']" />
           </property>
          </action>
          


          We need to pick the right attribute names for the "target-service" and/or "target-category". I do think this cleans this up a bit for the most simple use cases.


          • 47. Re: XPath Routing
            kconner

            None at all, provided Tom has no technical objections. It looks good to me and I am assuming it fits.

            I have not seen any comments which would suggest it doesn't.

            Kev

            • 48. Re: XPath Routing
              kconner

              Actually, I would not go with the category:name format as we have no clean mechanism for handling that. We have hit an escaping issue in a number of places when trying this out.

              It was an issue for InVM and, although a fix was added, it doesn't actually work completely. There is still a possibility of conflict, albeit remote.

              Kev

              • 49. Re: XPath Routing
                kconner

                This is yet another argument for using QNames rather than separate category/name values. That is well understood.

                Kev

                • 50. Re: XPath Routing
                  tfennelly

                   

                  "Kevin.Conner@jboss.com" wrote:
                  what do you see missing?


                  What do you want to call this additional attribute (instead of using cbrClass), and what values do you want it to have?

                  • 51. Re: XPath Routing
                    ammppp

                    Looking good guys! Only two other things I'd like to see here.

                    One is something similar to what someone else mentioned - basically allow the service name and category to optionally be xpath as well (basically destinations can be dynamic rather than picked from a static list). For example:




                    <destination target-category="/order/header/@category" target-service="/order/header/@service" expression="/order/header[@cat='red']/>



                    In this case, a previous action would have been responsible to set these attributes in the message or the other ESB service developers would be responsible to name the ESB services based on values already passed in the ESB message.

                    Second thing is that I'd like the xpath to not be restricted to the default message body. Would be nice to be able to pull this data (decision expression or service name or service category ) from some place other than just the default message body.

                    These same requests would apply to the regex router.

                    • 52. Re: XPath Routing
                      kconner

                       

                      "tfennelly" wrote:
                      "Kevin.Conner@jboss.com" wrote:
                      what do you see missing?


                      What do you want to call this additional attribute (instead of using cbrClass), and what values do you want it to have?

                      I'm not really bothered what it is called as long as it does not overload the cbrClass attribute, it serves a different purpose.

                      The values should represent the types supported, an enumeration of sorts, with the lack of presence indicating the current functionality.

                      Kev

                      • 53. Re: XPath Routing
                        tfennelly

                         

                        "Kevin.Conner@jboss.com" wrote:
                        I'm not really bothered what it is called


                        I'd prefer you to pick the name. No arguments later then about what was agreed and what wasn't. Thanks.

                        • 54. Re: XPath Routing
                          mvecera

                           

                          "Kevin.Conner@jboss.com" wrote:
                          "tfennelly" wrote:
                          Martin, would you be OK with putting this one on the back boiler for now? We can always add it later.

                          I agree with this, we should defer this until later so that we can have time to think about the consequences.

                          The current work is only concerned with duplicating the CBR functionality but using xpath/regexp in place of drools.

                          Kev


                          +1

                          • 55. Re: XPath Routing
                            tfennelly

                            This functionality is now available in trunk (XPath and Regex). See the fun_cbr quickstart and the docs for more details.

                            • 56. Re: XPath Routing
                              ldimaggio

                              Just to confirm, these changes should have no impact to existing configurations and .esb's that make use of content based routing? (aka no migration) And - the ESB (eclipse) editor will be upated to handle the changes when 4.7 goes GA? Thanks!

                              • 57. Re: XPath Routing
                                tfennelly

                                 

                                "ldimaggi@redhat.com" wrote:
                                Just to confirm, these changes should have no impact to existing configurations and .esb's that make use of content based routing? (aka no migration)


                                That's correct.

                                "ldimaggi@redhat.com" wrote:
                                And - the ESB (eclipse) editor will be upated to handle the changes when 4.7 goes GA?


                                I believe so :)

                                • 58. Re: XPath Routing
                                  bfitzpat

                                  Tom, do we have a JIRA created yet for this new ESB Xpath routing to get it into the ESB configuration editor? Or do we need to create one?
                                  --Fitz

                                  • 59. Re: XPath Routing
                                    tfennelly

                                     

                                    "bfitzpat" wrote:
                                    Tom, do we have a JIRA created yet for this new ESB Xpath routing to get it into the ESB configuration editor? Or do we need to create one?
                                    --Fitz


                                    Good question Brian... not sure what the procedure has been up to this. Kev?