6 Replies Latest reply on May 27, 2008 12:34 AM by (Rui_Esteves)

    Component gives different result when imported into workbench

      Hi all, I have this issue that i've made a component that works great as a standalone java app (public static void main() etc), i get the results that I expect. But as soon as I import it into workbench, it doesn't give the same results. Namely, I'm trying to get a list of tasks which i successfuly get through the standalone instance. But when its imported into workbench i get the wrong result (a task list of size 0).

      Has anyone ever come accross something like this or have an idea of what might be going on? There are no exceptions or anything so i'm stumped :S
        • 1. Re: Component gives different result when imported into workbench
          Level 1
          Just thought i should update, i've got it working on my s erver now, i just changed the connection properties from soap to ejb, and it works. the weird thing it won't work if i run it as a stand alone java app with the connection of ejb and my LC server is on a different machine.

          Not sure of the explaination, would appreciate it if anyone had one for me. Could it be a firewall issue?
          • 2. Re: Component gives different result when imported into workbench
            Level 1
            Can you post the error and the connection properties you're using?
            • 3. Re: Component gives different result when imported into workbench
              Level 1
              sure,i was just reading your post infact, lol

              My connection properties is like so;

              ==============================
              Properties ConnectionProps = new Properties();
              ConnectionProps.setPropert
              ("DSC_DEFAULT_EJB_ENDPOINT", "jnp://wfdev:1099");
              ConnectionProps.setProperty("DSC_TRANSPORT_PROTOCOL","EJB");
              ConnectionProps.setProperty("DSC_SERVER_TYPE", "JBoss");
              ConnectionProps.setProperty
              ("DSC_CREDENTIAL_USERNAME", "administrator");
              ConnectionProps.setProperty("DSC_CREDENTIAL_PASSWORD", "password");
              ==============================

              So as you can see, my server is remote, so rather than using local host i put the server name. This is when i'm using ejb and for some reason when i run it locally as a stand alone app i get a connection error but when i import it into workbench it works fine. This is the error i get when i run it as a stand alone;

              ============================== [com.adobe.livecycle.usermanager.client.DirectoryManagerServiceClient] errorCode:16385 errorCodeHEX:0x4001 message:Exception thrown is NOT a DSCException : UnExpected From DSC chainedException:java.lang.IllegalStateExceptionchainedExceptionMessage:null chainedException trace:java.lang.IllegalStateException
              at com.adobe.idp.dsc.clientsdk.ServiceClientFactory$1.handleThrowable(ServiceClientFactory.j ava:68)
              at com.adobe.idp.dsc.clientsdk.ServiceClient.invoke(ServiceClient.java:220)
              at com.adobe.livecycle.usermanager.client.DirectoryManagerServiceClient.findPrincipals(Direc toryManagerServiceClient.java:840)
              at com.adobe.sample.taskmanager.RetrieveTaskInfo.main(RetrieveTaskInfo.java:65)
              Caused by: java.lang.NoClassDefFoundError: javax/ejb/EJBException
              at com.adobe.idp.dsc.clientsdk.ServiceClientFactory.evaluateMessageDispatcher(ServiceClientF actory.java:512)
              at com.adobe.idp.dsc.clientsdk.ServiceClient.invoke(ServiceClient.java:215)
              ... 2 more

              at com.adobe.livecycle.usermanager.client.ManagerServiceClient.throwNonUMExceptionAsUMExcept ion(ManagerServiceClient.java:53)
              at com.adobe.livecycle.usermanager.client.ManagerServiceClient.handleException(ManagerServic eClient.java:95)
              at com.adobe.livecycle.usermanager.client.DirectoryManagerServiceClient.findPrincipals(Direc toryManagerServiceClient.java:844)
              at com.adobe.sample.taskmanager.RetrieveTaskInfo.main(RetrieveTaskInfo.java:65)
              ==============================

              But when i switch it around to SOAP, it works as a stand alone app, but not when i import it into workbench. The log shows this when i run it.

              ==============================
              2008-05-26 10:15:04,567 INFO [STDOUT] | [com.adobe.livecycle.usermanager.client.DirectoryManagerServiceClient] errorCode:16385 errorCodeHEX:0x4001 message:Exception thrown is NOT a DSCException : UnExpected From DSC chainedException:ALC-DSC-217-000: com.adobe.idp.dsc.DSCRuntimeException: Could not create/start dispatcher class com.adobe.idp.dsc.provider.impl.soap.axis.sdk.SoapAxisDispatcher for protocol: SOAP chainedExceptionMessage:Could not create/start dispatcher class com.adobe.idp.dsc.provider.impl.soap.axis.sdk.SoapAxisDispatcher for protocol: SOAP chainedException trace:ALC-DSC-217-000: com.adobe.idp.dsc.DSCRuntimeException: Could not create/start dispatcher class com.adobe.idp.dsc.provider.impl.soap.axis.sdk.SoapAxisDispatcher for protocol: SOAP
              at com.adobe.idp.dsc.clientsdk.ServiceClientFactory.createMessageDispatcher(ServiceClientFac tory.java:551)
              at com.adobe.idp.dsc.clientsdk.ServiceClientFactory.getMessageDispatcher(ServiceClientFactor y.java:497)
              at com.adobe.idp.dsc.clientsdk.ServiceClient.getMessageDispatcher(ServiceClient.java:239)
              at com.adobe.idp.dsc.clientsdk.ServiceClient.invoke(ServiceClient.java:205)
              at com.adobe.livecycle.usermanager.client.DirectoryManagerServiceClient.findPrincipals(Direc toryManagerServiceClient.java:840)
              at helloComponent.hi(helloComponent.java:45)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:585)
              at com.adobe.idp.dsc.component.impl.DefaultPOJOInvokerImpl.invoke(DefaultPOJOInvokerImpl.jav a:181)
              at com.adobe.idp.dsc.interceptor.impl.InvocationInterceptor.intercept(InvocationInterceptor. java:134)
              at com.adobe.idp.dsc.interceptor.impl.RequestInterceptorChainImpl.proceed(RequestInterceptor ChainImpl.java:44)
              at com.adobe.idp.dsc.transaction.interceptor.TransactionInterceptor$1.doInTransaction(Transa ctionInterceptor.java:74)
              at com.adobe.idp.dsc.transaction.impl.ejb.adapter.EjbTransactionCMTAdapterBean.execute(EjbTr ansactionCMTAdapterBean.java:336)
              at com.adobe.idp.dsc.transaction.impl.ejb.adapter.EjbTransactionCMTAdapterBean.doSupports(Ej bTransactionCMTAdapterBean.java:212)
              .....etc, etc
              ==============================

              There is no "caused by" line in the log or anything like that, and my component actually does return something workbench, just not the result that i expected. Hopefully you'll be able to find something helpful in there.
              • 4. Re: Component gives different result when imported into workbench
                Level 1
                When you invoke the services in a Java APP using EJBs the libraries needed are different.<br /><br />AFAIK you need the following (using JBoss, and it seem you use JBoss)<br /><br />- adobe-<service_you're_using>-client.jar<br />- adobe-livecycle-client.jar<br />- adobe-usermanager-client.jar<br />- adobe-usermanager-util-client.jar<br />- adobe-utilities.jar<br />- adobe-pdfutility-client.jar<br />- jbossall-client.jar<br /><br />if i remove some of these jars from my CP i get a similar error to the one you have.<br /><br />As for the SOAP one TBH i haven't gone there yet.
                • 5. Re: Component gives different result when imported into workbench
                  Level 1
                  yea, i have all of thos jar files, and a jar file for each of the services i'm using (eg taskmanager, usermanager, etc). I also referenced the jars in the component.xml file. Did the webservice end up working for you?
                  • 6. Re: Component gives different result when imported into workbench
                    Level 1
                    I still haven't tried WebServices.
                    I've mailed Adobe's support on the issue and i'm waiting for a reply on it.

                    I'll post it when (if) i get one.