4 Replies Latest reply on Jun 13, 2013 2:41 PM by rcernich

    Switchyard project organization question

    dustin.barlow

      What are the best practices when organizing Switchyard projects?  Is it best practice to just have one promoted process per project?  Is it ok to have mutliple processes promoted into mutliple service end-points with multiple bindings within a single project?  Does it really matter either way?

        • 1. Re: Switchyard project organization question
          kcbabo

          No hard and fast rule here, but it pays to think of an application in SY as a unit of modularization.  With that in mind, some considerations:

           

          • The greater the number of services in a project, the more likely that a deployment will have to change when one of the services is updated.
          • Transformers and validators are currently scoped to an application, so if you are using a transformation in multiple services then you need to define it for each application it's used in.
          • If there are resources (e.g. Java classes, WSDLs, etc.) used by multiple services in an application, they can all go in the same deployment.  If they are split up amongst multiple deployments, then it's best to isolate the shared artifacts and deploy them separately.

           

          Those are just a few examples.  Overall, it's a balance between convenience (everything in a single app) and deployment flexibility (split across multiple apps).

          1 of 1 people found this helpful
          • 2. Re: Switchyard project organization question
            dustin.barlow

            Thanks Keith for the insight.  I had guessed the answer would be just as you stated.  However, I just wanted to confirm my suspicions since the included quickstarts and demos are all pretty basic demos of singular capabilities of Switchyard (as one would expect).

             

            I also haven't really found any full blown implementations in Switchard to analyse how they were organized so I was really curious to know what people thought or perhaps had first hand experience when it comes to the not so obvious pros and cons with doing very granualar deployments versus more monolithic style ones in Switchyard.

             

            If there are additional opinions or comments on the topic, I'd love to hear other's experiences as well.

            • 3. Re: Switchyard project organization question
              magick93

              Transformers and validators are currently scoped to an application, so if you are using a transformation in multiple services then you need to define it for each application it's used in.

               

              Are there any plans to allow for common Transforms and Validators across mulitple SY projects?

              • 4. Re: Switchyard project organization question
                rcernich

                Hey Anton,

                Anton Hughes wrote:

                 

                Are there any plans to allow for common Transforms and Validators across mulitple SY projects?

                I believe this should be possible today, but you would have to declare the transformers manually in the switchyard.xml file (i.e. the scanner won't automatically add them to the config).  There may be some issues adding an existing Java transformer to the configuration.  Please file a JIRA if there are issues with this.

                 

                Hope that helps,

                Rob