2 Replies Latest reply on Oct 24, 2007 4:52 PM by Eric Cartman

    ESB Design & Patterns

    Eric Cartman Newbie


      I´m learning JBossESB to use it with a Project.

      I've already tested JBossESB with JBpm, Groovy, Smooks (freemaker), and Drools... so I´m getting the general idea.... and now I'm seeing the long run.

      1) ... the questions is.... what is a Service / Message ? I know the simple answer.

      What I need to know is.... Is there ONLY one message traveling between all services ? or do you divide a message every time a service has to use only a property ?

      2) If you have to divide / merge a message, do you have to do it by hand ?

      Several actions (ex Smooks) assume the transformation applies to the BODY.... so I'm guessing It's very usual to create a message from a property to send it to another service, Do you have to do it by hand with and Action ? with Groovy ?


      At the end, besides Quickstarts and Manuals, I'm looking to learn from patterns.


      Thanks in Advance,
      Eric

        • 1. Re: ESB Design & Patterns
          Burr Sutter Master

          I'll try to answer your questions, other members of the team may have some enhancements to my responses.


          What I need to know is.... Is there ONLY one message traveling between all services ?

          Yes and No. It depends on how the services are invoked. If it is the FTP gateway then the single message represents a single file and that message travels through all services that are routed/orchestrated to/through.


          or do you divide a message every time a service has to use only a property ?

          No, we do not automatically divide a message, you would have to programmatically in a custom action and/or service.



          If you have to divide / merge a message, do you have to do it by hand ?


          You might review the splitter & aggregator action sources to see how it manages something similiar to this concept. However, it is pretty easy to build your own action that peels off a piece of a message, making a new message out of that part, sending it to a particular service (or list of services) and then having an "aggregation" service that waits for all responses.
          You might even use jBPM to orchestrate this flow as well.


          Do you have to do it by hand with and Action ? with Groovy ?


          Either would work.



          • 2. Re: ESB Design & Patterns
            Eric Cartman Newbie

            Ok, I see ....


            I'm designing a Content Management Bus, where we have several sources, injecting content messages.

            We route messages to formatters, and after that to several publishers.

            The formatters work with Smooks and Freemaker. Here, the first transformation, from a property to the body and back.

            The messages have to be arranged to be published, second transformation.


            At first view, It seems that the best way It's to orchestrate all the simultaneous flows around JBpm, and leave ESB to mange the inputs, transfomations, and outputs.

            In this way, I think we can easily integrate several sources, transformations, and destinations.

            1. At ESB level, there's no service with chained actions.
            2. Input services receive messages and transfer them to jBpm.
            3. Transformation services, receive the msgs from JBpm and return them.
            4. Output services receive messages and publish them.


            Is there any source of patterns / heuristics design with setups like this ?


            PD: I think, as simpler alternative may be to replace JBpm with Drools or Groovy.

            Thanks
            Eric