2 Replies Latest reply on Jun 4, 2013 6:31 AM by kenfinni

    Is there any PortletBridge dependency req? to use Switchyard& CDI in GateIn portal

    maran_su

      Hi,

        

           I am using Switchyard service and CDI injection in GateIn portlet,

      is there any portlet Bridge Dependency i need to add in order to support Switchyard and CDI,

       

      i have used following dependency in my Pom.XML

       

      i am able to deploy switchyard in normal webApp but when i integrate it in to Gate In , Switchyard is not deploying please can any one give me answer.

       

       

       

        <dependency>
            <groupId>org.gatein</groupId>
            <artifactId>cdi-portlet-integration</artifactId>
            <version>1.0.0.Final</version>
          </dependency>
          <dependency>
            <groupId>javax.inject</groupId>
            <artifactId>javax.inject</artifactId>
            <version>1</version>
          </dependency>
          <dependency>
            <groupId>javax.enterprise</groupId>
            <artifactId>cdi-api</artifactId>
            <version>1.0-SP2</version>
          </dependency>
          <dependency>
            <groupId>org.switchyard.components</groupId>
            <artifactId>switchyard-component-bean</artifactId>
             <version>0.8.0.Final</version>
             <scope>provided</scope>
          </dependency>
          <dependency>
            <groupId>org.switchyard.components</groupId>
            <artifactId>switchyard-component-http</artifactId>
            <version>0.8.0.Final</version>
            <scope>provided</scope>
          </dependency>
          <dependency>
            <groupId>org.switchyard</groupId>
            <artifactId>switchyard-config</artifactId>
             <version>0.8.0.Final</version>
             <scope>provided</scope>
          </dependency>
          
      <dependency>
          <groupId>org.switchyard</groupId>
          <artifactId>switchyard-deploy-webapp</artifactId>
          <version>0.8.0.Final</version> <!-- SwitchYard release version e.g. 0.3.0 -->
      </dependency>
      
        • 1. Re: Is there any PortletBridge dependency req? to use Switchyard& CDI in GateIn portal
          maran_su

          Hi,

           

            I am getting this exception when i call the webService Proxy through SwitchYard in Gatein Jboss As7

           

          do i need to include any Portlet bridge depencey or Listner  for switchyard?

           

           

          Caused by: javax.portlet.faces.BridgeException: javax.faces.FacesException: java.lang.reflect.UndeclaredThrowableException

                  at org.jboss.portletbridge.bridge.controller.Jsf20ControllerImpl.throwBridgeException(Jsf20ControllerImpl.java:651)

                  at org.jboss.portletbridge.bridge.controller.Jsf20ControllerImpl.processPortletAction(Jsf20ControllerImpl.java:129)

                  at org.jboss.portletbridge.PortletBridgeImpl.doFacesRequest(PortletBridgeImpl.java:227)

                  at javax.portlet.faces.GenericFacesPortlet.processAction(GenericFacesPortlet.java:454)

                  ... 118 more

          Caused by: javax.faces.FacesException: java.lang.reflect.UndeclaredThrowableException

                  at com.sun.faces.context.ExceptionHandlerImpl.handle(ExceptionHandlerImpl.java:142) [jsf-impl-2.1.7-jbossorg-2.jar:]

                  at org.jboss.portletbridge.context.exception.PortletExceptionHandler.handle(PortletExceptionHandler.java:95)

                  at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:119) [jsf-impl-2.1.7-jbossorg-2.jar:]

                  at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118) [jsf-impl-2.1.7-jbossorg-2.jar:]

                  at org.jboss.portletbridge.bridge.controller.Jsf20ControllerImpl.processPortletAction(Jsf20ControllerImpl.java:123)

                  ... 120 more

          Caused by: javax.faces.el.EvaluationException: java.lang.reflect.UndeclaredThrowableException

                  at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102) [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final]

                  at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102) [jsf-impl-2.1.7-jbossorg-2.jar:]

                  at javax.faces.component.UICommand.broadcast(UICommand.java:315) [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final]

                  at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:794) [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final]

                  at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1259) [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final]

                  at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:81) [jsf-impl-2.1.7-jbossorg-2.jar:]

                  at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) [jsf-impl-2.1.7-jbossorg-2.jar:]

                  ... 122 more

          Caused by: java.lang.reflect.UndeclaredThrowableException

                  at $Proxy132.call(Unknown Source)       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.7.0_10]

                  at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) [rt.jar:1.7.0_10]

                  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_10]

                  at java.lang.reflect.Method.invoke(Method.java:601) [rt.jar:1.7.0_10]

                  at org.jboss.weld.bean.proxy.AbstractBeanInstance.invoke(AbstractBeanInstance.java:44) [weld-core-1.1.0.Final.jar:2011-01-14 16:44]

                  at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:105) [weld-core-1.1.0.Final.jar:2011-01-14 16:44]

                  at org.jboss.weld.proxies.PerlService$1366014918$Proxy$_$$_WeldClientProxy.call(PerlService$1366014918$Proxy$_$$_WeldClientProxy.java)

                  at org.molplexdrug.Action.SearchBean.call(SearchBean.java:52)

                  at org.molplexdrug.Action.SearchBean$Proxy$_$$_WeldClientProxy.call(SearchBean$Proxy$_$$_WeldClientProxy.java)

                  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.7.0_10]

                  at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) [rt.jar:1.7.0_10]

                  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_10]

                  at java.lang.reflect.Method.invoke(Method.java:601) [rt.jar:1.7.0_10]

                  at org.jboss.el.util.ReflectionUtil.invokeMethod(ReflectionUtil.java:335) [jboss-el-1.0_02.CR6.jar:1.0_02.CR6]

                  at org.jboss.el.util.ReflectionUtil.invokeMethod(ReflectionUtil.java:348) [jboss-el-1.0_02.CR6.jar:1.0_02.CR6]

                  at org.jboss.el.parser.AstPropertySuffix.invoke(AstPropertySuffix.java:58) [jboss-el-1.0_02.CR6.jar:1.0_02.CR6]

                  at org.jboss.el.parser.AstValue.invoke(AstValue.java:96) [jboss-el-1.0_02.CR6.jar:1.0_02.CR6]

                  at org.jboss.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276) [jboss-el-1.0_02.CR6.jar:1.0_02.CR6]

                  at com.sun.faces.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:105) [jsf-impl-2.1.7-jbossorg-2.jar:]

                  at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88) [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final]

                  ... 128 more

          Caused by: org.switchyard.component.bean.BeanComponentException: A service reference to service 'PerlService' is not bound into this client proxy instance.  A reference configuration to the service may be required in the application configuration.

                  at org.switchyard.component.bean.ClientProxyBean$ClientProxyInvocationHandler.invoke(ClientProxyBean.java:274) [switchyard-component-bean-0.8.0.Final.jar:0.8.0.Final]

                  ... 149 more

           

           

          attached my effective pom.xml

          • 2. Re: Is there any PortletBridge dependency req? to use Switchyard& CDI in GateIn portal
            kenfinni

            From that stacktrace it looks like the root cause exception, at the bottom, is possibly a misconfiguration of SwitchYard, as it mentions the service not being bound to the client proxy instance.