JCO Ejb problem

Hi all,
i'm developing a ejb to execute a function from a JCO Rfc provider. I got a lot of problem:
1) How can i set the correct JNDI name for the ejb?
2) What type of bean i need?
3) What is the correct sign for the function procedure?
Thanx

Hi Francesco,
This depends on what your application is doing, so there's two options a Stateless or Stateful Session bean. There's lots of info about these types on the net.  During development of this you will provide a JNDI name, when looking for the bean in your code you would prefix lookup with "java:comp/env/ejb/xxx" xxx being Bean name.
I don't understand the last question? please clarify.
Raj

Similar Messages

  • EJB problem (Seam 2.1.2 + WLS 10.3)

    Hi,
    I'm having some problems getting the EJB version of the booking example in Seam 2.1.2 working with WebLogic 10.3, and I'm hoping that someone here might have some advice. I followed the instructions in Chapter 39 of the Seam documentation for building the application on WebLogic 10.3 (http://docs.jboss.org/seam/2.1.2/reference/en-US/html/weblogic.html), worked through a few dependency issues, and got the application to the point where it deployed cleanly into WLS. When I go to http://localhost:7001/seam-booking, though, I get lots of exceptions, each of whose root cause is this:
    Caused by: javax.naming.NameNotFoundException: While trying to lookup 'jboss-seam-booking.EjbSynchronizations/local' didn't find subcontext 'jboss-seam-booking'. Resolved ''; remaining name 'jboss-seam-booking/EjbSynchronizations/local'
    at weblogic.jndi.internal.BasicNamingNode.newNameNotFoundException(BasicNamingNode.java:1139)
    at weblogic.jndi.internal.BasicNamingNode.lookupHere(BasicNamingNode.java:247)
    at weblogic.jndi.internal.ServerNamingNode.lookupHere(ServerNamingNode.java:182)
    at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:206)
    at weblogic.jndi.internal.WLEventContextImpl.lookup(WLEventContextImpl.java:254)
    at weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:380)
    at javax.naming.InitialContext.lookup(InitialContext.java:392)
    at org.jboss.seam.Component.instantiateSessionBean(Component.java:1400)
    at org.jboss.seam.Component.instantiate(Component.java:1364)
    at org.jboss.seam.Component.newInstance(Component.java:2122)
    ... 48 more
    On the "Deployments" tab of the admin console, I can expand the deployed EAR and see the packaged EJB jars inside of there, and they're identified as EJBs, but I don't see anything in the JNDI tree for that server.
    I am able to get beyond this error by commenting out the "<transaction:ejb-transaction/>" line in components.xml, which gets me to the booking application's home page in the browser, but trying to do anything else (log in, for example), hits the same kinds of error, just with different beans (like the AuthenticatorAction bean).
    Thanks in advance for any suggestions!
    Mark

    I worked out the solution to this one, and have documented it at http://seamframework.org/Community/Weblogic103SetupWithEjbBookingExample#comment106254 for future reference.

  • DynamicRFCException with JCO.client problem

    Hi,
    Iam trying to execute an RFC from webdynpro.Iam getting the following error.So as a result i dont get any result as expected on my screen as the RFC is not getting executed due to JCO problem.Please kindly let me know the reason.In the last line of the exception it talks about user authentication.I dont have any idea whats the reason.This happens as soon as my bapi execute statement in my controller is executed.
    could not create JCOClientConnection for logical System: WD_MODELDATA_DEST - Model: class com.test.Getmodel. Please assure that you have configured the RFC connections and/or logical system name properly for this model!
    com.sap.tc.webdynpro.modelimpl.dynamicrfc.WDDynamicRFCExecuteException: Error connecting using JCO.Client: null at com.sap.tc.webdynpro.modelimpl.dynamicrfc.DynamicRFCModel.prepareExecute(DynamicRFCModel.java:179) at com.test.Getmodel.bapi_Ben_Bus3029_Get_Evt_List(Getmodel.java:141) at com.test.Bapi_Ben_Bus3029_Get_Evt_List_Input.doExecute(Bapi_Ben_Bus3029_Get_Evt_List_Input.java:137) at com.sap.tc.webdynpro.modelimpl.dynamicrfc.DynamicRFCModelClassExecutable.execute(DynamicRFCModelClassExecutable.java:92) at com.avid.benefits.Benefitscust.executebapi(Benefitscust.java:128) at com.avid.benefits.wdp.InternalBenefitscust.executebapi(InternalBenefitscust.java:162) at com.avid.benefits.AvidusbenefitsView.wdDoInit(AvidusbenefitsView.java:97) at com.avid.benefits.wdp.InternalAvidusbenefitsView.wdDoInit(InternalAvidusbenefitsView.java:129) at com.sap.tc.webdynpro.progmodel.generation.DelegatingView.doInit(DelegatingView.java:61) at com.sap.tc.webdynpro.progmodel.controller.Controller.initController(Controller.java:215) at com.sap.tc.webdynpro.progmodel.view.View.initController(View.java:445) at com.sap.tc.webdynpro.progmodel.controller.Controller.init(Controller.java:200) at com.sap.tc.webdynpro.progmodel.view.ViewManager.getView(ViewManager.java:709) at com.sap.tc.webdynpro.progmodel.view.ViewManager.bindRoot(ViewManager.java:579) at com.sap.tc.webdynpro.progmodel.view.ViewManager.init(ViewManager.java:155) at com.sap.tc.webdynpro.clientserver.window.WebDynproWindow.doOpen(WebDynproWindow.java:295) at com.sap.tc.webdynpro.clientserver.window.ApplicationWindow.show(ApplicationWindow.java:183) at com.sap.tc.webdynpro.clientserver.window.ApplicationWindow.open(ApplicationWindow.java:178) at com.sap.tc.webdynpro.clientserver.cal.ClientApplication.init(ClientApplication.java:364) at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.initApplication(ApplicationSession.java:756) at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.doProcessing(ApplicationSession.java:291) at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessingStandalone(ClientSession.java:713) at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessing(ClientSession.java:666) at com.sap.tc.webdynpro.clientserver.session.ClientSession.doProcessing(ClientSession.java:250) at com.sap.tc.webdynpro.clientserver.session.RequestManager.doProcessing(RequestManager.java:149) at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doContent(DispatcherServlet.java:62) at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doGet(DispatcherServlet.java:46) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401) at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266) at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:386) at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:364) at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:1039) at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:265) at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95) at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175) at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33) at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(Native Method) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:102) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:172) Caused by: com.sap.tc.webdynpro.modelimpl.dynamicrfc.WDDynamicRFCException: Could not create JCOClientConnection for logical System: WD_MODELDATA_DEST - Model: class com.test.Getmodel. Please assure that you have configured the RFC connections and/or logical system name properly for this model! at com.sap.tc.webdynpro.modelimpl.dynamicrfc.AiiModel.getCurrentlyUsedJcoClient(AiiModel.java:210) at com.sap.tc.webdynpro.modelimpl.dynamicrfc.DynamicRFCModel.prepareExecute(DynamicRFCModel.java:170) ... 42 more Caused by: com.sap.tc.webdynpro.services.sal.sl.api.WDSystemLandscapeException: Error while obtaining JCO connection. at com.sap.tc.webdynpro.serverimpl.wdc.sl.SystemLandscapeFactory.getJCOClientConnection(SystemLandscapeFactory.java:152) at com.sap.tc.webdynpro.services.sal.sl.api.WDSystemLandscape.getJCOClientConnection(WDSystemLandscape.java:30) at com.sap.tc.webdynpro.modelimpl.dynamicrfc.AiiModel.getCurrentlyUsedJcoClient(AiiModel.java:189) ... 43 more Caused by: com.sap.tc.webdynpro.services.exceptions.WDRuntimeException: Failed to resolve connection parameter for 'WD_MODELDATA_DEST' at com.sap.tc.webdynpro.serverimpl.wdc.sl.JCOClientConnection.resolveConnectionParameter4MsgServerJCODestination(JCOClientConnection.java:649) at com.sap.tc.webdynpro.serverimpl.wdc.sl.JCOClientConnection.resolveConnectionParameter(JCOClientConnection.java:476) at com.sap.tc.webdynpro.serverimpl.core.sl.AbstractJCOClientConnection.init(AbstractJCOClientConnection.java:233) at com.sap.tc.webdynpro.serverimpl.core.sl.AbstractJCOClientConnection.<init>(AbstractJCOClientConnection.java:218) at com.sap.tc.webdynpro.serverimpl.wdc.sl.JCOClientConnection.<init>(JCOClientConnection.java:129) at com.sap.tc.webdynpro.serverimpl.wdc.sl.SystemLandscapeFactory.getJCOClientConnection(SystemLandscapeFactory.java:150) ... 45 more Caused by: com.sap.tc.webdynpro.services.exceptions.WDRuntimeException: User not authenticated - unable to establish JCO connection with SSO. at com.sap.tc.webdynpro.serverimpl.wdc.sl.JCOClientConnection.resolveConnectionParameter4MsgServerJCODestination(JCOClientConnection.java:584) ... 50 more
    Error connecting using JCO.Client: null
    Error connecting using JCO.Client: null: Could not create JCOClientConnection for logical System: WD_MODELDATA_DEST - Model: class com.test.Getmodel. Please assure that you have configured the RFC connections and/or logical system name properly for this model!: Error while obtaining JCO connection.: Failed to resolve connection parameter for 'WD_MODELDATA_DEST': User not authenticated - unable to establish JCO connection with SSO.

    Hi Swathi,
                        The problem may be with JCo destinations. If you have authorization in Portal, navigate to Content Administration -> Web Dynpro.
    In the left side you can see deployed web dynpro applications. Check in local, sap,  or any of your custom namespace. Browse & select to your application. Right side you can see JCo destinations for your application. If they are in green color , means they are created. If not, ask your basis team to create them. If they are n green color, ping and test them. if they are working fine or not.
    If they are fine, try to deploy after you have logged into the portal. 
    Regards,
    Siva

  • JCO Connection Problem

    Hi Experts,
    This is not related to Java Web Dynpro directly.
    We are encountering strange behavior with respect to JCo Destination.
    Up to yesterday we had no problems with JCo. But when we tried to run run a Web Dynpro application, it
    was not able to extract data from SAP backend.
    On further investigation it was found out that JCo Destination test is failing. Following is the error when we
    tried to test JCo Destination:
    com.sap.mw.jco.JCO$Exception: (103) RFC_ERROR_LOGON_FAILURE: Client 100 is not available in this system
    Backend is working fine with username and password in the client. Connection from ABAP server to
    the the problematic ABAP server is also working (SM59). But connection from any Java portal to ABAP
    server is not working.
    Has anybody encountered this problem?
    Best Regards,
    Pramod

    Hi Promod,
    It would be some Username and password issue. If you manage to change them you issue will be resolved. Have a look at the the following useful discussion. It would be helpful for you.
    JCO Connection Error
    Also have a look at the following Wiki for troubleshooting the RFC Communication problems with Java Connectors.
    https://www.sdn.sap.com/irj/scn/wiki?path=/display/ep/troubleshooting%252bsap%252bjava%252bconnector%252b(JCo)
    I hope this helps you.
    Regards,
    Gopal.

  • JCO server problems

    Hello,
    We've developed JCO server which serve as a bridge between SAP R/3 and MS SQL database system. In R/3 system is created TCP/IP destination and JCO server connects to this destination as a registered program.
    In our test environment everything works fine. In customer production environment I face this behaviour:
    After installation of solution it works. But after "some time", when I try to test destination in SM59 and I've got this error:
    SM59 - test connection
    connection to partner broken / CPI-C error CM_PRODUCT_SPECIFIC_ERROR
    COMPONENT      NI (network interface)                                                                         
    COUNTER        2422932                                                                               
    ERROR TEXT     Connection reset by peer                                                                       
    ERROR NUMBER   232                                                                               
    MODULE         niuxi.c                                                                               
    LINE           1204                                                                               
    RETURN CODE    -6 
    What is interesting, problem persist, if i turn off JCO server (I expect error message, that no program is registered!),.... so I change the registered program ID (in SM59), change this in configuration of JCO server - it works.. but again after some time I've got that error.
    R/3 version is 4.6c
    Can you give suggestions, how to solve this problem (where should be the problem)?
    Thanks for any answer.
    Best Regards,
    Juraj

    Hi,
    It gives me the correct IP when I ping yes. It's only when the SLD tries to resolve IP via JCO destinations. Yesterday I put in all hosts in my landscape into the hosts file of the SLD, disabled the NIC that it shouldn't be using and restarted.
    Still it tries to resolve hosts in my landscape to 10.150.83.XXX. How is this possible??
    Thanks - any other ideas?
    .: HP

  • EJB problem with home interface

    Hi firends
    I am beginner to EJB world, and trying first EJB object i.e. Hello World program
    I prepared first Remote interface, HelloBean and it compiled also properly.
    names of program
    Remote interface : Hello
    Bean: HelloBean
    Home interface : HelloHome
    But after preparing Home interface it fails to compile at position of create()
    the declaration is
    public Hello create() throws RemoteException,CreateException
    compilation error pointing at Hello in above statement saying 'Cannot resolve symbol'
    The fact is all these files are located in same directory only
    can anyone help me in this problem as I am eger to execute my first program and want to go further in EJB
    thanx in advance
    Mandar

    Hi Mandar,
    How are you setting the classpath and what exactly is it set to?
    Unresolved symbol can only mean that the class cannot be found in the classpath. If two files are in the same directory and one has a dependency on the other then adding '.' to the classpath is all that is needed. Questions to ask yourself. Are the files in the same directory? does either include a 'package' statement? and are you absolutely certain that the classpath is set correctly (type 'set' at the command line)? Also if you have set the CLASSPATH variable, using -classpath with the javac command will override the variable.
    Check everything above and if you still have problems maybe we can get some more details if you can post the entire error message.
    Mandy

  • Loading EJB problem with deployejb !

    I am working with Oracle 8.1.5 and jdk 1.1.6,
    when I am running the deployejb tool with the HelloWorld example of the demo directory, I have a problem when loadind EJB files into the database:
    deployejb -v -u workuser ...
    done
    Compiling Stubs...done
    Generating Jar File...done
    Loading EJB Jar file adn Comm Stubs Jar file...loading: helloServer/HelloBean
    ORA-01552: cannot use system rollback segment for non-system tablespace USERS
    SQL Error in loading : helloServer/HelloBean
    ORA-06502: PL/SQL : numeric or value error
    ORA-06512: at "SYS.DBMS_LOB", line 700
    ORA-06512: at "WORKUSER.LOADLOBS", line 1
    ORA-06512: at line 1
    ... [same problem with all objects]
    Can you HELP me ?

    Hard to say, looks like a database configuration problem. Check with your DBA...
    Matthieu

  • ** JCO$Exception Problem in RFC to RFC scenario

    Hi Friends,
    I am doing RFC to RFC scenario. We have two IDES system. One XI system. The scenario is to send the Vendor data from First IDES system (Z_APPLE_VENDOR_SEND) to call the RFC (Z_APPLE_VENDOR_INSERT) in the second RFC system. Sync to Sync Scenario. In this case data is passed from source system and mapped to target RFC soruce Structure. But, not able to login into target system. The following error is occured in SXMB_MONI.
    com.sap.aii.af.ra.ms.api.DeliveryException: RfcAdapter: receiver channel has static errors: can not instantiate RfcPool caused by: com.sap.aii.af.rfc.RfcAdapterException: error initializing RfcClientPool:com.sap.aii.af.rfc.core.repository.RfcRepositoryException: can not connect to destination system due to: com.sap.mw.jco.JCO$Exception: (102) RFC_ERROR_COMMUNICATION: Connect to SAP gateway failed Connect_PM TYPE=A ASHOST=aprins05 SYSNR=01 GWHOST=aprins05 GWSERV=sapgw01 PCS=1 LOCATION CPIC (TCP/IP) on local host with Unicode ERROR partner '172.25.12.23:sapgw01' not reached TIME Fri Oct 17 23:28:55 2008 RELEASE 700 COMPONENT NI (network interface) VERSION 38 RC -10 MODULE nixxi.cpp LINE 2764 DETAIL NiPConnect2 SYSTEM CALL connect ERRNO 10061 ERRNO TEXT WSAECONNREFUSED: Connection refused COUNTER
    Friends, I have tested the following : SLDCHECK, Connection between IDES and XI system. Checked the Gateway of receiver side IDES system thru tcode SMGW. All are working fine. But, still the problem comes.
    Kindly help me to solve this issue.
    Kind Regards,
    Jegathees P.

    Hi
    Restart the Receiver System once and try again.
    Go throgh the following thread
    (102) RFC_ERROR_COMMUNICATION: Connect to SAP gateway failed
    Regards
    Sridhar Goli

  • Ejb problem,

    I had a problem in a previous post which i solved. I am trying to create the hellBoean from Mastering EJBs. I am packaging it with the sun application server. When I run the appclient I get the following. seems like its looking for a main class in my bean? I dont get it?
    Mar 11, 2005 8:57:54 PM com.sun.enterprise.util.Utility invokeApplicationMain
    SEVERE: UTIL6027:Exception in invokeApplicationMain [{0}].
    java.lang.NoSuchMethodException: examples.HelloBean.main([Ljava.lang.String;)
            at java.lang.Class.getMethod(Class.java:986)
            at com.sun.enterprise.util.Utility.invokeApplicationMain(Utility.java:207)
            at com.sun.enterprise.appclient.Main.<init>(Main.java:425)
            at com.sun.enterprise.appclient.Main.main(Main.java:97)
    Mar 11, 2005 8:57:54 PM com.sun.enterprise.appclient.Main <init>
    WARNING: ACC003: Application threw an exception.
    java.lang.ClassNotFoundException: No main method in class: class examples.HelloBean
            at com.sun.enterprise.util.Utility.invokeApplicationMain(Utility.java:211)
            at com.sun.enterprise.appclient.Main.<init>(Main.java:425)
            at com.sun.enterprise.appclient.Main.main(Main.java:97)

    i read the help on the deploytool with making application client. I am supposed to pick a main class. I think this is causing an error. none of my ejb classes have a main???

  • Sample of Request and Reply in Jco Interface - problem

    Hi
    I created a transaction with JCO interface and generated a sample of req and reply for a custom BAPI. A day later my co-worker added 2 new parameters in the BAPI and in this case I need to regenerate the req and reply sample.
    After I regenerated them ( I also tried delete the Jco Interface and insert new Jco action block); however the new parameters were not showing up.
    I do have another MII system (free from using this BAPI) and tested with the new BAPI. I received the new parameters in the new MII system.
    So it looks like MII is caching this Req and Repl.
    Question
    1. How do I clear the cache manually?
    - edited: I found the answer in forum .... to use http://<SERVER>:<PORT>/XMII/JCOProxy?Mode=Reset . This solve my problem. Do anyone knows any side effect if I use this ?
    2. Where does MII save this Req & Rep? in MII Database?
    3. In MII JCO interface config page, there is a parameter call retention time in Days. Does this parameters related to my problem?
    (there is no documentation about this parameter)
    any answer is greatfully appreciated
    Edited by: Seng Kiang Hoe on Jan 11, 2011 2:42 PM

    This issue has come up  before in the last 12 months.  I would search back further than the standard90 days to find what they did to refresh the NW or possibly ECC cache of the BAPI structure.
    Regards,
    Mike

  • WLS6.1sp1 stateful EJB problem =   load-balancing and fail over

              I have three problem
              1. I have 2 clustered server. my weblogic-ejb-jar.xml is here
              <?xml version="1.0"?>
              <!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB//EN'
              'http://www.bea.com/servers/wls600/dtd/weblogic-ejb-jar.dtd'>
              <weblogic-ejb-jar>
              <weblogic-enterprise-bean>
                   <ejb-name>DBStatefulEJB</ejb-name>
                   <stateful-session-descriptor>
                   <stateful-session-cache>
                        <max-beans-in-cache>100</max-beans-in-cache>
                        <idle-timeout-seconds>120</idle-timeout-seconds>
                   </stateful-session-cache>
                   <stateful-session-clustering>
                        <home-is-clusterable>true</home-is-clusterable>
                        <home-load-algorithm>RoundRobin</home-load-algorithm>
                        <home-call-router-class-name>common.QARouter</home-call-router-class-name>
                        <replication-type>InMemory</replication-type>
                   </stateful-session-clustering>
                   </stateful-session-descriptor>
                   <jndi-name>com.daou.EJBS.solutions.DBStatefulBean</jndi-name>
              </weblogic-enterprise-bean>
              </weblogic-ejb-jar>
              when i use "<home-call-router-class-name>common.QARouter</home-call-router-class-name>"
              and deploy this ejb, exception cause
              <Warning> <Dispatcher> <RuntimeException thrown b
              y rmi server: 'weblogic.rmi.cluster.ReplicaAwareServerRef@9 - jvmid: '2903098842
              594628659S:203.231.15.167:[5001,5001,5002,5002,5001,5002,-1]:mydomain:cluster1',
              oid: '9', implementation: 'weblogic.jndi.internal.RootNamingNode@5f39bc''
              java.lang.IllegalArgumentException: Failed to instantiate weblogic.rmi.cluster.B
              asicReplicaHandler due to java.lang.reflect.InvocationTargetException
              at weblogic.rmi.cluster.ReplicaAwareInfo.instantiate(ReplicaAwareInfo.ja
              va:185)
              at weblogic.rmi.cluster.ReplicaAwareInfo.getReplicaHandler(ReplicaAwareI
              nfo.java:105)
              at weblogic.rmi.cluster.ReplicaAwareRemoteRef.initialize(ReplicaAwareRem
              oteRef.java:79)
              at weblogic.rmi.cluster.ClusterableRemoteRef.initialize(ClusterableRemot
              eRef.java:28)
              at weblogic.rmi.cluster.ClusterableRemoteObject.initializeRef(Clusterabl
              eRemoteObject.java:255)
              at weblogic.rmi.cluster.ClusterableRemoteObject.onBind(ClusterableRemote
              Object.java:149)
              at weblogic.jndi.internal.BasicNamingNode.rebindHere(BasicNamingNode.jav
              a:392)
              at weblogic.jndi.internal.ServerNamingNode.rebindHere(ServerNamingNode.j
              ava:142)
              at weblogic.jndi.internal.BasicNamingNode.rebind(BasicNamingNode.java:36
              2)
              at weblogic.jndi.internal.BasicNamingNode.rebind(BasicNamingNode.java:36
              9)
              at weblogic.jndi.internal.BasicNamingNode.rebind(BasicNamingNode.java:36
              9)
              at weblogic.jndi.internal.BasicNamingNode.rebind(BasicNamingNode.java:36
              9)
              at weblogic.jndi.internal.BasicNamingNode.rebind(BasicNamingNode.java:36
              9)
              at weblogic.jndi.internal.RootNamingNode_WLSkel.invoke(Unknown Source)
              at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:296)
              So do i must use it or not???
              2. When i don't use "<home-call-router-class-name>common.QARouter</home-call-router-class-name>"
              , there's no exception
              but load balancing does not happen. According to the document , there's must load
              balancing when i call home.create() method.
              my client program goes here
                   DBStateful the_ejb1 = (DBStateful) PortableRemoteObject.narrow(home.create(),
              DBStateful.class);
                   DBStateful the_ejb2 = (DBStateful) PortableRemoteObject.narrow(home.create(3),
              DBStateful.class);
              the result is like that
                   the_ejb1 = ClusterableRemoteRef(203.231.15.167 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@4695a6)/397
                   the_ejb2 = ClusterableRemoteRef(203.231.15.167 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@acf6e)/398
                   or
                   the_ejb1 = ClusterableRemoteRef(203.231.15.125 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@252fdf)/380
                   the_ejb2 = ClusterableRemoteRef(203.231.15.125 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@6a0252)/381
                   I think the result should be like under one... isn't it??
                   the_ejb1 = ClusterableRemoteRef(203.231.15.167 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@4695a6)/397
                   the_ejb2 = ClusterableRemoteRef(203.231.15.125 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@6a0252)/381
              In this case i think the_ejb1 and the_ejb2 must have instance in different cluster
              server
              but they go to one server .
              3. If i don't use      "<home-call-router-class-name>common.QARouter</home-call-router-class-name>",
              "<replication-type>InMemory</replication-type>" then load balancing happen but
              there's no fail-over
              So how can i get load-balancing and fail over together??
              

              I have three problem
              1. I have 2 clustered server. my weblogic-ejb-jar.xml is here
              <?xml version="1.0"?>
              <!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB//EN'
              'http://www.bea.com/servers/wls600/dtd/weblogic-ejb-jar.dtd'>
              <weblogic-ejb-jar>
              <weblogic-enterprise-bean>
                   <ejb-name>DBStatefulEJB</ejb-name>
                   <stateful-session-descriptor>
                   <stateful-session-cache>
                        <max-beans-in-cache>100</max-beans-in-cache>
                        <idle-timeout-seconds>120</idle-timeout-seconds>
                   </stateful-session-cache>
                   <stateful-session-clustering>
                        <home-is-clusterable>true</home-is-clusterable>
                        <home-load-algorithm>RoundRobin</home-load-algorithm>
                        <home-call-router-class-name>common.QARouter</home-call-router-class-name>
                        <replication-type>InMemory</replication-type>
                   </stateful-session-clustering>
                   </stateful-session-descriptor>
                   <jndi-name>com.daou.EJBS.solutions.DBStatefulBean</jndi-name>
              </weblogic-enterprise-bean>
              </weblogic-ejb-jar>
              when i use "<home-call-router-class-name>common.QARouter</home-call-router-class-name>"
              and deploy this ejb, exception cause
              <Warning> <Dispatcher> <RuntimeException thrown b
              y rmi server: 'weblogic.rmi.cluster.ReplicaAwareServerRef@9 - jvmid: '2903098842
              594628659S:203.231.15.167:[5001,5001,5002,5002,5001,5002,-1]:mydomain:cluster1',
              oid: '9', implementation: 'weblogic.jndi.internal.RootNamingNode@5f39bc''
              java.lang.IllegalArgumentException: Failed to instantiate weblogic.rmi.cluster.B
              asicReplicaHandler due to java.lang.reflect.InvocationTargetException
              at weblogic.rmi.cluster.ReplicaAwareInfo.instantiate(ReplicaAwareInfo.ja
              va:185)
              at weblogic.rmi.cluster.ReplicaAwareInfo.getReplicaHandler(ReplicaAwareI
              nfo.java:105)
              at weblogic.rmi.cluster.ReplicaAwareRemoteRef.initialize(ReplicaAwareRem
              oteRef.java:79)
              at weblogic.rmi.cluster.ClusterableRemoteRef.initialize(ClusterableRemot
              eRef.java:28)
              at weblogic.rmi.cluster.ClusterableRemoteObject.initializeRef(Clusterabl
              eRemoteObject.java:255)
              at weblogic.rmi.cluster.ClusterableRemoteObject.onBind(ClusterableRemote
              Object.java:149)
              at weblogic.jndi.internal.BasicNamingNode.rebindHere(BasicNamingNode.jav
              a:392)
              at weblogic.jndi.internal.ServerNamingNode.rebindHere(ServerNamingNode.j
              ava:142)
              at weblogic.jndi.internal.BasicNamingNode.rebind(BasicNamingNode.java:36
              2)
              at weblogic.jndi.internal.BasicNamingNode.rebind(BasicNamingNode.java:36
              9)
              at weblogic.jndi.internal.BasicNamingNode.rebind(BasicNamingNode.java:36
              9)
              at weblogic.jndi.internal.BasicNamingNode.rebind(BasicNamingNode.java:36
              9)
              at weblogic.jndi.internal.BasicNamingNode.rebind(BasicNamingNode.java:36
              9)
              at weblogic.jndi.internal.RootNamingNode_WLSkel.invoke(Unknown Source)
              at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:296)
              So do i must use it or not???
              2. When i don't use "<home-call-router-class-name>common.QARouter</home-call-router-class-name>"
              , there's no exception
              but load balancing does not happen. According to the document , there's must load
              balancing when i call home.create() method.
              my client program goes here
                   DBStateful the_ejb1 = (DBStateful) PortableRemoteObject.narrow(home.create(),
              DBStateful.class);
                   DBStateful the_ejb2 = (DBStateful) PortableRemoteObject.narrow(home.create(3),
              DBStateful.class);
              the result is like that
                   the_ejb1 = ClusterableRemoteRef(203.231.15.167 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@4695a6)/397
                   the_ejb2 = ClusterableRemoteRef(203.231.15.167 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@acf6e)/398
                   or
                   the_ejb1 = ClusterableRemoteRef(203.231.15.125 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@252fdf)/380
                   the_ejb2 = ClusterableRemoteRef(203.231.15.125 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@6a0252)/381
                   I think the result should be like under one... isn't it??
                   the_ejb1 = ClusterableRemoteRef(203.231.15.167 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@4695a6)/397
                   the_ejb2 = ClusterableRemoteRef(203.231.15.125 weblogic.rmi.cluster.PrimarySecon
                   daryReplicaHandler@6a0252)/381
              In this case i think the_ejb1 and the_ejb2 must have instance in different cluster
              server
              but they go to one server .
              3. If i don't use      "<home-call-router-class-name>common.QARouter</home-call-router-class-name>",
              "<replication-type>InMemory</replication-type>" then load balancing happen but
              there's no fail-over
              So how can i get load-balancing and fail over together??
              

  • JCO connection problem at web dyn pro

    HI all,
    I was installed sneak preview of Net weaver 6.4,
      I want to do some web dynpro (java) programs which connect to back end systems.(R/3 system).
      The R/3 system which I want to connect is at remote place, i have connectivity to that R/3 system using VPN connectivity. With this I am not having any problem. Since I am able to connect using User name and password, and able to do some transactions like RZ70, etc.
       I developed an application which calls COMPANY_CODE_GET_LIST (BAPI function).
    for the above requirement what I did was
       (1)I created SLD setting.
           (a)Web as Java (I am not having any problem to
              Create this.
           (b) Web as ABAP.
              When i am trying to create
              This, there are some steps like i need to go to SAP log in and I need to run the transaction RZ70. For this i need to create an enter in visual administrator>JCO RFC Provider>runtime-->Bundles i need to create an entry for RFC destination as well as Repository.
          under <b>RFC destination </b> there are some fields which i need to enter those are  (a)Program ID as <b>mySLD</b>  (b) Gateway Host as <b>10.10.10.125</b> (c)Gateway service as <b>sapgw00</b>  (d)Number of processes as <b>1</b>
          Under <b>Repository</b>  (a) Application server host <b>10.10.10.125</b> (b)system number as <b>00</b> (c)Client number as <b>100</b> (d)Language as <b>en</b> (e)user as <b>ABCD</b>  (f)password as <b>1234</b>
      I haven't choosed the check boxes <b> Local bundle </b> and <b> Unicode </b> and pressed the set button. So like this i created the RFC destinations. under the <b>properties</b> tab  there is a property called <b>RFC_DEFAULT_DESTINATION</b> by default it was false so i made it as <b>true.</b> .
    I also went to <b>SLD Data Supplier</b>,under <b>Runtime</b> tab , HTTP  Settings , I mentioned
               (a)Host: pava-vis75
               (b) Port: 50000
               (c) user: administrator
               (d) password: abcd1234
               RFC Settings, I mentioned as
               (a)Gateway Host: 10.10.10.125 (which is SAP R/3 system)
                (b)Gateway Service/Host: sapgw00
               CIM Client Generation settings, as
               (a)Host: pava-vis75
               (b)Port (http/https):50000
               (c) user: administrator
               (d) Password : abcd1234
        I tested the CIMClient Test by click the the button. I got the successful message.
        Then I came back to HTTP settings and clicked the button with tilted arrow mark [This triggers data transfer to system landscape directory], for this also I got a successfully message.[data transferred successfully]
        Next I been to SAPLOGON and went to RFC Destinations by using <b> sm59 </b> transaction. There under TCP/IP connections i been to <b> SLD_NUC </b>, opened this by double clicking that and under Technical settings for <b> Program ID </b> I had given the ID which I created at visual administrator [JCO RFC Provider] which is <b>mySLD </b>, under gateway options for Gateway Host as <b>10.10.10.125</b>and Gateway service as <b> sapgw00 </b> then i tested the connection, it was also successfully.
    Then I opened the SLDAPICUST and i created a new entry for maintaining the SLD Access Data by giving some couple of entries as
                (a)Alias: vissldtest
                (b)Host Name: pava-vis75
                (c)Port: 50000
                (d) user: administrator
                (e) password: abcd1234
    Then saved it.
    Next I created <b>sapmsUV0         3600/tcp </b> entry at
    <b>WINDOWS\system32\drivers\etc</b>\services file, and also there are some required entries which are already existing those are <b>sapgw00</b> <b>3300/tcp</b> to <b>sapgw99</b> <b>3399/tcp</b> , another entry starts from  <b>sapdp00s</b> <b>4700/tcp</b> to <b>sapdp99s</b> <b>4799/tcp</b> , next entry starts from  <b>sapgw00s</b> <b>4800/tcp</b> to <b>sapgw99s         4899/tcp</b> and <b>sapmsJ2E      3601/tcp </b> .
    I restarted the system, as well as server.
    Now my problem is when I was trying to create JCO destination at web dynpro content administrator. For that I navigated as “create JCO Destination &#61664;Deployed Content&#61664;local-&#61664;local/CompanyCodeGetList-&#61664;Applications&#61664; CompanyCodeGetList
    I Choosed the JCO Connections tab-&#61664; there are 2 entries those are
                (1) COMPANY_CODE_MODEL
                (2) COMPANY_CODE_RFC_METADATA
    So I started creating connection for COMPANY_CODE_RFC_METADATA.
      First one is
                   General data <b> Name </b>: COMPANY_CODE_RFC_METADATA
                                        <b> Client </b> : 100
                                        I didn’t changed any default JCo pool configuration.
                     J2EE Cluster
                                        There is a check box called “Use Local J2EE engine J2E on pava-vis75’ so I choosed that.
                  Connection Type
                                       <b>Dictionary Meta Data</b> and <b>application Data </b>
                            I choosed the first one.
                 Then
                           Msg. Server Connection
                            Security
                            After these, I tried to test the connection by clicking the ‘Test Connection.
             It is saying the error as
         First time
            com.sap.mw.jco.JCO$Exception: (102) RFC_ERROR_COMMUNICATION: Connect to message server host failed Connect_PM TYPE=B MSHOST=v011 GROUP=DEFAULT R3NAME=UV0 MSSERV=sapmsUV0 PCS=1 ERROR service 'sapmsUVO' unknown TIME Fri Jul 01 07:20:41 2006 RELEASE 640 COMPONENT NI (network interface) VERSION 37 RC -3 COUNTER 1                                      
    second time
    com.sap.mw.jco.JCO$Exception: (102) RFC_ERROR_COMMUNICATION: Connect to message server host failed Connect_PM TYPE=B MSHOST=v011 GROUP=DEFAULT R3NAME=UV0 MSSERV=sapmsUV0 PCS=1 ERROR service '?' unknown TIME Fri Jul 01 07:20:41 2006 RELEASE 640 COMPONENT NI (network interface) VERSION 37 RC -3 COUNTER 1
    Can any body please help me to solve this problem.
    From past 1 week on wards I have been trying to resolve this. But in vain.

    answer in your other thread on the same topic
    problem in connecting JCO destination in web dynpro
    (Kindly avoid double posting)
    Regards
    Raja

  • JCo encoding problem

    Hi,
    I have a problem where a login over JCo fails when I have the character u20AC in the password.
    This is a bit strange, because the JCo Client itself has the UTF-16 encoding, and the password is UTF-8. The password is UTF-8 because it also contains Ä which works.
    I set up a test password with umlauts, and all umlauts seem to work. Everytime I have a u20AC or even &, the login fails.
    I tried setting "jco.client.unicode" to 1, but this didn't seem to work. I am not even sure the property "jco.client.unicode" even exists, although there is a "jco.server.unicode" which in my case is not helpful - I'm creating a client, not a server.
    The remote SAP System is a Unicode system by the way.
    Any ideas? Oh, I am using JCo 2.1.8.
    T00th

    Stefan,
    thanks a lot for the explanation, now we know at least what happens. As this seems so crappy though, I cannot help but rant a little...
    If JCo would do the logon with UTF-16/Unicode by default, you won't be able to logon to a Non-Unicode system without specifying the jco.client.codepage parameter.
    Not really as long as a proper code page conversion from UTF-16 to the code page used by the system would've been implemented on the server side. Instead of choosing codepage 1100 the more natural choice seems UTF-8.
    As far as I know since application server 6.10 the server "knows" about Unicode (e.g. see [here|http://help.sap.com/saphelp_nw04/helpdata/en/cb/56453c3ff4110ee10000000a11405a/frameset.htm]). Anyhow, if I understood you correctly you can actually set the code page for the logon data using jco.client.codepage, but what happens when you use Unicode codepages on non-Unicode systems?
    OSS note [794411 - Supported codepages of SAP Java Connector 2.1 and 6.x|https://service.sap.com/sap/support/notes/794411] seems to list the supported codepages for JCo 2.1.x (stops at 2.1.5 though, maybe no changes after that). UTF-8 is not listed (i.e. 4110), yet no error occurs when I specify this on JCo 2.1.8 when connecting to a non-Unicode SAP 4.7 system (kind of expected an exception).
    Finally OSS note [975768 - Deprecation of Java features with non-Unicode Backend|https://service.sap.com/sap/support/notes/975768] seems to put an end to all that madness. Well let's hope JCo follows and deprecates the jco.client.codepage parameter as soon as possible...
    Here's something funny though: When using JCo 3.0.5 I get client codepage 1100 when connecting to a non-Unicode 4.7 system and client codepage 4102 when connecting to a Unicode ECC 6.0 system (without setting jco.client.codepage). So maybe this is just a concern for JCo 2.x, but still it seems odd that we have codepage references in JCo 3.0.5 (<i>DestinationDataProvider.JCO_CODEPAGE</i>, <i>JCoCustomDestination.setCodepage(String)</i> and others).
    Cheers, harald

  • JCO RFC Problem

    Hello,
    I am trying to call BAPI Using RFC - JCO connections from EJB with the help of below document.
    http://help.sap.com/saphelp_nw04/helpdata/en/17/d609b48ea5f748b47c0f32be265935/frameset.htm
    I have two questions here,
        DestinationService dstService = (DestinationService)
        ctx.lookup(DestinationService.JNDI_KEY);
    DestinationService is null here, i guess i could not get destination service from IntialContext.
    After getting the client, how do we call Function module?
    JCO.Client client = JCO.createClient(jcoProperties);
    is it the same way as direct connection...
    http://help.sap.com/saphelp_nw04/helpdata/en/de/e6c9255044b241a9401a3a1b7009a9/frameset.htm
    Please help me, how to solve this issue.
    Regards,
    Learner

    Destination Serive is null, because you have not specified any Reference to the interface.
    in the .ear project - application-j2ee-engine.xml file, you need to specify the refence like this,
         <reference
              reference-type="hard">
              <reference-target
              provider-name="sap.com"
              target-type="interface">tcsecdestinations~interface</reference-target>
              </reference>
    After getting client connection same way you will access the, JCO direct connection.
    RFCDestination rfcDestionation =
              (RFCDestination) dstService.getDestination("RFC", "RFC_Destination");
    Properties jcoProperties = rfcDestionation.getJCoProperties();          
    mConnection = JCO.createClient(jcoProperties);
    mConnection.connect();
    JCO.Repository sapJcoRepository = new JCO.Repository ("SAPJCorep", mConnection);
    JCO.Function iFunction = sapJcoRepository.getFunctionTemplate("Z2_INCOMING_MOVEMENTS").getFunction();
    get and set paramters, in regular way. Reply me, if you have any more issues.
    Regards,
    Sridhar

  • Sun One EJB problem - PortableRemoteObject.narrow ClassCastException...

    Hi all,
    I'm using Sun One app server 7 for the first time and am having a bit of difficulty. I have deployed a very simple EAR containing one stateless session bean just to test it. The ear appears to have deployed correctly but PortableRemoteObject.narrow is throwing a ClassCastException when trying to do a remote lookup on the bean.
    I'm using the following env settings...
    initialContextFactory = com.sun.enterprise.naming.SerialInitContextFactory
    providerUrl = iiop://127.0.0.1:3700The lookup appears to work okay - this line of code executes successfully
    Object objref = initialContext.lookup(jndiHomeName);...objref appears to initalise succesfully (if I toString() it I get an iiop stream of some sort). However, it is the next line that is failing...
    Object obj = PortableRemoteObject.narrow(objref, homeClass);...this is the exception I get...
    java.lang.ClassCastException
         at com.sun.corba.se.internal.javax.rmi.PortableRemoteObject.narrow(Unknown Source)
         at javax.rmi.PortableRemoteObject.narrow(Unknown Source)
         at com.scorlog.ServiceLocator.getRemoteHome(ServiceLocator.java:145)Furthermore, when PortableRemoteObject.narrow() executes, I get the following console exception on the server...
    com.sun.corba.ee.internal.core.DuplicateServiceContext
            at com.sun.corba.ee.internal.core.ServiceContexts.put(ServiceContexts.java:208)
            at com.sun.corba.ee.internal.iiop.ServerRequestImpl.getServiceContextsForReply(ServerRequestImpl.java:258)
            at com.sun.corba.ee.internal.iiop.ServerRequestImpl.createResponse(ServerRequestImpl.java:89)
            at com.sun.corba.ee.internal.POA.SubcontractResponseHandler.createReply(SubcontractResponseHandler.java:50)
            at org.omg.CosNaming.NamingContextExtPOA._invoke(NamingContextExtPOA.java:377)
            at com.sun.corba.ee.internal.POA.GenericPOAServerSC.dispatchToServant(GenericPOAServerSC.java:569)
            at com.sun.corba.ee.internal.POA.GenericPOAServerSC.internalDispatch(GenericPOAServerSC.java:211)
            at com.sun.corba.ee.internal.POA.GenericPOAServerSC.dispatch(GenericPOAServerSC.java:113)
            at com.sun.corba.ee.internal.iiop.ORB.process(ORB.java:275)
            at com.sun.corba.ee.internal.iiop.RequestProcessor.process(RequestProcessor.java:83)
            at com.iplanet.ias.corba.ee.internal.iiop.ServicableWrapper.service(ServicableWrapper.java:25)
            at com.iplanet.ias.util.threadpool.FastThreadPool$ThreadPoolThread.run(FastThreadPool.java:288)
            at java.lang.Thread.run(Thread.java:534)
    FINE: No SAS context element found in service context listI have seen the forum that other users have had similar problems and the suggestion was that the client can't see the ejb stubs. I don't think this is the problem in my case as I deployed the same ear on weblogic 7 (obviously substituting sun-ejb-jar.xml for a weblogic-ejb-jar.xml) and successfully executed the same client code for the remote lookup.
    My feeling is that the problem revolves around the JNDI binding. Could it be the case that even though the object is binding properly, the app server doesn't realise it is an ejb and not a jdbc/jms/mail object? The documentation gives details on looking up a JDBC, javamail, URL, JMS resource (http://docs.sun.com/source/817-2177/djjndi.html) but not ejb so I could be doing something simple wrong here...
    My sun-ejb-jar.xml is as follows....
    <?xml version="1.0" encoding="UTF-8"?>
    <!-- Generated by XDoclet -->
    <sun-ejb-jar>
        <enterprise-beans>
            <ejb>
                <ejb-name>SBTest</ejb-name>
                <jndi-name>ejb/SBTestBean</jndi-name>
            </ejb>
        </enterprise-beans>
    </sun-ejb-jar>However, I noticed on another thread, a user had some additional elements under their <ejb> tag like this...
    <?xml version="1.0" encoding="UTF-8"?>
    <sun-ejb-jar>
      <enterprise-beans>
        <name>Ejb1</name>
        <ejb>
          <ejb-name>HelloBean</ejb-name>
          <jndi-name>HelloBean</jndi-name>
          <ejb-ref>
            <ejb-ref-name>ejb/helloBean</ejb-ref-name>
            <jndi-name>HelloBean</jndi-name>
          </ejb-ref>
        </ejb>
      </enterprise-beans>
    </sun-ejb-jar>However, when I tried to add and <ejb-ref> element to my xml doc the ear failed to deploy. This is the error I get in the admin console...
    Error
    Deployment Error -- Error while running ejbc -- Fatal Error from EJB Compiler -- --
    Failed to load deployment descriptor for: testApp cause: Error converting J2EE-
    specific ejb xml to object representation: testApp.jar app_testApp Generated by
    XDoclet This bean has no ejb reference by the name of [ejb/SBtest]
    ejb/SBTestSBTestThis problem is eating up my time and being made all the more frustrating by the fact that a) it deploys on weblogic and b) the documentation is terrible. Even the sample application that comes with sun one only provides the .class files for the code that does the ejb look up and not the .java so you can't see how they hell they do it!
    Unfortunately I am tied to using Sun One so I really need to solve this problem fast. If anyone can provide any help I'd greatly appreciate it.
    Cheers,
    John :)

    I am having the same problem after upgrading to Sun One from iplanet. Any clue?

Maybe you are looking for

  • How do I connect an external monitor to my MacBook Air?

    How do I connect an external monitor to my MacBook Air?

  • Extending Flash Javascript

    After finding out about the capabilities of (java)scripting in Photoshop, I'm curious to know if there's similar functionality for Flash. After some searching I found the 'Extending Flash'-documentation (please direct the currently inactive Flash Jav

  • Session Tracking problem

    I am doing session tracking in jsp. what my purpose is i want to stop the user, if the user is already logged in. For this, i am creating a Hashtable and entering the user id and session id as key- value pairs into the hashtable when the user is logg

  • TS1347 How to sink ipad to windows live mail in my laptop

    I am trying to sink the contacts and calendar back into my Windowns Live Mail in my Laptop, but I cannot make it happen.  Please let me know if anyone knows a good way to do it. Thank you, Appletomk

  • Ng finder search in Lion

    I'm still trying to figure out the anomalies or functionality of the (10.7.4) Finder "find" command at this late date. I posted this once before and got many useful tips- among them using EasyFind (good but slow).  I'm now hitting a wall such that I'