EJB handle containing t3://null:7001

I'm working on a cluster, using in-memory replication, on SunOs 5.6 (WLS
          5.01 sp1).
          I've 102 stateless session bean, and only 1 stateful.
          The stateful has in weblogic-ejb-home.xml the following:
          <weblogic-ejb-jar>
          <weblogic-enterprise-bean>
          <ejb-name>europortal.architecture.Customer.CustomerSession</ejb-name>
          <caching-descriptor>
          <max-beans-in-cache>100</max-beans-in-cache>
          <idle-timeout-seconds>10</idle-timeout-seconds>
          </caching-descriptor>
          <clustering-descriptor>
          <home-is-clusterable>True</home-is-clusterable>
          <home-load-algorithm>round-robin</home-load-algorithm>
          </clustering-descriptor>
          <jndi-name>europortal.architecture.Customer.CustomerSession</jndi-name>
          </weblogic-enterprise-bean>
          </weblogic-ejb-jar>
          I deploy all of the beans on both the instance of the cluster.
          The jsp using the stateful bean get the following error:
          java.rmi.NoSuchObjectException: Unable to locate
          EJBHome:
          'europortal.architecture.Customer.CustomerSession' on
          server: 't3://null:7001
          at java.lang.Throwable.fillInStackTrace(Native
          Method)
          at
          java.lang.Throwable.fillInStackTrace(Compiled Code)
          at java.lang.Throwable.<init>(Compiled Code)
          at java.lang.Exception.<init>(Compiled Code)
          at java.io.IOException.<init>(Compiled Code)
          at
          java.rmi.RemoteException.<init>(RemoteException.java:56)
          at
          java.rmi.NoSuchObjectException.<init>(NoSuchObjectException.java:50)
          at
          weblogic.ejb.internal.HomeHandleImpl.getEJBHome(HomeHandleImpl.java:68)
          at
          weblogic.ejb.internal.HandleImpl.getEJBObject(Compiled
          Code)
          at
          europortal.architecture.Customer.CustomerSessionWrapper.getFreePagesServiceL
          abel(CustomerSessionWrapper.java:261)
          at
          jsp_servlet._NASApp._EPApps._priveligeManager._jspService(Compiled
          Code)
          at
          weblogic.servlet.jsp.JspBase.service(Compiled Code)
          at
          weblogic.servlet.internal.ServletStubImpl.invokeServlet(Compiled
          Code)
          at
          weblogic.servlet.internal.ServletStubImpl.invokeServlet(Compiled
          Code)
          at
          weblogic.servlet.internal.RequestDispatcherImpl.include(Compiled
          Code)
          at
          weblogic.servlet.internal.RequestDispatcherImpl.include(Compiled
          Code)
          at EPApps.mainProcess.service(Compiled Code)
          at
          javax.servlet.http.HttpServlet.service(Compiled Code)
          at
          weblogic.servlet.internal.ServletStubImpl.invokeServlet(Compiled
          Code)
          at
          weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
          l.java:742)
          at
          weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
          l.java:686)
          at
          weblogic.servlet.internal.ServletContextManager.invokeServlet(ServletContext
          Manager.java:247)
          at
          weblogic.socket.MuxableSocketHTTP.invokeServlet(MuxableSocketHTTP.java:363)
          at
          weblogic.socket.MuxableSocketHTTP.execute(Compiled
          Code)
          at weblogic.kernel.ExecuteThread.run(Compiled
          Code),
          while using the handle of the ejb and, finding it == null, tries to start
          again from the lookup.
          I've serialized the handle on a file, as soon as it was created, and inside
          it I can read the following:
          t3://null:7001 (it's not ASCII, but you can read it)
          It looks like an error in getting the address of the server...
          But everything works fine when I use a single WLS instance without cluster.
          Anyone can help?
          I enclose the code (CustomerSessionWrapper.java)
          [CustomerSessionWrapper.java]
          

I checked with the developer on this and he says that you forgot to set
          weblogic.cluster.dnsName property. Please refer to the ejb documentation for more info on this.
          - Prasad
          Luca Relandini wrote:
          > I'm working on a cluster, using in-memory replication, on SunOs 5.6 (WLS
          > 5.01 sp1).
          > I've 102 stateless session bean, and only 1 stateful.
          > The stateful has in weblogic-ejb-home.xml the following:
          > <weblogic-ejb-jar>
          > <weblogic-enterprise-bean>
          > <ejb-name>europortal.architecture.Customer.CustomerSession</ejb-name>
          > <caching-descriptor>
          > <max-beans-in-cache>100</max-beans-in-cache>
          > <idle-timeout-seconds>10</idle-timeout-seconds>
          > </caching-descriptor>
          > <clustering-descriptor>
          > <home-is-clusterable>True</home-is-clusterable>
          > <home-load-algorithm>round-robin</home-load-algorithm>
          > </clustering-descriptor>
          > <jndi-name>europortal.architecture.Customer.CustomerSession</jndi-name>
          > </weblogic-enterprise-bean>
          > </weblogic-ejb-jar>
          >
          > I deploy all of the beans on both the instance of the cluster.
          > The jsp using the stateful bean get the following error:
          >
          > java.rmi.NoSuchObjectException: Unable to locate
          > EJBHome:
          > 'europortal.architecture.Customer.CustomerSession' on
          > server: 't3://null:7001
          > at java.lang.Throwable.fillInStackTrace(Native
          > Method)
          > at
          > java.lang.Throwable.fillInStackTrace(Compiled Code)
          > at java.lang.Throwable.<init>(Compiled Code)
          > at java.lang.Exception.<init>(Compiled Code)
          > at java.io.IOException.<init>(Compiled Code)
          > at
          > java.rmi.RemoteException.<init>(RemoteException.java:56)
          > at
          > java.rmi.NoSuchObjectException.<init>(NoSuchObjectException.java:50)
          > at
          > weblogic.ejb.internal.HomeHandleImpl.getEJBHome(HomeHandleImpl.java:68)
          > at
          > weblogic.ejb.internal.HandleImpl.getEJBObject(Compiled
          > Code)
          > at
          > europortal.architecture.Customer.CustomerSessionWrapper.getFreePagesServiceL
          > abel(CustomerSessionWrapper.java:261)
          > at
          > jsp_servlet._NASApp._EPApps._priveligeManager._jspService(Compiled
          > Code)
          > at
          > weblogic.servlet.jsp.JspBase.service(Compiled Code)
          > at
          > weblogic.servlet.internal.ServletStubImpl.invokeServlet(Compiled
          > Code)
          > at
          > weblogic.servlet.internal.ServletStubImpl.invokeServlet(Compiled
          > Code)
          > at
          > weblogic.servlet.internal.RequestDispatcherImpl.include(Compiled
          > Code)
          > at
          > weblogic.servlet.internal.RequestDispatcherImpl.include(Compiled
          > Code)
          > at EPApps.mainProcess.service(Compiled Code)
          > at
          > javax.servlet.http.HttpServlet.service(Compiled Code)
          > at
          > weblogic.servlet.internal.ServletStubImpl.invokeServlet(Compiled
          > Code)
          > at
          > weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
          > l.java:742)
          > at
          > weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
          > l.java:686)
          > at
          > weblogic.servlet.internal.ServletContextManager.invokeServlet(ServletContext
          > Manager.java:247)
          > at
          > weblogic.socket.MuxableSocketHTTP.invokeServlet(MuxableSocketHTTP.java:363)
          > at
          > weblogic.socket.MuxableSocketHTTP.execute(Compiled
          > Code)
          > at weblogic.kernel.ExecuteThread.run(Compiled
          > Code),
          >
          > while using the handle of the ejb and, finding it == null, tries to start
          > again from the lookup.
          > I've serialized the handle on a file, as soon as it was created, and inside
          > it I can read the following:
          > t3://null:7001 (it's not ASCII, but you can read it)
          > It looks like an error in getting the address of the server...
          >
          > But everything works fine when I use a single WLS instance without cluster.
          > Anyone can help?
          > I enclose the code (CustomerSessionWrapper.java)
          >
          > Name: CustomerSessionWrapper.java
          > CustomerSessionWrapper.java Type: Java file (application/x-unknown-content-type-VisualCafeFile.Document)
          > Encoding: x-uuencode
          

