3 Replies Latest reply on Feb 12, 2020 5:49 AM by Bipin RajalingamS

    BES -EJB

    Mohd Zafar Active Member

      I am having trouble making EJB call with BES. I used the sample from the resource kit, its getting error while creating the helperContext

      Has anyone implemented it and can help me here. I am using 10.2 on WL server

       

      Error :

      Exception in thread "main" java.lang.NoSuchMethodError: org.eclipse.persistence.sdo.helper.SDOHelperContext.getHelperContextResolver()Lorg/eclipse/persistence/sdo/helper/SDOHelperContext$HelperContextResolver;

      at com.siperian.common.xml.sdo.HelperContextFactory.getHelperContextReloadIfNeeded(HelperContextFactory.java:41)

      at com.informatica.mdm.cs.client.CompositeServiceClient.getSDOHelperContext(CompositeServiceClient.java:112)

      at com.informatica.mdm.cs.client.CompositeServiceClient.getHelperContext(CompositeServiceClient.java:107)

      at com.informatica.mdm.sample.cs.DynamicSDO2.main(DynamicSDO2.java:40)

       

       

      code snippet:

       

       

       

       

      package com.informatica.mdm.sample.cs;

       

       

      import java.util.Properties;

       

       

      import com.informatica.mdm.cs.CallContext;

      import com.informatica.mdm.cs.api.CompositeServiceException;

      import com.informatica.mdm.cs.client.CompositeServiceClient;

       

       

      import commonj.sdo.Type;

      import commonj.sdo.helper.DataFactory;

      import commonj.sdo.helper.HelperContext;

       

       

      public class DynamicSDO2 {

       

       

          public static void main(String[] args) throws CompositeServiceException {

              String systemName = "Admin";

              Properties config = new Properties();

              config.put("siperian-client.protocol", "ejb");

              config.put("siperian-client.orsId", "poc-ors");

              config.put("siperian-client.username", "poc-user");

              config.put("siperian-client.password", "poc-pass");

              config.put("java.naming.provider.url", "t3://server:8001/");

              config.put("java.naming.factory.initial", "weblogic.jndi.WLInitialContextFactory");

              config.put("java.naming.factory.url.pkgs", "weblogic");

            

              CompositeServiceClient client = CompositeServiceClient.newCompositeServiceClient(config);

              System.out.println("Client created");

              CallContext callContext = new CallContext(config.getProperty("siperian-client.orsId"), config.getProperty("siperian-client.username"), config.getProperty("siperian-client.password"));

              HelperContext helperContext = client.getHelperContext(callContext);

              DataFactory dataFactory = helperContext.getDataFactory();

              Type writePersonType = helperContext.getTypeHelper().getType("urn:cs-ors.informatica.mdm", "WriteAccountView");

          }

      }