1 Reply Latest reply on Jul 23, 2015 7:51 PM by Tomohisa igarashi

    SwitchYard. Injecting property into Java Transformer

    Kuat Ospanov Newbie


      I am trying to load property value from file which was included in switchyard.xml as :


          <sy:properties load="file:///opt/wildfly/modules/system/layers/base/kz/configuration/config.properties"/>


      I can get property values in Camel route using this syntax:


      But I couldn`t inject that property in my Java transformer. My goal is to be able to get property value

        @Transformer(to = "java:kz.RefillForPrepaid")

          public RefillForPrepaid transformPayEventToRefillForPrepaid(

                  kz.PayEvent from) {

              RefillForPrepaid rqu = new RefillForPrepaid();


      Please, help me to resolve this issue.

      P.s. I am using Wildlfly 8.1, Switchyard is 2.0.0.Beta1.

        • 1. Re: SwitchYard. Injecting property into Java Transformer
          Tomohisa igarashi Master

          Property injection is only available for implementation (bean, camel, bpel, rule, bpm) at this moment. But making domain property visible to transformers/validators sounds interesting. Please feel free to file a feature request JIRA with detailed usecase. BTW, SY2.0 have some issues to run on WildFly 8.1. You may want to use WildFly 8.0 instead for now or just wait for next follow up SY release supporting later WildFly version.