Similar Messages

  • EJB Handle deserialization ....

    Hi,
    I am running Weblogic Server 8 SP2 with the supplied ejb20_basic_statefulSession example.
    <p>
    My client is a webapp installed on Tomcat and is using the ejb20_basic_statefulSession_client.jar, together with the WebLogic's wlclient.jar. I can successfully invoke the methods (buy, sell, getBalance) and get back the expected results.
    <p>
    Now the problem. I am storing an object containing an EJBHandle to the Trader SFSB in a HTTPSession. Upon HTTPSession passivation, the EJB Handle is serialized out. However, upon HTTPSession activation, deserialization fails and I am getting the following exception:
    <p>
    Error deserializing Session 5E343833AA1183690C6895162B69E1D1.localhost:8005: java.lang.ClassNotFoundException: <b>examples.ejb20.basic.statefulSession._Trader_Stub</b>
    <p>
    The funny thing is that I cannot find the class <b>examples.ejb20.basic.statefulSession._Trader_Stub</b> anywhere. It is not generated by wlappc.
    <p>
    I have tried writeObject()/readObject() and HttpSessionBindingListener's valueBound()/valueUnbound(), but I am still getting the same error.
    Would appreciate any input. Thanks.
    Regards,
    Eric

    Hi getting the below error deserilising the EJBObject after serilizaion.
    Below is the code to obtain it
    ==============================================
    FileInputStream fis = new FileInputStream ("d:/beaexam/serial");
    ObjectInputStream ois = new ObjectInputStream(fis);
    SecondLocal learnLocal1 = null;
    Handle handle = (Handle)ois.readObject();
    ==============================================
    java.lang.ExceptionInInitializerError
    at weblogic.ejb20.internal.HandleImpl.readExternal(HandleImpl.java:99)
    at java.io.ObjectInputStream.readExternalData(Unknown Source)
    at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
    at java.io.ObjectInputStream.readObject0(Unknown Source)
    at java.io.ObjectInputStream.readObject(Unknown Source)
    at EJBClientHandle.main(EJBClientHandle.java:14)
    Caused by: java.lang.NullPointerException
    at weblogic.rmi.utils.io.RemoteObjectReplacer.<clinit>(RemoteObjectRepla
    cer.java:47)
    ... 6 more

  • Does not contain port: null

    Hi there,
    I had deployed 2 web services, one of it is working another one isn't. Both of the web services implementing the same/identical ways. The exception i got it:
    service: {http://localhost:8080/}ORMEngineService does not contain port: null
         at com.sun.xml.rpc.client.dii.ConfiguredService.portNotFoundException(ConfiguredService.java:139)
         at com.sun.xml.rpc.client.dii.ConfiguredService.getPortInfo(ConfiguredService.java:132)
         at com.sun.xml.rpc.client.dii.ConfiguredService.getPort(ConfiguredService.java:245)
         at com.sun.xml.rpc.client.dii.ConfiguredService.getPort(ConfiguredService.java:152)
         at gov.mohr.ems.core.entity.logic.ORMEngineWebServicesTest.test1(ORMEngineWebServicesTest.java:59)
         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 junit.framework.TestCase.runTest(TestCase.java:154)
         at junit.framework.TestCase.runBare(TestCase.java:127)
         at junit.framework.TestResult$1.protect(TestResult.java:106)
         at junit.framework.TestResult.runProtected(TestResult.java:124)
         at junit.framework.TestResult.run(TestResult.java:109)
         at junit.framework.TestCase.run(TestCase.java:118)
         at junit.framework.TestSuite.runTest(TestSuite.java:208)
         at junit.framework.TestSuite.run(TestSuite.java:203)
    ...Below are my references:
    1. mapping file:
    <?xml version="1.0" encoding="UTF-8"?>
    <java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
      <package-mapping>
        <package-type>gov.mohr.ems.core.entity.logic</package-type>
        <namespaceURI>http://localhost:8080/types</namespaceURI>
      </package-mapping>
      <package-mapping>
        <package-type>gov.mohr.ems.core.entity.logic</package-type>
        <namespaceURI>http://localhost:8080/</namespaceURI>
      </package-mapping>
      <service-interface-mapping>
        <service-interface>gov.mohr.ems.core.entity.logic.ORMEngineService</service-interface>
        <wsdl-service-name xmlns:serviceNS="http://localhost:8080/">serviceNS:ORMEngineService</wsdl-service-name>
        <port-mapping>
          <port-name>ORMEngineServiceEndpointPort</port-name>
          <java-port-name>ORMEngineServiceEndpointPort</java-port-name>
        </port-mapping>
      </service-interface-mapping>
      <service-endpoint-interface-mapping>
        <service-endpoint-interface>gov.mohr.ems.core.entity.logic.ORMEngineServiceEndpoint</service-endpoint-interface>
        <wsdl-port-type xmlns:portTypeNS="http://localhost:8080/">portTypeNS:ORMEngineServiceEndpoint</wsdl-port-type>
        <wsdl-binding xmlns:bindingNS="http://localhost:8080/">bindingNS:ORMEngineServiceEndpointBinding</wsdl-binding>
        <service-endpoint-method-mapping>
          <java-method-name>executeQuery</java-method-name>
          <wsdl-operation>executeQuery</wsdl-operation>
          <method-param-parts-mapping>
            <param-position>0</param-position>
            <param-type>java.lang.String</param-type>
            <wsdl-message-mapping>
              <wsdl-message xmlns:wsdlMsgNS="http://localhost:8080/">wsdlMsgNS:ORMEngineServiceEndpoint_executeQuery</wsdl-message>
              <wsdl-message-part-name>String_1</wsdl-message-part-name>
              <parameter-mode>IN</parameter-mode>
            </wsdl-message-mapping>
          </method-param-parts-mapping>
          <wsdl-return-value-mapping>
            <method-return-value>java.lang.String</method-return-value>
            <wsdl-message xmlns:wsdlMsgNS="http://localhost:8080/">wsdlMsgNS:ORMEngineServiceEndpoint_executeQueryResponse</wsdl-message>
            <wsdl-message-part-name>result</wsdl-message-part-name>
          </wsdl-return-value-mapping>
        </service-endpoint-method-mapping>
      </service-endpoint-interface-mapping>
    </java-wsdl-mapping>2. WSDL file:
    <?xml version="1.0" encoding="UTF-8"?>
    <definitions name="ORMEngineService" targetNamespace="http://localhost:8080/" xmlns:tns="http://localhost:8080/" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
      <types/>
      <message name="ORMEngineServiceEndpoint_executeQuery">
        <part name="String_1" type="xsd:string"/></message>
      <message name="ORMEngineServiceEndpoint_executeQueryResponse">
        <part name="result" type="xsd:string"/></message>
      <portType name="ORMEngineServiceEndpoint">
        <operation name="executeQuery" parameterOrder="String_1">
          <input message="tns:ORMEngineServiceEndpoint_executeQuery"/>
          <output message="tns:ORMEngineServiceEndpoint_executeQueryResponse"/></operation></portType>
      <binding name="ORMEngineServiceEndpointBinding" type="tns:ORMEngineServiceEndpoint">
        <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc"/>
        <operation name="executeQuery">
          <soap:operation soapAction=""/>
          <input>
            <soap:body use="literal" namespace="http://localhost:8080/"/></input>
          <output>
            <soap:body use="literal" namespace="http://localhost:8080/"/></output></operation></binding>
      <service name="ORMEngineService">
        <port name="ORMEngineServiceEndpointPort" binding="tns:ORMEngineServiceEndpointBinding">
          <soap:address location="REPLACE_WITH_ACTUAL_URL"/></port></service></definitions>The following are the working copies of the same implmentation:
    1. webservices.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <!--
        Document   : webservices.xml
        Created on : May 11, 2006, 5:36 PM
        Author     : david
        Description:
            Web Services Configuration File for EJB Container
    -->
    <webservices xmlns="http://java.sun.com/xml/ns/j2ee"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_web_services_1_1\.xsd" version="1.1">
      <webservice-description>
        <webservice-description-name>PersistenceService</webservice-description-name>
        <wsdl-file>META-INF/wsdl/PersistenceService.wsdl</wsdl-file>
        <jaxrpc-mapping-file>META-INF/mapping-persistence.xml</jaxrpc-mapping-file>
        <port-component>
          <port-component-name>PersistencePort</port-component-name>
          <wsdl-port>PersistenceServiceEndpointPort</wsdl-port>
          <service-endpoint-interface>gov.mohr.ems.core.entity.logic.PersistenceServiceEndpoint</service-endpoint-interface>
          <service-impl-bean>
            <ejb-link>PersistenceEJB</ejb-link>
          </service-impl-bean>
        </port-component>
      </webservice-description>
      <webservice-description>
        <webservice-description-name>ORMEngineService</webservice-description-name>
        <wsdl-file>META-INF/wsdl/ORMEngineService.wsdl</wsdl-file>
        <jaxrpc-mapping-file>META-INF/mapping-ormengine.xml</jaxrpc-mapping-file>
        <port-component>
          <port-component-name>ORMEnginePort</port-component-name>
          <wsdl-port>ORMEngineServiceEndpointPort</wsdl-port>
          <service-endpoint-interface>gov.mohr.ems.core.entity.logic.ORMEngineServiceEndpoint</service-endpoint-interface>
          <service-impl-bean>
            <ejb-link>ORMEngineEJB</ejb-link>
          </service-impl-bean>
        </port-component>
      </webservice-description>
    </webservices>2. ejb-jar.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <ejb-jar version="2.1" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd">
      <display-name>Enforcement Management System Backend</display-name>
      <enterprise-beans>
      <!--<session>
          <display-name>WorkflowJAR</display-name>
          <ejb-name>WorkflowEJB</ejb-name>
          <home>gov.mohr.ems.core.workflow.logic.WorkflowRemoteHome</home>
          <remote>gov.mohr.ems.core.workflow.logic.WorkflowRemote</remote>
          <ejb-class>gov.mohr.ems.core.workflow.logic.WorkflowBean</ejb-class>
          <session-type>Stateless</session-type>
          <transaction-type>Container</transaction-type>
          <env-entry>
            <env-entry-name>ejb/BeanFactoryPath</env-entry-name>
            <env-entry-type>java.lang.String</env-entry-type>
            <env-entry-value>/META-INF/applicationcontext-ejb.xml</env-entry-value>
          </env-entry>
        </session>-->
        <!--<session>
          <display-name>NotificationJAR</display-name>
          <ejb-name>NotificationEJB</ejb-name>
          <home>gov.mohr.ems.core.notification.logic.NotificationRemoteHome</home>
          <remote>gov.mohr.ems.core.notification.logic.NotificationRemote</remote>
          <ejb-class>gov.mohr.ems.core.notification.logic.NotificationBean</ejb-class>
          <session-type>Stateless</session-type>
          <transaction-type>Container</transaction-type>
          <env-entry>
            <env-entry-name>ejb/BeanFactoryPath</env-entry-name>
            <env-entry-type>java.lang.String</env-entry-type>
            <env-entry-value>/META-INF/applicationcontext-ejb.xml</env-entry-value>
          </env-entry>
        </session>-->
        <session>
            <display-name>ORMEngineJAR</display-name>
            <ejb-name>ORMEngineEJB</ejb-name>
            <service-endpoint>gov.mohr.ems.core.entity.logic.ORMEngineServiceEndpoint</service-endpoint>
            <!--<home>gov.mohr.ems.core.entity.logic.ORMEngineRemoteHome</home>
            <remote>gov.mohr.ems.core.entity.logic.ORMEngineRemote</remote>-->
            <ejb-class>gov.mohr.ems.core.entity.logic.ORMEngineBean</ejb-class>
            <session-type>Stateless</session-type>
            <transaction-type>Container</transaction-type>
            <env-entry>
                <env-entry-name>ejb/BeanFactoryPath</env-entry-name>
                <env-entry-type>java.lang.String</env-entry-type>
                <env-entry-value>/META-INF/applicationcontext-ejb.xml</env-entry-value>
            </env-entry>
        </session>
        <session>
            <display-name>PersistenceJAR</display-name>
            <ejb-name>PersistenceEJB</ejb-name>
            <service-endpoint>gov.mohr.ems.core.entity.logic.PersistenceServiceEndpoint</service-endpoint>
            <!--<home>gov.mohr.ems.core.entity.logic.PersistenceRemoteHome</home>
            <remote>gov.mohr.ems.core.entity.logic.PersistenceRemote</remote>-->
            <ejb-class>gov.mohr.ems.core.entity.logic.PersistenceBean</ejb-class>
            <session-type>Stateless</session-type>
            <transaction-type>Container</transaction-type>
            <env-entry>
                <env-entry-name>ejb/BeanFactoryPath</env-entry-name>
                <env-entry-type>java.lang.String</env-entry-type>
                <env-entry-value>/META-INF/applicationcontext-ejb.xml</env-entry-value>
            </env-entry>
        </session>
      </enterprise-beans>
      <assembly-descriptor>
         <!--<container-transaction>
          <method>
            <ejb-name>WorkflowEJB</ejb-name>
            <method-name>*</method-name>
          </method>
          <trans-attribute>Required</trans-attribute>
        </container-transaction>-->
        <!--<container-transaction>
          <method>
            <ejb-name>NotificationEJB</ejb-name>
            <method-name>*</method-name>
          </method>
          <trans-attribute>Required</trans-attribute>
        </container-transaction>-->
        <container-transaction>
            <method>
                <ejb-name>ORMEngineEJB</ejb-name>
                <method-name>*</method-name>
            </method>
            <trans-attribute>Required</trans-attribute>
        </container-transaction>
        <container-transaction>
            <method>
                <ejb-name>PersistenceEJB</ejb-name>
                <method-name>*</method-name>
            </method>
            <trans-attribute>Required</trans-attribute>
        </container-transaction>
      </assembly-descriptor>
    </ejb-jar>3. applicationcontext-ejb.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE beans PUBLIC "-//SPRING//DTD// BEAN//EN"
        "http://www.springframework.org/dtd/spring-beans.dtd">
    <!--
        Document   : applicationcontext-ejb.xml
        Created on : April 26, 2006, 9:07 PM
        Author     : david
        Description:
            Spring configuration.
    -->
    <beans default-autowire="byName">
        <bean id="sessionFactory" class="org.springframework.jndi.JndiObjectFactoryBean">
            <property name="jndiName">
                <value>java:hibernate/SessionFactory</value>
            </property>
        </bean>
        <!--<bean id="gov.mohr.ems.core.workflow.logic.Workflow" class="gov.mohr.ems.core.workflow.logic.WorkflowImpl"/>-->
        <!--<bean id="gov.mohr.ems.core.notification.logic.Notification" class="gov.mohr.ems.core.notification.logic.NotificationImpl"/>-->
        <!-- Backend -->
        <bean id="gov.mohr.ems.core.entity.logic.DefaultQueryMethod" class="gov.mohr.ems.core.entity.logic.DefaultQueryMethod"/>
        <bean id="gov.mohr.ems.core.entity.logic.ORMEngine" class="gov.mohr.ems.core.entity.logic.ORMEngineImpl">
            <property name="queryMethodMap">
                <map>
                    <entry key="CustomerSampleKey">
                        <value>CustomerSampleClassName</value>
                    </entry>
                </map>
            </property>
        </bean>
        <bean id="gov.mohr.ems.core.entity.logic.Persistence" class="gov.mohr.ems.core.entity.logic.PersistenceImpl"/>
    </beans>4. working copy of mapping file:
    <?xml version="1.0" encoding="UTF-8"?>
    <java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
      <package-mapping>
        <package-type>gov.mohr.ems.core.entity.logic</package-type>
        <namespaceURI>http://localhost:8080/types</namespaceURI>
      </package-mapping>
      <package-mapping>
        <package-type>gov.mohr.ems.core.entity.logic</package-type>
        <namespaceURI>http://localhost:8080/</namespaceURI>
      </package-mapping>
      <service-interface-mapping>
        <service-interface>gov.mohr.ems.core.entity.logic.PersistenceService</service-interface>
        <wsdl-service-name xmlns:serviceNS="http://localhost:8080/">serviceNS:PersistenceService</wsdl-service-name>
        <port-mapping>
          <port-name>PersistenceServiceEndpointPort</port-name>
          <java-port-name>PersistenceServiceEndpointPort</java-port-name>
        </port-mapping>
      </service-interface-mapping>
      <service-endpoint-interface-mapping>
        <service-endpoint-interface>gov.mohr.ems.core.entity.logic.PersistenceServiceEndpoint</service-endpoint-interface>
        <wsdl-port-type xmlns:portTypeNS="http://localhost:8080/">portTypeNS:PersistenceServiceEndpoint</wsdl-port-type>
        <wsdl-binding xmlns:bindingNS="http://localhost:8080/">bindingNS:PersistenceServiceEndpointBinding</wsdl-binding>
        <service-endpoint-method-mapping>
          <java-method-name>upload</java-method-name>
          <wsdl-operation>upload</wsdl-operation>
          <method-param-parts-mapping>
            <param-position>0</param-position>
            <param-type>java.lang.String</param-type>
            <wsdl-message-mapping>
              <wsdl-message xmlns:wsdlMsgNS="http://localhost:8080/">wsdlMsgNS:PersistenceServiceEndpoint_upload</wsdl-message>
              <wsdl-message-part-name>String_1</wsdl-message-part-name>
              <parameter-mode>IN</parameter-mode>
            </wsdl-message-mapping>
          </method-param-parts-mapping>
          <wsdl-return-value-mapping>
            <method-return-value>java.lang.String</method-return-value>
            <wsdl-message xmlns:wsdlMsgNS="http://localhost:8080/">wsdlMsgNS:PersistenceServiceEndpoint_uploadResponse</wsdl-message>
            <wsdl-message-part-name>result</wsdl-message-part-name>
          </wsdl-return-value-mapping>
        </service-endpoint-method-mapping>
      </service-endpoint-interface-mapping>
    </java-wsdl-mapping>5. working copy of WSDL file:
    <?xml version="1.0" encoding="UTF-8"?>
    <definitions name="PersistenceService" targetNamespace="http://localhost:8080/" xmlns:tns="http://localhost:8080/" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
      <types/>
      <message name="PersistenceServiceEndpoint_upload">
        <part name="String_1" type="xsd:string"/></message>
      <message name="PersistenceServiceEndpoint_uploadResponse">
        <part name="result" type="xsd:string"/></message>
      <portType name="PersistenceServiceEndpoint">
        <operation name="upload" parameterOrder="String_1">
          <input message="tns:PersistenceServiceEndpoint_upload"/>
          <output message="tns:PersistenceServiceEndpoint_uploadResponse"/></operation></portType>
      <binding name="PersistenceServiceEndpointBinding" type="tns:PersistenceServiceEndpoint">
        <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc"/>
        <operation name="upload">
          <soap:operation soapAction=""/>
          <input>
            <soap:body use="literal" namespace="http://localhost:8080/"/></input>
          <output>
            <soap:body use="literal" namespace="http://localhost:8080/"/></output></operation></binding>
      <service name="PersistenceService">
        <port name="PersistenceServiceEndpointPort" binding="tns:PersistenceServiceEndpointBinding">
          <soap:address location="REPLACE_WITH_ACTUAL_URL"/></port></service></definitions>Anyone has any ideas?
    Many thanks!

    if we examine the webservices.xml, there are 2 part:
    <webservices xmlns="http://java.sun.com/xml/ns/j2ee"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_web_services_1_1\.xsd" version="1.1">
      <webservice-description>
        <webservice-description-name>PersistenceService</webservice-description-name>
        <wsdl-file>META-INF/wsdl/PersistenceService.wsdl</wsdl-file>
        <jaxrpc-mapping-file>META-INF/mapping-persistence.xml</jaxrpc-mapping-file>
        <port-component>
          <port-component-name>PersistencePort</port-component-name>
          <wsdl-port>
    PersistenceServiceEndpointPort</wsdl-port>
          <service-endpoint-interface>gov.mohr.ems.core.entity.logic.PersistenceServiceEndpoint</service-endpoint-interface>
          <service-impl-bean>
            <ejb-link>PersistenceEJB</ejb-link>
          </service-impl-bean>
        </port-component>
      </webservice-description>
      <webservice-description>
        <webservice-description-name>ORMEngineService</webservice-description-name>
        <wsdl-file>META-INF/wsdl/ORMEngineService.wsdl</wsdl-file>
        <jaxrpc-mapping-file>META-INF/mapping-ormengine.xml</jaxrpc-mapping-file>
        <port-component>
          <port-component-name>ORMEnginePort</port-component-name>
          <wsdl-port>
    ORMEngineServiceEndpointPort</wsdl-port>
          <service-endpoint-interface>gov.mohr.ems.core.entity.logic.ORMEngineServiceEndpoint</service-endpoint-interface>
          <service-impl-bean>
            <ejb-link>ORMEngineEJB</ejb-link>
          </service-impl-bean>
        </port-component>
      </webservice-description>
    </webservices>one is for Persistence service, one is for ORMEngine service. it is just that i need to put them both inside the same webservices.xml

  • What is the difference between ejb reference and ejb handle?

    Hi:
    I am newbie for J2EE.
    I want to know what is the difference between ejb reference and ejb handle
    from the client view and from the container view?
    Very Thanks!
    Stive

    Hi John,,
    1) Ejb Object Handle are nothing but a long lived proxy for the
    ejb object, using this handle user can disconnect from the Ejb Server/Container
    at any time
    and after some time using the same handle he can able to resume the conversational
    state
    with the server / container where he was been disconnected From.
    And there are currently two Handles , HomeHandle and Handle for EjbHomeObject
    and EjbObject
    Respectively. Both these handles have Persistent reference to the EJB Object
    2) Ejb Reference is used to lookup a bean from other Enterprise Bean
    Ejb reference is a nickname for the JNDI Location that you want to lookup a bean.
    your code will looks up a Home object via using this nickname
    and the deployer will bind the
    nickname to the JNDI location of its choice
    EJb Reference are declared in the deployment descriptor
    Regards
    Karthikeyan Gangadharan
    SIP Technologies, Chennai
    E-mail-ID : [email protected]
    "John Stive" <[email protected]> wrote:
    >
    Hi:
    I am newbie for J2EE.
    I want to know what is the difference between ejb reference and ejb
    handle
    from the client view and from the container view?
    Very Thanks!
    Stive

  • Error trying to deserialize EJB HomeHandle and EJB Handle classes

    I get the following exception when I try to deserialize both a javax.ejb.HomeHandle and a javax.ejb.Handle.  I serialize and immediately deserialize within the same application using the same classloader so there are not alot of external variables that may cause the problem.  Any ideas on why I can't deserialize an ejb handle?
    The reason I am doing this is to try and get around the need to reference another application just to call a remote method in that application.  I want to serialize the remote home interface handle or the remote component interface handle and deserialize it using my local application classloader.  Does anybody know if this would work?
    #1#java.lang.ClassNotFoundException: Loader /L_service:ejb could not load class turtle.registry.SBRegistryRemoteHome
         at com.sap.vmc.core.impl.sapjvm.sharing.NativeSharedClassLoaderImpl.loadClass(NativeSharedClassLoaderImpl.java:609)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:265)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:333)
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java:242)
         at java.io.ObjectInputStream.resolveProxyClass(ObjectInputStream.java:656)
         at java.io.ObjectInputStream.readProxyDesc(ObjectInputStream.java:1499)
         at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1462)
         at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1698)
         at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1304)
         at java.io.ObjectInputStream.readObject(ObjectInputStream.java:349)
         at com.sap.engine.services.ejb3.runtime.impl.LocalHandleDelegate.readStub(LocalHandleDelegate.java:177)
         at com.sap.engine.services.ejb3.runtime.impl.ServerHandleDelegate.readStub(ServerHandleDelegate.java:64)
         at com.sap.engine.services.ejb3.runtime.impl.LocalHandleDelegate.readEJBHome(LocalHandleDelegate.java:101)
         at com.sap.engine.services.ejb3.runtime.impl.StatelessHomeHandleImpl.readObject(StatelessHomeHandleImpl.java:73)
         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 java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:946)
         at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1818)
         at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1718)
         at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1304)
         at java.io.ObjectInputStream.readObject(ObjectInputStream.java:349)
         at turtle.common.util.SerializationHelper.convertObject(SerializationHelper.java:43)
         at turtle.common.server.connect.RemoteFactory.getRemoteSAPWAS(RemoteFactory.java:206)
         at turtle.common.server.connect.RemoteFactory.getRemote(RemoteFactory.java:46)
         at turtle.common.server.connect.RemoteProxyFactory.getRemote(RemoteProxyFactory.java:99)
         at turtle.common.server.connect.RemoteProxyFactory.create(RemoteProxyFactory.java:91)
         at turtle.common.server.connect.RemoteProxyFactory.createProxy(RemoteProxyFactory.java:52)
         at turtle.server.runtime.registry.RegistryFacade.connectToRegistry(RegistryFacade.java:932)
         at turtle.server.runtime.registry.RegistryFacade.getGenericRegistryBI(RegistryFacade.java:987)
         at turtle.server.runtime.registry.RegistryFacade.unbindObjectsInProject(RegistryFacade.java:857)
         at turtle.registry.ProjectRegistrar$1$1.run(ProjectRegistrar.java:130)
         at java.security.AccessController.doPrivileged(Native Method)
         at javax.security.auth.Subject.doAs(Subject.java:337)
         at turtle.common.security.auth.AuthenticatorBase.doAs(AuthenticatorBase.java:387)
         at turtle.registry.ProjectRegistrar$1.run(ProjectRegistrar.java:172)
         at java.util.TimerThread.mainLoop(Timer.java:512)
         at java.util.TimerThread.run(Timer.java:462)

    Has anyone been able to get this to work?  Or can anyone confirm that this is a bug?
    As a simpler test, I modified the UserManagementBean of the Car Rental example application.  I added some code in the register method that serializes and deserializes the Handle object obtained from the SessionContext.getEJBObject().getHandle() method.  The serialization completes without issue.  However, I get the same error when trying to deserialize the Handle object:
    java.lang.ClassNotFoundException: Loader /L_service:ejb could not load class com.sap.engine.examples.epf.ejb.controller.customer.UserManagementHome
         at com.sap.vmc.core.impl.sapjvm.sharing.NativeSharedClassLoaderImpl.loadClass(NativeSharedClassLoaderImpl.java:609)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:265)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:333)
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java:242)
         at java.io.ObjectInputStream.resolveProxyClass(ObjectInputStream.java:656)
         at java.io.ObjectInputStream.readProxyDesc(ObjectInputStream.java:1499)
         at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1462)
         at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1698)
         at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1304)
         at java.io.ObjectInputStream.readObject(ObjectInputStream.java:349)
         at com.sap.engine.services.ejb3.runtime.impl.LocalHandleDelegate.readStub(LocalHandleDelegate.java:177)
         at com.sap.engine.services.ejb3.runtime.impl.ServerHandleDelegate.readStub(ServerHandleDelegate.java:64)
         at com.sap.engine.services.ejb3.runtime.impl.LocalHandleDelegate.readEJBHome(LocalHandleDelegate.java:101)
         at com.sap.engine.services.ejb3.runtime.impl.StatelessHomeHandleImpl.readObject(StatelessHomeHandleImpl.java:73)
         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 java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:946)
         at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1818)
         at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1718)
         at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1304)
         at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1917)
         at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1841)
         at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1718)
         at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1304)
         at java.io.ObjectInputStream.readObject(ObjectInputStream.java:349)
         at com.sap.engine.examples.epf.ejb.controller.customer.SerializationUtils.deSerialize(SerializationUtils.java:33)
         at com.sap.engine.examples.epf.ejb.controller.customer.SerializationUtils.deepClone(SerializationUtils.java:59)
         at com.sap.engine.examples.epf.ejb.controller.customer.UserManagementBean.register(UserManagementBean.java:75)

  • Xpath Debatching in Orchestration -The part 'part' of message 'Message_In_Copy' contained a null value at the end of the construct block

    Hi ,
    Facing strange issue in Xpath debatching in Orchestration.
    Getting following error in construct shape:
    The part 'part' of message 'Message_In_Copy' contained a null value at the end of the construct block
    Code inside the construct block:
    sXpath = System.String.Format("/*[local-name()='Customers' and namespace-uri()='http://Debatch.Customer']/*[local-name()='Customer' and namespace-uri()='http://Debatch.Customer' and position()={0}]", nLoopCount);
    System.Diagnostics.Debug.WriteLine(sXpath);
    Message_In_Copy= xpath(Message_In, sXpath);
    Schema used:
    <?xml version="1.0" encoding="utf-16"?>
    <xs:schema xmlns="http://Debatch.Customer" xmlns:b="http://schemas.microsoft.com/BizTalk/2003" targetNamespace="http://Debatch.Customer" xmlns:xs="http://www.w3.org/2001/XMLSchema">
    <xs:element name="Customers">
    <xs:complexType>
    <xs:sequence>
    <xs:element minOccurs="0" maxOccurs="unbounded" name="Customer">
    <xs:complexType>
    <xs:sequence>
    <xs:element name="name" type="xs:string" />
    <xs:element name="id" type="xs:string" />
    </xs:sequence>
    </xs:complexType>
    </xs:element>
    </xs:sequence>
    </xs:complexType>
    </xs:element>
    </xs:schema>
    Can anyone help me out ? to identify the root cause for above issue.
    Thanks,
    Kind Regards,
    girsh
    girishkumar.a

    I agree with Shankycheil here, querying XPath will return XMLNode and thus can't be assigned to XMLNode.
    But for debatching in Orchestration using Xpath is not a very good idea. 
    Because using XPATH loads the complete message in memory(XML Structure) and then performs processing.
    This approach is always prone to throwing Out of Memory exception and low in performance also.
    Therefore I would suggest you to perform debatching by calling XML Disassembler(XMLReceive) pipeline.
    As pipeline works with Stream it will have better performance and you will also get complete control over the messages.
    Refer the below samples for debatching using XML Receive pipeline within Orchestration.
    Comparrison between XPATH and ReceivePipeline for Debatching:-
    De-batching within an orchestration using XPath or calling a pipeline
    Debatching within Orchestration using Pipeline-
    http://tech-findings.blogspot.in/2013/07/debatchingsplitting-xml-message-in.html 
    https://jeremyronk.wordpress.com/2011/10/03/how-to-debatch-into-an-orchestration-with-a-pipeline/
    Thanks,
    Prashant
    Please mark this post accordingly if it answers your query or is helpful.

  • EJB Handles & Clustering

    I'm just curious about what happens when I use an ejb handle for a stateful session
    bean in a clustered environment. Does the reference I get back when I use the
    handle point me back to the exact bean I was using or does it pick a clone of
    the bean on any one of the servers? Assume that the stateful bean replication
    has been enabled.
    Many Thanks,
    Ron

    Jason Pringle wrote:
              > Since serialization of the handle is not supported under clustering, how do
              > I get the servlet to "find" the same stateful bean instance on subsequent
              > invocations?
              Our docs should be more clear here. Our current version doesn't support
              fail-over on handles in a cluster. So if you create a handle on server A
              and server A goes down you will not be able to re-create the bean currently.
              This is a known bug, and it should be fixed by the EJB 1.1 release (the final
              release not the beta(s))
              As long as the server where the handle was created and where the stateful
              session bean lives are alive, handles will work fine.
              -- Rob
              > I'm ok with having it die if the server goes down (my session
              > will still exist, I'll get an "object not found" error and have the user
              > restart the operation), but would like to be able to use stateful session
              > EJBeans across servlet invocations.
              >
              > Thanks for any input!
              >
              > --Jason
              

  • Error getting the EJB Handle for context name: User

    I am getting EJB Handle for context name: User.
    1) I specified ejb's and datasource in the ejb-jar.xml in the session tags.
    <session> </session>
    and I also included ejb's and datasource in the sun-ejb-jar.xml still I am getting the above error I am new to EJB how can I resolve this?

    What is the Oracle application server version?
    JDeveloper 11g supports direct deployment to Oracle Application Server 11g
    http://www.oracle.com/technology/products/jdev/collateral/papers/11/newfeatures/index.html

  • EJB Handle return remote ref fails??

    Having a problem getting a remote reference on an EJB using a handle. Create a remote ref to an EJB and store three items and display said items - okay
    Get a handle to the remote ref and serialize and store - okay
    Deserialize - okay
    Cast to remote ref - NOT okay wants a home ref?
    This example is, by and large, similar to the example in section 6.8 of the EJB 2.0 Spec.
    Need to know why I cannot get the remote ref returned? Is there an OC4J issue? Please let me know when you can as would like to use this in a class.
    THANKS - Ken Cooper
    public class CartClient {
    public static void main(String[] args) {
    CartClient cartClient = new CartClient();
    try {
    Context context = getInitialContext();
    CartHome cartHome = (CartHome) PortableRemoteObject.narrow(context.lookup(
    "Cart"), CartHome.class);
    Cart cart;
    // Use one of the create() methods below to create a new instance
    cart = cartHome.create();
    // Call any of the Remote methods below to access the EJB
    // cart.getItems( );
    // cart.addItems( java.lang.String p );
    cart.addItems("Truck");
    cart.addItems("Car");
    cart.addItems("Boat");
    System.out.println(cart.getItems());
    // Serialize and store in C:\cartHandle
    Handle cartHandle = cart.getHandle();
    FileOutputStream out = new FileOutputStream("C:/cartHandle");
    ObjectOutputStream so = new ObjectOutputStream(out);
    so.writeObject(cartHandle);
    so.flush();
    System.out.println("Serialized");
    // Deserialize from C:\cartHandle
    FileInputStream in = new FileInputStream("C:/cartHandle");
    ObjectInputStream si = new ObjectInputStream(in);
    cartHandle = (Handle) si.readObject();
    System.out.println("DeSerialized");
    Cart cart2 = (Cart) PortableRemoteObject.narrow(cartHandle.getEJBObject(),
    Cart.class);
    System.out.println("Second: " + cart2.getItems());
    } catch (Throwable ex) {
    ex.printStackTrace();
    private static Context getInitialContext() throws NamingException {
    Hashtable env = new Hashtable();
    env.put(Context.INITIAL_CONTEXT_FACTORY,
    "com.evermind.server.rmi.RMIInitialContextFactory");
    env.put(Context.SECURITY_PRINCIPAL, "admin");
    env.put(Context.SECURITY_CREDENTIALS, "welcome");
    env.put(Context.PROVIDER_URL,
    "ormi://localhost:23891/current-workspace-app");
    return new InitialContext(env);
    OUTPUT AND ERROR FROM EXECUTION
    C:\JDev9031\jdk\bin\javaw.exe -ojvm -classpath C:\JDev9031\jdev\mywork\del15aug\Project4\classes;......
    Start: TruckCarBoat
    Serialized
    DeSerialized
    com.evermind.server.rmi.OrionRemoteException: Error looking up EJBHome at location 'Cart'
    javax.ejb.EJBObject com.evermind.server.ejb.StatefulSessionHandle.getEJBObject()
    StatefulSessionHandle.java:56
    void mypackage4.CartClient.main(java.lang.String[])
    CartClient.java:53 (NOTE: The highlighted line above is line 53)

    Thank you all guys for your suggests, and sorry for my (long) silence: i was at home with hard cough. I think that unfortunally the problem is more in deep. This because:
    1) at the beginnnig, in my (many) attempts I've tried to give the server url in a lot of ways:
    a) only the IP;
    b) http://<IP>;
    c) http://<IP>: <port>;
    d) http://<server-name>;
    e) http://<server-name>:<server-port>;
    b) iiop://<IP>;
    c) iiop://<IP>: <port>;
    d) iiop://<server-name>;
    e) iiop://<server-name>:<server-port>;
    In this cases, using init.put(org.omg.CORBA.ORBInitialHost,<param-value>) (init is Java Properties object), I didn't get what I would: always AppServer running on Win2000 responded me, instead of the one running on Linux.
    Using instead using init.put(Context.PROVIDER_URL,<param-value>) , in case a) I got the error message Root exception is java.net.MalformedURLException: no protocol:<IP-number>. In case b), c), d) and e) I got invalid url - connection refused error message (Invalid URL: http://gandalf.engiweb.com. Root exception is java.net.ConnectException: Connection refused: connect).
    A collegue of mine is using WebSphere and everything seems to work correctly. I'm afraid that there is a problem (of misconfiguration?) in the Borland Application Server. This is a problem, because, if I have (suppose) server gandalf running, with the correct EJB, and the server Saruman running too, but with the scorrect EJB, or the ejb container down, always respond me Saruman, not Gandalf: my tests gave me this result.
    At the moment I don't know what to do, except migrate to WebSphere, or another Application Server.
    Thank you a lot for your interest. Bye!

  • JCA 1.0 inbound communication with javax.ejb.Handle...?

    Hello,
    I made a study regarding inbound communication in JCA. The assumption is about that resource adapter is effectively the client of the EJB container; so I implemented the JCA 1.0 resource adapter as it was a client.
    In detail: when I got a connection from resource container I pass the session bean's Handle (it is reachable through javax.ejb.EJBObject::getHandle). When resource adapter wants to deliver something asynchronously it retrieves the session bean by its Handle and calls one of its method (e.g. receive). This works.
    I ported this simple app to weblogic, websphere and Sun ref 1.4 without problems. Do anyone knows about standard or specs which prevents performing inbound communication this way ?
    Thanks in advance, best regards.

    This is a interesting solution. Did you get any answer?
    regards,
    Kristoffer

  • Why is it so hard to deploy EJBs that contain SQLJ???

    The SQLJ translator creates _SJProfilex.ser files by default that
    contain the SQL statements the SQLJ file uses. When trying to
    use a SQLJ file for an EJB, I can't get it to deploy right--in
    fact I'm thrawted at every turn! (THIS SHOULD BE EASY!)
    1) .ser files aren't deployed by default. O.K., I added the .ser
    rule in the deployment file. No dice, still doesn't show up in
    the JAR file!
    2) Even if I force the .ser file to be in the JAR (by including
    it in the project), still no dice! After deployment, the .ser
    file doesn't make it to the server.
    3) O.K., there's a nice -ser2class option to SQLJ that turns it
    into a class file instead of a .ser file. But where to add that
    option? It's not in the SQLJ options of the project properties.
    I also tried an SQLJ_OPTIONS environment variable, and putting an
    sqlj.properties file in all the suggested places. Nothing works!
    The only way I've been able to get it to work is to manually JAR
    the .ser file, ftp it to the server, and run loadjava on it.
    THERE HAS GOT TO BE AN EASIER WAY! ...so much for one-click
    deployment.
    Please help!
    null

    Hi John,
    There is an issue with deploying SQLJ files in 8.1.5.
    The doc (help sytem ) gives more details on how to deploy them.
    Open Online Help system
    Double click on the Sample Applications book icon
    Double click on the "web Application for Oracle8i" book
    Open "Deploying the EJB's"
    On the right hand window you will find a topic
    "Deploying the SQLJ files used by the Rentals EJB"
    this should take you through the deployment of SQLJ files.
    regards
    raghu
    John K. Peterson (guest) wrote:
    : The SQLJ translator creates _SJProfilex.ser files by default
    that
    : contain the SQL statements the SQLJ file uses. When trying to
    : use a SQLJ file for an EJB, I can't get it to deploy right--in
    : fact I'm thrawted at every turn! (THIS SHOULD BE EASY!)
    : 1) .ser files aren't deployed by default. O.K., I added the
    .ser
    : rule in the deployment file. No dice, still doesn't show up in
    : the JAR file!
    : 2) Even if I force the .ser file to be in the JAR (by including
    : it in the project), still no dice! After deployment, the .ser
    : file doesn't make it to the server.
    : 3) O.K., there's a nice -ser2class option to SQLJ that turns it
    : into a class file instead of a .ser file. But where to add
    that
    : option? It's not in the SQLJ options of the project
    properties.
    : I also tried an SQLJ_OPTIONS environment variable, and putting
    an
    : sqlj.properties file in all the suggested places. Nothing
    works!
    : The only way I've been able to get it to work is to manually
    JAR
    : the .ser file, ftp it to the server, and run loadjava on it.
    : THERE HAS GOT TO BE AN EASIER WAY! ...so much for one-click
    : deployment.
    : Please help!
    null

  • EJB 3.0 EntityManager null on JBoss 4.2

    Hi ,
    I am developing an application in EBJ 3.0.
    My application is properly deployed on JBoss 4.2 application server but when I am trying to persist data I am getting EntityManaget always null.
    My Mail Id is : [email protected]
    following is my code Please help me...........
    My datasource for oracle
    D:\jboss-4.2.2.GA\server\default\deploy\oracle-ds.xml
    <datasources>
    <local-tx-datasource>
    <jndi-name>OracleDS</jndi-name>
    <connection-url>jdbc:oracle:thin:@serverIp:1521:SID</connection-url>
    <!--
    Here are a couple of the possible OCI configurations.
    For more information, see http://otn.oracle.com/docs/products/oracle9i/doc_library/release2/java.920/a96654/toc.htm
    <connection-url>jdbc:oracle:oci:@youroracle-tns-name</connection-url>
    or
    <connection-url>jdbc:oracle:oci:@(description=(address=(host=youroraclehost)(protocol=tcp)(port=1521))(connect_data=(SERVICE_NAME=yourservicename)))</connection-url>
    Clearly, its better to have TNS set up properly.
    -->
    <driver-class>oracle.jdbc.driver.OracleDriver</driver-class>
    <user-name>V2RND</user-name>
    <password>V2RND</password>
    <!-- Uses the pingDatabase method to check a connection is still valid before handing it out from the pool -->
    <!--valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleValidConnectionChecker</valid-connection-checker-class-name-->
    <!-- Checks the Oracle error codes and messages for fatal errors -->
    <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name>
    <!-- sql to call when connection is created
    <new-connection-sql>some arbitrary sql</new-connection-sql>
    -->
    <!-- sql to call on an existing pooled connection when it is obtained from pool - the OracleValidConnectionChecker is prefered
    <check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
    -->
    <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml -->
    <metadata>
    <type-mapping>Oracle9i</type-mapping>
    </metadata>
    </local-tx-datasource>
    </datasources>
    Entity Bean
    com.ntpl.v2hralign.master.entity.Department
    package com.ntpl.v2hralign.master.entity;
    import java.io.Serializable;
    import javax.persistence.Column;
    import javax.persistence.Entity;
    import javax.persistence.Id;
    import javax.persistence.Table;
    @Entity
    @Table(name="MASTER_DEPARTMENT")
    public class Department implements Serializable {
    @Id
    @Column(name="DEPT_ID")
    private int deptId;
    @Column(name="DEPT_NAME")
    private String deptName;
    private static final long serialVersionUID = 1L;
    public Department() {
    super();
    public int getDeptId() {
    return this.deptId;
    public void setDeptId(int deptId) {
    this.deptId = deptId;
    public String getDeptName() {
    return this.deptName;
    public void setDeptName(String deptName) {
    this.deptName = deptName;
    Remote Interface
    package com.ntpl.v2hralign.master.session;
    import javax.ejb.Remote;
    @Remote
    public interface DepartmentRemote {
    public void createDepartment(int deptId, String deptName);
    package com.ntpl.v2hralign.master.session;
    import javax.annotation.Resource;
    import javax.ejb.Stateless;
    import javax.naming.InitialContext;
    import javax.persistence.EntityManager;
    import javax.persistence.EntityManagerFactory;
    import javax.persistence.Persistence;
    import javax.persistence.PersistenceContext;
    import javax.persistence.PersistenceContextType;
    import org.hibernate.mapping.Component;
    import org.jboss.aspects.Injected;
    import com.ntpl.v2hralign.master.entity.Department;
    @Stateless
    public class DepartmentSession implements DepartmentRemote {
    @PersistenceContext EntityManager entityManager;
    //@Injected protected EntityManager entityManager;
    /*EntityManagerFactory emf = Persistence.createEntityManagerFactory("V2HRAlign");
    EntityManager entityManager = emf.createEntityManager();*/
    /*protected EntityManager entityManager;
    public EntityManager getEntityManager() {
    if (entityManager == null){
    try{
    System.out.println("hi dear not yet get anaything");
    entityManager = (EntityManager)(new InitialContext()).lookup("java:comp/ejb/EntityManager");
    } catch (Exception e){};
    return entityManager;
    @Override
    public void createDepartment(int deptId, String deptName) {
    //entityManager = getEntityManager();
    Department department = new Department();
    department.setDeptId(deptId);
    department.setDeptName(deptName);
    System.out.println("entityManager="+entityManager);
    entityManager.persist(department);
    persistence.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <persistence version="1.0" xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd">
    <persistence-unit name="V2HRAlign">
    <jta-data-source>java:/OracleDS</jta-data-source>
    <class>com.ntpl.v2hralign.master.entity.Department</class>
    <properties>
    <property name="hibernate.dialect" value="org.hibernate.dialect.Oracle9Dialect"/>
    <property name="hibernate.connection.driver_class" value="oracle.jdbc.driver.OracleDriver"/>
    <property name="hibernate.hbm2ddl.auto" value="create"/>
    <property name="hibernate.show_sql" value="true" />
    </properties>
    </persistence-unit>
    </persistence>
    Client Program
    package com.ntpl.v2hralignclient.master.client;
    import javax.ejb.EJB;
    import com.ntpl.v2hralign.master.session.DepartmentRemote;
    import com.ntpl.v2hralign.master.session.DepartmentSession;
    public class DepartmentClient {
    * @param args
    @EJB
    public static DepartmentRemote department = new DepartmentSession();
    public static void main(String[] args) {
    department.createDepartment(1, "Software");
    Error -------------------------------
    entityManager=null
    Exception in thread "main" java.lang.NullPointerException
    at com.ntpl.v2hralign.master.session.DepartmentSession.createDepartment(DepartmentSession.java:54)
    at com.ntpl.v2hralignclient.master.client.DepartmentClient.main(DepartmentClient.java:20)
    ---------------------------------------------------------------------------------------------------------------------------------------

    the problem is in your client code. you are instantiating the EJB locally. that is not what you want. you should be looking up the remote ejb using a Context object. look for information on setting up a client program to contact jboss using jndi.

  • How can I call remote ejb through jsp?(null)

     

    Trying the code:
              <%@ page import="si3.*,javax.ejb.*,javax.naming.*,java.util.*,java.rmi.RemoteException" %>
              <%
              int h=8;
              int w=8;
              Hashtable p = new Hashtable ();
              p.put(Context.INITIAL_CONTEXT_FACTORY,"weblogic.jndi.WLInitialContextFactory");
              p.put(Context.PROVIDER_URL,"t3://192.168.0.203:7001");
              Context ctx= new InitialContext(p);
              Object homeref = ctx.lookup("si3.test");
              addHome home = (addHome) PortableRemoteObject.narrow(homeref, addHome.class);
              add the_ejb = home.create();
              out.println(the_ejb.add(h,w));
              out.println("adf");
              the_ejb.remove();
              %>
              yzj wrote:
              > I have two server running weblogic5.1.
              > If the jsp and ejb locate the same server running weblogic 5.1 ,works well .But one deploys the ejb (jndi name si3.test),the other runs the jsp.I use jsp call the remote ejb ,catch exception :
              >
              > GMT+08:00 2000:<E> <ServletContext-General> Root
              > > cause of ServletException
              > > javax.naming.NameNotFoundException: 'si3.test'; remaining name 'si3.test'
              > > at
              > > weblogic.jndi.toolkit.BasicWLContext.resolveName(BasicWLContext.java,
              > > Compiled Code)
              > > at
              > > weblogic.jndi.toolkit.BasicWLContext.lookup(BasicWLContext.java:133)
              > > at
              > > weblogic.jndi.toolkit.BasicWLContext.lookup(BasicWLContext.java:574)
              > > at javax.naming.InitialContext.lookup(InitialContext.java:349)
              > > at jsp_servlet.client._jspService(client.java:90)
              > > at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
              > > at
              > > weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
              > > :124)
              > > at
              > > weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
              > > l.java:744)
              > > at
              > > weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
              > > l.java:692)
              > > at
              > > weblogic.servlet.internal.ServletContextManager.invokeServlet(ServletContext
              > > Manager.java:
              > > 251)
              > > at
              > > weblogic.socket.MuxableSocketHTTP.invokeServlet(MuxableSocketHTTP.java:363)
              > > at
              > > weblogic.socket.MuxableSocketHTTP.execute(MuxableSocketHTTP.java:263)
              > > at weblogic.kernel.ExecuteThread.run(ExecuteThread.java, Compiled
              > > Code)
              >
              > Why? Can you help me? Thanks.
              > The jsp's source(Client.jsp ):
              > <%@ page import="si3.*,javax.ejb.*,javax.naming.*,java.util.*,java.rmi.RemoteException" %>
              > <%
              > int h=8;
              > int w=8;
              > Hashtable p = new Hashtable ();
              > p.put(Context.INITIAL_CONTEXT_FACTORY,"weblogic.jndi.WLInitialContextFactory");
              > p.put(Context.PROVIDER_URL,"t3://192.168.0.203:7001");
              > Context ctx= new InitialContext(p);
              > addHome home = (addHome) ctx.lookup("si3.test");
              > add the_ejb = home.create();
              > out.println(the_ejb.add(h,w));
              > out.println("adf");
              > the_ejb.remove();
              > %>
              >
              >
              [att1.html]
              

  • Eclipse and glassfish ejb jar contains zero ejb

    Hi,
    We have an EAR that had ejbs in a war file. recently it was converted to a jar and since then the deployment from eclipse to the local glassfish is giving the following errors:
    SEVERE: Exception while deploying the app [hub-application-ear]
    SEVERE: Invalid ejb jar [hub-sso.jar]: it contains zero ejb.
    Note:
    1. A valid ejb jar requires at least one session, entity (1.x/2.x style), or message-driven bean.
    2. EJB3+ entity beans (@Entity) are POJOs and please package them as library jar.
    3. If the jar file contains valid EJBs which are annotated with EJB component level annotations (@Stateless, @Stateful, @MessageDriven, @Singleton), please check server.log to see whether the annotations were processed properly.
    java.lang.IllegalArgumentException: Invalid ejb jar [hub-sso.jar]: it contains zero ejb.
    Note:
    1. A valid ejb jar requires at least one session, entity (1.x/2.x style), or message-driven bean.
    2. EJB3+ entity beans (@Entity) are POJOs and please package them as library jar.
    3. If the jar file contains valid EJBs which are annotated with EJB component level annotations (@Stateless, @Stateful, @MessageDriven, @Singleton), please check server.log to see whether the annotations were processed properly.
         at com.sun.enterprise.deployment.util.EjbBundleValidator.accept(EjbBundleValidator.java:76)
         at com.sun.enterprise.deployment.util.ApplicationValidator.accept(ApplicationValidator.java:128)
         at com.sun.enterprise.deployment.EjbBundleDescriptor.visit(EjbBundleDescriptor.java:730)
         at com.sun.enterprise.deployment.Application.visit(Application.java:1765)
         at com.sun.enterprise.deployment.archivist.ApplicationArchivist.validate(ApplicationArchivist.java:830)
         at com.sun.enterprise.deployment.archivist.ApplicationArchivist.openWith(ApplicationArchivist.java:277)
         at com.sun.enterprise.deployment.archivist.ApplicationFactory.openWith(ApplicationFactory.java:240)
         at org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:175)
         at org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:94)
         at com.sun.enterprise.v3.server.ApplicationLifecycle.loadDeployer(ApplicationLifecycle.java:827)
         at com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:769)
         at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:368)
         at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
         at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:389)
         at com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:348)
         at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:363)
         at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1085)
         at com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1200(CommandRunnerImpl.java:95)
         at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1291)
         at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1259)
         at com.sun.enterprise.v3.admin.AdminAdapter.doCommand(AdminAdapter.java:461)
         at com.sun.enterprise.v3.admin.AdminAdapter.service(AdminAdapter.java:212)
         at com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:179)
         at com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:117)
         at com.sun.enterprise.v3.services.impl.ContainerMapper$Hk2DispatcherCallable.call(ContainerMapper.java:354)
         at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:195)
         at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:849)
         at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:746)
         at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1045)
         at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:228)
         at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
         at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
         at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
         at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
         at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
         at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
         at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
         at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
         at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
         at java.lang.Thread.run(Thread.java:662)
    However, the deployment of the same EAR to the local server from the glassfish admin screen works as expected.
    We are developing in EJB 3.1, eclipse is Indigo and server is glassfish 3.1.2.
    Regards,
    Sameer Jaffer

    I'm trying to get a hold of the ejb, session bean home. everywhere that i've looked said that i need to access it via the "java:/env/.../beanname".
    Obviously I am wrong.
    what should i be trying to do to get a hold of my session bean home?

  • WebLogic 6.1 SP2 stateful EJB handle serialization problem

    I try to serialize and later deserialize the handle of a stateful
    session bean in WebLogic 6.1 SP2. This works on the client, but not on
    the server. In WebLogic 6.1 SP1, it worked on both server and client.
    The test code:
    try {
    InitialContext context = new InitialContext();
    InfSessionHome sessionHome = (InfSessionHome)
    InfEJBUtil.getInfEJBHome
    (context, InfJNDINames.INFSESSION_EJBHOME,
    InfSessionHome.class);
    infSession1 = sessionHome.create();
    // serialize
    ObjectOutputStream objector = new ObjectOutputStream(byteStream);
    objector.writeObject(infSession1.getHandle());
    objector.flush();
    objector.close();
    byte[] ejbKeyBytes = byteStream.toByteArray();
    // deserialize
    ByteArrayInputStream byteInStream = new
    ByteArrayInputStream(ejbKeyBytes);
    ObjectInputStream objStream = new ObjectInputStream(byteInStream);
    Handle ejbHandle = (Handle) objStream.readObject();
    objStream.close();
    InfSession infSession2 = (InfSession) ejbHandle.getEJBObject();
    if (!infSession2.equals(infSession1)) {
    throw new IllegalStateException("not equal: " + infSession2);
    } catch (Exception e) {
    e.printStackTrace();
    I get the following stack trace in the readObject() call:
    java.io.InvalidClassException:
    weblogic.rmi.internal.LocalServerRefMissing no-arg constructor for
    class
    at java.io.ObjectInputStream.inputObject(ObjectInputStream.java:1221)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:386)
    at java.io.ObjectInputStream.inputClassFields(ObjectInputStream.java:2263)
    at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:519)
    at weblogic.rmi.internal.StubInfo.readObject(StubInfo.java:73)
    at java.lang.reflect.Method.invoke(Native Method)
    at java.io.ObjectInputStream.invokeObjectReader(ObjectInputStream.java:2214)
    at java.io.ObjectInputStream.inputObject(ObjectInputStream.java:1411)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:386)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:236)
    at weblogic.ejb20.internal.HandleImpl.readExternal(HandleImpl.java:89)
    at java.io.ObjectInputStream.inputObject(ObjectInputStream.java:1212)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:386)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:236)
    I suppose that WebLogic uses a different handle on the server
    (LocalServerRef class, handle local to it's EJB) than on the client.
    I took the routine from Apache SOAP 2.2 StatefulEJBProvider. So I
    suppose that more people are running into the same problem.
    Does anybody know of a workaround?
    Tom

    Just a small addition/clarification to what Cameron said on serialization.
    - The no argument constructor is required in the first non-serializable class in the object hierarchy for de-serialization process. If your class extends form Object class(which has a no arg constructor), you need not have a no-arg constructor. refere to http://64.49.216.133/faq/view.jsp?EID=251942 for more details.
    - Also I suggest using the api
    isIdentical(...)
    instead of equals method in the code if you are trying to establish whether the two objects represent the same EJBObject or not
    - Rajeev
    Cameron Purdy <[email protected]> wrote in message news:[email protected]...
    A no-argument constructor is required for a class to be deserialized. It
    sounds like a BEA bug from the stack trace, but make sure you don't have
    something extra that you are serializing on something of yours that should
    be transient. (It's hard to imagine how, but you never know ...)
    Peace,
    Cameron Purdy
    Tangosol, Inc.
    Clustering Weblogic? You're either using Coherence, or you should be!
    Download a Tangosol Coherence eval today at http://www.tangosol.com/
    "Tom Gerber" <[email protected]> wrote in message
    news:[email protected]...
    I try to serialize and later deserialize the handle of a stateful
    session bean in WebLogic 6.1 SP2. This works on the client, but not on
    the server. In WebLogic 6.1 SP1, it worked on both server and client.
    The test code:
    try {
    InitialContext context = new InitialContext();
    InfSessionHome sessionHome = (InfSessionHome)
    InfEJBUtil.getInfEJBHome
    (context, InfJNDINames.INFSESSION_EJBHOME,
    InfSessionHome.class);
    infSession1 = sessionHome.create();
    // serialize
    ObjectOutputStream objector = new ObjectOutputStream(byteStream);
    objector.writeObject(infSession1.getHandle());
    objector.flush();
    objector.close();
    byte[] ejbKeyBytes = byteStream.toByteArray();
    // deserialize
    ByteArrayInputStream byteInStream = new
    ByteArrayInputStream(ejbKeyBytes);
    ObjectInputStream objStream = new ObjectInputStream(byteInStream);
    Handle ejbHandle = (Handle) objStream.readObject();
    objStream.close();
    InfSession infSession2 = (InfSession) ejbHandle.getEJBObject();
    if (!infSession2.equals(infSession1)) {
    throw new IllegalStateException("not equal: " + infSession2);
    } catch (Exception e) {
    e.printStackTrace();
    I get the following stack trace in the readObject() call:
    java.io.InvalidClassException:
    weblogic.rmi.internal.LocalServerRefMissing no-arg constructor for
    class
    atjava.io.ObjectInputStream.inputObject(ObjectInputStream.java:1221)
    atjava.io.ObjectInputStream.readObject(ObjectInputStream.java:386)
    atjava.io.ObjectInputStream.inputClassFields(ObjectInputStream.java:2263)
    atjava.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:519)
    at weblogic.rmi.internal.StubInfo.readObject(StubInfo.java:73)
    at java.lang.reflect.Method.invoke(Native Method)
    atjava.io.ObjectInputStream.invokeObjectReader(ObjectInputStream.java:2214)
    atjava.io.ObjectInputStream.inputObject(ObjectInputStream.java:1411)
    atjava.io.ObjectInputStream.readObject(ObjectInputStream.java:386)
    atjava.io.ObjectInputStream.readObject(ObjectInputStream.java:236)
    atweblogic.ejb20.internal.HandleImpl.readExternal(HandleImpl.java:89)
    atjava.io.ObjectInputStream.inputObject(ObjectInputStream.java:1212)
    atjava.io.ObjectInputStream.readObject(ObjectInputStream.java:386)
    atjava.io.ObjectInputStream.readObject(ObjectInputStream.java:236)
    I suppose that WebLogic uses a different handle on the server
    (LocalServerRef class, handle local to it's EJB) than on the client.
    I took the routine from Apache SOAP 2.2 StatefulEJBProvider. So I
    suppose that more people are running into the same problem.
    Does anybody know of a workaround?
    Tom
    [att1.html]

Maybe you are looking for

  • How to get 300 mbps on Cisco LAP1142N without WLAN Controller

    Hi, Anyone using Cisco LAP1142N without Wireless LAN Controller and getting 300mbps throughput? I am only using 5 GHz (Manually Disabled 2.4) but i am getting only 144 mbps max throughtput. It would be great if someone can help me to achive around 30

  • Simpler networks power line adapter doesn't suppor...

    Hello all, I am new to BT and youview. Over the weekend I set up youview and have been playing around a bit. The experience so far isn't great - especially I was trying to play the movie Madagascar from iPlayer and literally youview struggled to load

  • Creating a Places Keyword Tag

    Greetings, When I create a keyword tag in the Places category, it doesn't allow me to input the GPS coordinates. I have some pictures that have GPS coordinates in the metadata. Is it possible to create keyword tags from the pictures, so that the new

  • Bb calendar is not syncing with MAC, i am to the point that I am going to switch to an Iphone

    When I put the software on MAC, I was asked the first time where to sync and I choose the Address book and Ical. I originally just synced the phone book.  About 2 weeks ago I attempted to sync calendars to ICAL and I was having trouble until it worke

  • "cannot create communication semaphore" - Error

    hi, We recently re-installed SAP and done a database recovery on my R3 system. We are running SAP 6.40 with MAXDB 7.5.0.032. This is running on Linux. My problem is since the recovery i get this message on my system log as well as when trying to use