Implementing a java connector

Has anyone tried implementing a JCA Resource Manager the would integrate into a J2EE server for communication with a remote server?
I'm thinking about implementing one for connectivity with an Http server....
Has anyone tried something of this sort?

mkx wrote:
Hi,
we are currently implementing a Java connector for the X11 windowing system and we're running into trouble with event handling.
What we are doing is to fork a thread from the main application that will then invoke a native event handling loop that will listen for X11 events. Whenever such an event occurs, it will call back to a Java object to report that event.
While receiving and reporting events works fine, any successive calls from the main thread to the native windowing functions will block the program.
Let me outline the call order again:
1. Java application is started, main thread created
2. New Java thread is started that invokes a native method that itself runs in a while loop
3. Normal program flow continues in the main Java thread
4. Main Java thread now calls some native method, and locks up
Any idea why this is happening? Is it not possible to invoke the same native code within two distinct Java threads? I have looked into the JNI functions AttachCurrentThread and DetachCurrentThread, but they only seem to handle the problem that two native threads share the same JVM, but that's not what we need. We have two Java threads that need to share the same native code.Are you sure its not a problem with the something in the X11 code being non-reentrant?
http://www.gnu.org/software/libc/manual/html_node/Nonreentrancy.html#Nonreentrancy
Jim S.

Similar Messages

  • Java connector Approach

    HI,
    MY requirment is as follows :
    the customer has employee base of 1000, he has SAP R/3 installed for which he has only 100 user license available.
    The customer wants to implement HR module which should be used by all 1000 employees in the organization.
    Our Approach :  we want to implement the Java Connector which will be consuming only one license  to acces the data from R/3
    EX :
    mConnection =
    JCO.createClient("400", // SAP client
    "user", // userid
    "********", // password
    "EN", // language
    "iwdf5020", // host name
    "00"); // system number
    mConnection.connect();
    and develop a web Application, which we will be updating the standard infotypes in R/3.
    Finally deploy the application some Tomcat server and make it available across the organization
    Please let me know the approach is feasible or any other option is available ???
    Thanks & Regards,
    vijay.

    thanks, this was really helpful!
    now i need to get the right vCompany. according to the api-docs that's an instance of ICompany and it seems like this is the way to set all the connection parameters... how do i do that?
    maybe i should be more precise.. what exact properties of the ICompany do i have to set in order to connect to a company?
    i tried with the folowing but did not succeed:
    vCompany = SBOCOMUtil.newCompany();
    vCompany.setServer("10.0.0.152"); //the sap / sql server's ip address
    vCompany.setCompanyDB("SBODemo_Swiss");
    vCompany.setUserName("username");
    vCompany.setPassword("password");
    vCompany.connect(); //returns -8008 (Error while trying to initialize database)
    (of course i replaced username and password with those of a valid user)
    if i add those two lines before the connect statement:
    vCompany.setDbUserName("sa");
    vCompany.setDbPassword("password");
    connect returns -111 which means "Connection to SBO-Common has failed"
    adding a line that sets the language doesn't change anything..
    now i don't know if this really was a step forward or not, but i think it was since i get -8008 even if i enter the wrong ip ...
    what am i missing?
    if all these questions have already been answered in a tutorial or in any document, please give me a link or a hint what to look for, since i didn't find it so far.
    kind regards
    pascal suter
    <i>i keep updating this post as i proceed and as long as i don't get an answer ;)</i>
    Message was edited by: Pascal Suter

  • Sharing the Metadata Repository (SAP Java Connector)

    Is it possible to share the metadata repository across multiple client processes in the context of the SAP Java Connector?  If so, can someone point me to the technique that I have to implement?
    Each client process creates its own JCO.Pool (with a unique key) and obtains a repository by invoking JCO.createRepository(...).
    Thanks in advance.

    Hi jim,
    You will probably find the answer in this article :
    <a href="http://www.winfobase.de/lehre/lv_materialien.nsf/intern01/84528E02791D4B16C1256E7B004B9571/$FILE/Tips&Tricks_JCo_Programming.pdf">Tips and Tricks in JCO Programming</a>
    Regards,
    Mathieu

  • Programming restrictions for JCA (Java Connector Architecture)

    I need to know programming restrictions for JCA (Java Connector Architecture) from a Client program's perspective. Could somebody help my?

    If you are on the client side of JCA you just have to use the resource adapter implementation. Therefore client code is limited to the package javax.resource.cci. So I think there are no restriction from JCA itself.
    What technique you use on client side to connect to the resource adapter is up to you and "just" have to follow the restriction in that area.

  • Thru Java connector to update SAP by BAPI

    Dear...
    How to bring the data from external application through the Java connector to SAP?  Pls help....

    Hai Check the following Document & Links
    Bapi to create customer master 
    BAPI_CUSTOMER_CREATEFROMDATA
    BAPI_CUSTOMER_CREATEFROMDATA1
    Or you can use FM SD_CUSTOMER_MAINTAIN_ALL
    what is BAPI?
    BAPI stands for Business API(Application Program Interface).
    I have answered this question before..
    A BAPI is remotely enabled function module ie it can be invoked from remote programs like standalone JAVA programs, web interface etc..
    You can make your function module remotely enabled in attributes of Function module but
    A BAPI are standard SAP function modules provided by SAP for remote access. Also they are part of Businees Objest Repository(BOR).
    BAPI are RFC enabled function modules. the difference between RFc and BAPI are business objects. You create business objects and those are then registered in your BOR (Business Object Repository) which can be accessed outside the SAP system by using some other applications (Non-SAP) such as VB or JAVA. in this case u only specify the business object and its method from external system in BAPI there is no direct system call. while RFC are direct system call Some BAPIs provide basic functions and can be used for most SAP business object types. These BAPIs should be implemented the same for all business object types. Standardized BAPIs are easier to use and prevent users having to deal with a number of different BAPIs. Whenever possible, a standardized BAPI must be used in preference to an individual BAPI.
    The following standardized BAPIs are provided:
    Reading instances of SAP business objects
    GetList ( ) With the BAPI GetList you can select a range of object key values, for example, company codes and material numbers.
    The BAPI GetList() is a class method.
    GetDetail() With the BAPI GetDetail() the details of an instance of a business object type are retrieved and returned to the calling program. The instance is identified via its key. The BAPI GetDetail() is an instance method. BAPIs that can create, change or delete instances of a business object type
    The following BAPIs of the same object type have to be programmed so that they can be called several times within one transaction. For example, if, after sales order 1 has been created, a second sales order 2 is created in the same transaction, the second BAPI call must not affect the consistency of the sales order 2. After completing the transaction with a COMMIT WORK, both the orders are saved consistently in the database.
    Create( ) and CreateFromData! ( )
    The BAPIs Create() and CreateFromData() create an instance of an SAP business object type, for example, a purchase order. These BAPIs are class methods.
    Change( )
    The BAPI Change() changes an existing instance of an SAP business object type, for example, a purchase order. The BAPI Change () is an instance method.
    Delete( ) and Undelete( ) The BAPI Delete() deletes an instance of an SAP business object type from the database or sets a deletion flag.
    The BAPI Undelete() removes a deletion flag. These BAPIs are instance methods.
    Cancel ( ) Unlike the BAPI Delete(), the BAPI Cancel() cancels an instance of a business object type. The instance to be cancelled remains in the database and an additional instance is created and this is the one that is actually canceled. The Cancel() BAPI is an instance method.
    Add<subobject> ( ) and Remove<subobject> ( ) The BAPI Add<subobject> adds a subobject to an existing object inst! ance and the BAPI and Remove<subobject> removes a subobject from an object instance. These BAPIs are instance methods.
    Check these Links out
    http://searchsap.techtarget.com/ateQuestionNResponse/0,289625,sid21_cid558752_tax293481,00.html
    http://www.sap-img.com/abap/interview-question-on-bapi-rfc-abap-objects-tables.htm
    http://www.sap-img.com/fu033.htm
    http://www.sap-img.com/abap/ale-bapi.htm
    Please check out this thread..
    Re: bapi
    Also refer to the following links..
    www.sappoint.com/abap/bapiintro.pdf
    www.sap-img.com/bapi.htm
    www.sap-img.com/abap/bapi-conventions.htm
    www.planetsap.com/Bapi_main_page.htm
    www.sapgenie.com/abap/bapi/index.htm
    <b>Checkout !!
    http://searchsap.techtarget.com/originalContent/0,289142,sid21_gci948835,00.html
    http://techrepublic.com.com/5100-6329-1051160.html#
    http://www.sap-img.com/bapi.htm
    http://www.sap-img.com/abap/bapi-conventions.htm
    http://www.sappoint.com/abap/bapiintro.pdf
    Java Connector(JCO) can call not only BAPI's but also the function modules which are remotely enabled..
    BAPI's as i said earlier are remotely enabled function modules..
    Hence, JCO can call also BAPI's(n not only BAPI's as u mentioned).</b>
    Thanks & regards
    Sreenivasulu P

  • Java Connector and RFCs

    Hi Experts,
    i'm currently in a SAP IS-Retail implementation and i need to invoke RFCs (SAP RFCs) in a third-party system.
    If this third-party system is a java based application, may they use the SAP Java Connector to invoke our (SAP) RFCs???
    Thank you very much.
    Kind Regards,
    Paulo

    Hi Paulo,
    For the kind of situtaion you have stated, SAP JCo is the best answer and you can also see the number of recomendations you have got.
    CHECK-LIST for JCo
    First download the JCo connector from OSS which is compatibale to the version you are using.
    then
    1) install Java and configure the class path in Desktop > My computer ( Right-click) > properties > Environment variables > class path
    2) We have also used Tomcat and ant server, so please check them if you need.
    3) 'librfc32.dll' in WinowsNT > System32 > replace.
    4) sapjcorfc.dll and SAP JCO in the java class path, also the documents and other demo's place it in java folder.
    5) Create connections in java with the program given Example1.java and connections are given above.
    6) in SAP, go to RFC connection, in create connection we have to
    name as JCo
    Type as TCP/IP connections
    Description - anything you wish
    Activation type - Registered Sever Program
    Program -JCOSERVER01( as I remember)
    hope its useful.
    cheers
    ajay

  • Error while deploying MDM Java Connector for EP

    Hi,
    i am a newbie to MDM.i am trying to develop a portal component with the blog "Using MDM5.5 Java Connector with SAP Enterprise Portal 6.0" as reference.
    i created an MDM system in portal and the connection tests passed.
    But when i deploy the code i get the following exception-
    java.lang.NullPointerException
         at com.sap.mdm.connector.connection.MdmConnectionFactory.getConnectionEx(MdmConnectionFactory.java:170)
         at com.sap.portal.ivs.internalconnector.ConnectionProvider.getConnection(ConnectionProvider.java:304)
         at com.sap.portal.ivs.internalconnector.ConnectionProvider.getConnection(ConnectionProvider.java:258)
         at com.sapportals.portal.ivs.cg.ConnectorService.getConnection(ConnectorService.java:478)
         at com.sapportals.portal.ivs.cg.ConnectorService.getConnection(ConnectorService.java:85)
         at com.cts.mdm.MDMtestcomp.doContent(MDMtestcomp.java:36)(this points to the line <b>connection = cgService.getConnection("MDM_SYSTEM_ALIAS", prop);</b>)
         at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:209)
         at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalComponent.java:114)
         at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:328)
    This is my code-
    IConnectorGatewayService cgService = (IConnectorGatewayService)
                   PortalRuntime.getRuntimeResources().getService(IConnectorService.KEY);
              ConnectionProperties prop =
              new ConnectionProperties(request.getLocale(), request.getUser());
                   IConnection connection = null;
                   connection = cgService.getConnection("MDM_SYSTEM_ALIAS", prop);
         INative nativeInterface = connection.retrieveNative();
                        CatalogData catalog = new CatalogData();
                             catalog = (CatalogData)
                   nativeInterface.getNative(CatalogData.class.getName());
                        ResultSetDefinition rsd = new ResultSetDefinition("Customers");
              rsd.AddField("Name");
              Search search = new Search("Customers");
              A2iResultSet rs = null;
                             rs = catalog.GetResultSet(search,rsd,"Name",true,0);
    response.write(rs.GetFields().toString());
    Have i missed anything?
    Should i deploy any .jar file? (i've already deployed MDM4J.jar) and referenced it in portalapp!
    Thanks in advance
    SwarnaDeepika

    Hello Swarna:
    I believe than rather than deploying the MDM4J.jar, you should deploy this components:
    com.sap.mdm.tech.mdm4j.sda
    com.sap.mdm.tech.connector.sda
    BPMDMTECHN00_0.sca
    BPMDMAPPLI00_0.sca
    Once you deploy those, you should have no problems. Another solution would be to take your MDM4J.jar and wrap it into an SDA, then deploy, but that would be pretty much the same.
    Those components are included on your MDM CD. Please ensure you use the same Version/support package/hotfix all over your landscape.
    I hope that helps
    Alejandro

  • SAP Business One - Java Connector

    Hi All,
    <br/><br/>
    We have a SAP Business One Application installed on a laptop. The requirement is to be able to use the SAP Java API to update tables in the system. We are not allowed to connect directly to the database and was advised to use the API instead.
    <br/><br/>
    The downloaded API that we are using is "sapjco30P_6-10005324 32 bit.zip". I have included the dll file contained in this package in the WINDOWS/system32 folder. I am using Eclipse as IDE and already included the "sapjco3.jar" in the classpath.
    <br/><br/>
    First question: Am I using the right Java Connector for SAP Business One?
    <br/><br/>
    I got sample code on how to connect using JCO:
    <br/><br/>
    package sample;<br/><br/>
    import java.io.File;<br/>
    import java.io.FileOutputStream;<br/>
    import java.util.Properties;<br/>
    import java.util.concurrent.CountDownLatch;<br/><br/>
    import com.sap.conn.jco.AbapException;<br/>
    import com.sap.conn.jco.JCoContext;<br/>
    import com.sap.conn.jco.JCoDestination;<br/>
    import com.sap.conn.jco.JCoDestinationManager;<br/>
    import com.sap.conn.jco.JCoException;<br/>
    import com.sap.conn.jco.JCoField;<br/>
    import com.sap.conn.jco.JCoFunction;<br/>
    import com.sap.conn.jco.JCoFunctionTemplate;<br/>
    import com.sap.conn.jco.JCoStructure;<br/>
    import com.sap.conn.jco.JCoTable;<br/>
    import com.sap.conn.jco.ext.DestinationDataProvider;<br/><br/>
    public class StepByStepClient<br/>
    {<br/>
        static String ABAP_AS = "ABAP_AS_WITHOUT_POOL";<br/>
        static String ABAP_AS_POOLED = "ABAP_AS_WITH_POOL";<br/>
        static String ABAP_MS = "ABAP_MS_WITHOUT_POOL";<br/>
        static<br/>
        {<br/>
            Properties connectProperties = new Properties();<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_ASHOST, "localhost");<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_SYSNR,  "06");<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_CLIENT, "000");<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_USER,   "manager"); //sapuser<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_PASSWD, "manager"); //sap1234<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_LANG,   "en");<br/>
            createDataFile(ABAP_AS, "jcoDestination", connectProperties);<br/><br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_POOL_CAPACITY, "3");<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_PEAK_LIMIT,    "10");<br/>
            createDataFile(ABAP_AS_POOLED, "jcoDestination", connectProperties);<br/><br/>
            connectProperties.clear();<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_MSHOST, "localhost");<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_R3NAME,  "SID");<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_CLIENT, "000");<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_USER,   "manager"); //sapuser<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_PASSWD, "manager"); //sap1234<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_GROUP, "GROUP");<br/>
            connectProperties.setProperty(DestinationDataProvider.JCO_LANG,   "en");<br/>
            createDataFile(ABAP_MS, "jcoDestination", connectProperties);<br/>
        }<br/><br/>
        static void createDataFile(String name, String suffix, Properties properties)<br/>
        {<br/>
            File cfg = new File(name"."suffix);<br/>
            if(!cfg.exists())<br/>
            {<br/>
                try<br/>
                {<br/>
                    FileOutputStream fos = new FileOutputStream(cfg, false);<br/>
                    properties.store(fos, "for tests only !");<br/>
                    fos.close();<br/>
                }<br/>
                catch (Exception e)<br/>
                {<br/>
                    throw new RuntimeException("Unable to create the destination file " + cfg.getName(), e);<br/>
                }<br/>
            }<br/>
        }<br/><br/>
        public static void step1Connect() throws JCoException<br/>
        {<br/>
            JCoDestination destination = JCoDestinationManager.getDestination(ABAP_AS);<br/>
            System.out.println("Attributes:");<br/>
            System.out.println(destination.getAttributes());<br/>
            System.out.println();<br/><br/>
            destination = JCoDestinationManager.getDestination(ABAP_MS);<br/>
            System.out.println("Attributes:");<br/>
            System.out.println(destination.getAttributes());<br/>
            System.out.println();<br/>
        }<br/><br/>
        public static void main(String[] args) throws JCoException<br/>
        {<br/>
            step1Connect();<br/>
        }<br/>
    }<br/>
    <br/><br/>
    Each time I run the application I run into an error:
    <br/><br/>
    Attributes:<br/>
    Exception in thread "main" com.sap.conn.jco.JCoException: (102) JCO_ERROR_COMMUNICATION: Connect to SAP gateway failed<br/>
    Connection parameters: TYPE=A DEST=ABAP_AS_WITHOUT_POOL ASHOST=localhost SYSNR=06 PCS=1<br/><br/>
    LOCATION    CPIC (TCP/IP) on local host with Unicode<br/>
    ERROR       connection to partner '127.0.0.1:3306' broken<br/>
    TIME        Mon May 09 10:46:46 2011<br/>
    RELEASE     720<br/>
    COMPONENT   NI (network interface)<br/>
    VERSION     40<br/>
    RC          -6<br/>
    MODULE      gwxx.c<br/>
    LINE        646<br/>
    DETAIL      NiIRead: P=127.0.0.1:3306; L=0.0.0.0:50496<br/>
    SYSTEM CALL GwRead<br/>
    ERRNO       10054<br/>
    ERRNO TEXT  WSAECONNRESET: Connection reset by peer<br/>
    COUNTER     2<br/><br/>
         at com.sap.conn.jco.rt.MiddlewareJavaRfc.generateJCoException(MiddlewareJavaRfc.java:662)<br/>
         at com.sap.conn.jco.rt.MiddlewareJavaRfc$JavaRfcClient.connect(MiddlewareJavaRfc.java:1362)<br/>
         at com.sap.conn.jco.rt.ClientConnection.connect(ClientConnection.java:721)<br/>
         at com.sap.conn.jco.rt.PoolingFactory.init(PoolingFactory.java:103)<br/>
         at com.sap.conn.jco.rt.ConnectionManager.createFactory(ConnectionManager.java:293)<br/>
         at com.sap.conn.jco.rt.DefaultConnectionManager.createFactory(DefaultConnectionManager.java:46)<br/>
         at com.sap.conn.jco.rt.ConnectionManager.getFactory(ConnectionManager.java:262)<br/>
         at com.sap.conn.jco.rt.RfcDestination.initialize(RfcDestination.java:509)<br/>
         at com.sap.conn.jco.rt.RfcDestination.getAttributes(RfcDestination.java:347)<br/>
         at com.sap.conn.jco.rt.RfcDestination.getAttributes(RfcDestination.java:27)<br/>
         at sample.StepByStepClient.step1Connect(StepByStepClient.java:74)<br/>
         at sample.StepByStepClient.main(StepByStepClient.java:304)<br/>
    Caused by: RfcException: [null]<br/>
        message: Connect to SAP gateway failed<br/>
    Connection parameters: TYPE=A DEST=ABAP_AS_WITHOUT_POOL ASHOST=localhost SYSNR=06 PCS=1<br/>
    <br/><br/>
    Second question: What seems to be the problem with my sample application? Do I need to use a different Java Connector for SAP Business One or SAP Business One does not support Java Connector?
    <br/><br/>
    Please help.
    <br/><br/>
    Thank you all.
    Edited by: kevinroy on May 9, 2011 4:51 AM

    Hi,<br/>
    Thank you very much for the reply. I am now able to move forward with what I am doing.<br/>
    I used the following code in connecting but am encountering an error:<br/>
    public class ConnectSAP {
         // company interface
         public ICompany company;
         private SBOErrorMessage errMsg = null;
         public static void main(String[] args) {
              ConnectSAP company = new ConnectSAP();
              company.conn();
         //method make connection andinitialize company instance
         public int conn() {
              int rc = 0;
              try {
                   company = SBOCOMUtil.newCompany();
                   company.setServer("192.168.0.216"); //192.168.0.216
                   company.setCompanyDB("SBODemoUS");
                   company.setUserName("manager");
                   company.setPassword("manager");
                   company.setDbServerType(SBOCOMConstants.BoDataServerTypes_dst_MSSQL2005);
                   company.setUseTrusted(new Boolean(false));
                   company.setLanguage(SBOCOMConstants.BoSuppLangs_ln_English);
                   company.setDbUserName("username"); 
                   company.setDbPassword("password");
                   //company.setAddonIdentifier("...");     
                   //company.setLicenseServer("...");
                   rc = company.connect();
                   if (rc == 0) {
                        System.out.println("Connected!");
                   } else {
                        errMsg = company.getLastError();
                        System.out.println(
                             "I cannot connect to database server: "
                                  + errMsg.getErrorMessage()
                                  + " "
                                  + errMsg.getErrorCode());
              } catch (Exception e) {
                   e.printStackTrace();
                   return -1;
              return rc;
         public void freeConnection(){
              company.disconnect();
    }<br/>
    I am getting the error "Failed to Connect to SBOCommon -111".<br/>
    Error is still the same even if I set UseTrusted to true and comment the DbUserName and DbPassword.<br/>
    Do I need to specify the license? Or login to SAP before connecting?<br/>
    Thank you.

  • RFC JAVA CONNECTOR CAUSING THE JAVA TO BE IN SAFE MODE

    Hi GURUS :
    We have SolMan with JAVA as Add in . Now during the JSPM Launch the JSPM Aborts with the Err Messages as shown :
    in trace file dev_jrfc.trc and in defaultTrace we have this same message :
    >>>>
    #1.5 #0003BA951BE1004C0000000500007486000456B88DE8595D#1221250561628#com.sap.engine.services.rfcengine##com.sap.engine.services.rfcengine#J2EE_GUEST#0##n/a##d7e28da080f311ddc3de0003ba951be1#SAPEngine_Application_Thread[impl:3]_27##0#0#Error#1#/System/Server#Plain###Bean SLDJAVA_ACCESSOR_REQUESTnot found on host <fqdn of host name> ProgId =JCOLDAPI: Path to object does not exist at rfcaccessejb_stateful, the whole lookup name is rfcaccessejb_stateful/SLDJAVA_ACCESSOR_REQUEST.registered entries for FuctionName=JNDIName : {}#
    #1.5 #0003BA951BE1004C0000000600007486000456B88DE85D04#1221250561629#com.sap.engine.services.rfcengine##com.sap.engine.services.rfcengine.handleRequest#J2EE_GUEST#0##n/a##d7e28da080f311ddc3de0003ba951be1#SAPEngine_Application_Thread[impl:3]_27##0#0#Error##Plain###java.lang.RuntimeException: Bean SLDJAVA_ACCESSOR_REQUESTnot found on host <fqdn of host name>, ProgId =JCOLDAPI: Path to object does not exist at rfcaccessejb_stateful, the whole lookup name is rfcaccessejb_stateful/SLDJAVA_ACCESSOR_REQUEST.#
    #1.5 #0003BA951BE1004C0000000700007486000456B88DE85E8C#1221250561629#com.sap.engine.services.rfcengine##com.sap.engine.services.rfcengine.handleRequest#J2EE_GUEST#0##n/a##d7e28da080f311ddc3de0003ba951be1#SAPEngine_Application_Thread[impl:3]_27##0#0#Error##Plain###java.lang.RuntimeException: Bean SLDJAVA_ACCESSOR_REQUESTnot found on host <fqdn of host name>, ProgId =JCOLDAPI: Path to object does not exist at rfcaccessejb_stateful, the whole lookup name is rfcaccessejb_stateful/SLDJAVA_ACCESSOR_REQUEST.
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.handleRequest(RFCDefaultRequestHandler.java:138)
         at com.sap.engine.services.rfcengine.RFCJCOServer$J2EEApplicationRunnable.run(RFCJCOServer.java:254)
         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)
    <<<
    Now , this JCOLDAPI is Java RFC Connector with User PORTALADMIN and at the ABAP Side we see that the J2EE_ADMIN pwd was changed by this PORTALADMIN !! We had at the same time stamp, the message in the log file of the JSPM that credential supplied to log in to J2EE Engine is not valid ( 'cause, the PORTALADMIN had changed the PW
    of the J2EE_ADMIN ) - While attempting to Launch the JSPM for JAVA Patches > It aborts with the same above message !!
    Half of the SW Comp were updated and rest half aborts repeatedly with the above message.
    Same way the Vis Admin won't start with the msg that Credential to connect J2EE is not valid. Although there was no change at the Config Tool Secure Store > J2EE Admin and SAPSR3DB passwords !!
    I have changed both the J2EE_ADMIN and the PORTAL ADMIN to the User Type Service User ( note 622464 ) ..have
    kept the same pw at ABAP and configtool secure store. But the java is not coming up neither through SMICM nor through the startsap j2ee command as SMPADM.
    i.e. it would comeup only in SAFE Mode !!
    This JCOLDAPI RFC Java Connector 's PORTALADMIN has several rights at the ABAP Side and is used for EWA Purpose.
    JAVA is running in SAFE mode and no matter how many time I try at the config tool Side to bring it in normal mode it is not swithcing to normal mode > I disble the safe mode at the ConfigTool Side > Apply > Save . > Restart the JAVA through the jcmon > shutdown and restart cluster under #10 Cluster Admin Menu > it is coming up only in SAFE mode again with the abvoe error message !!! Restart through the SMICM don't even work at all !!. Also, the system is slow ..even to come in safe
    mode JAVA takes about 45 minutes !!!
    Also, since the JAVA is coming up only in safe mode the SLD and the browser page is not available. The jcomon displays the instance status as ' Synchronizing Binaries' since
    last 20 hours ..this  means that the instance is in hang state.
    Any idea how to solve this problem ?
    Thanks a Lot in Advance,
    Regards,
    - Ishan
    Edited by: ISHAN P on Sep 13, 2008 2:54 PM

    hi ishan,
    do you have solved the problem?? as ??
    thanks
    umberto

  • How to get pdf file from sap presentation server using java connector

    Hi Friends,
    with the below code i am able to get po details in pdf in presentation server.
    DATA : w_url TYPE string
           VALUE 'C:\Documents and Settings\1011\Solutions\web\files\podet.pdf'.
    CALL FUNCTION 'ECP_PDF_DISPLAY'
            EXPORTING
              purchase_order       = i_ponum
           IMPORTING
      PDF_BYTECOUNT        =
             pdf                  = file  " data in Xsting format
    *Converting Xstring to binary_tab
          CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
            EXPORTING
              buffer                = file
      APPEND_TO_TABLE       = ' '
    IMPORTING
      OUTPUT_LENGTH         =
            TABLES
              binary_tab            = it_bin " data in binary format
    **Downloading into PDF file
          CALL FUNCTION 'GUI_DOWNLOAD'
            EXPORTING
      BIN_FILESIZE                    =
              filename                        = w_url
              filetype                        = 'BIN'
             TABLES
              data_tab                        = it_bin
    when i am using java connector , to retirve the file from presentation server , the follwoing error i am getting...
    init:
    deps-jar:
    compile-single:
    run-single:
    com.sap.mw.jco.JCO$Exception: (104) RFC_ERROR_SYSTEM_FAILURE: Error in Control Framework
            at com.sap.mw.jco.rfc.MiddlewareRFC$Client.nativeExecute(Native Method)
            at com.sap.mw.jco.rfc.MiddlewareRFC$Client.execute(MiddlewareRFC.java:1244)
            at com.sap.mw.jco.JCO$Client.execute(JCO.java:3842)
            at com.sap.mw.jco.JCO$Client.execute(JCO.java:3287)
            at PdfGen.<init>(PdfGen.java:35)
            at PdfGen.main(PdfGen.java:78)
    Java Result: 1
    BUILD SUCCESSFUL (total time: 1 second)
    i debugged too, problem with <b>gui_download......</b>
    I am very glad to all with your suggestions!!
    Regards,
    Madhu..!!

    Hi
    You can try to create an external command (transaction SM69).......sorry I've forgotten,,,,they works on application
    How do you call CL_GUI_FRONTEND_SERVICES=>EXECUTE?
    Max
    Edited by: max bianchi on Oct 13, 2011 10:27 AM

  • How to install the SAP Java Connector

    Hi,
    I am unsure how to install the SAP Java Connector on Linux (Suse Linux Enterprise 10). The SAP Integration Kit install and admin guide says:
    ===
    u2022 Copy the librfccm library and the libsapjcorfc library to busines
    sobjects_root/enterprise120/PLATFORM_PATH, where busines
    sobjects_root is the full path to your businessobjects directory,
    and PLATFORM_PATH is your platform. For example, PLATFORM_PATH
    is solaris_sparc for an installation on Solaris.
    u2022 Use symbolic links for the location of the librfccm library and the lib
    sapjcorfc library.
    u2022 Add the location of the librfccm library and the libsapjcorfc library
    to the library path.
    ===
    Do I have to do all 3 steps or is the 1st one (copying of files) enough?
    On the other hand, the SAP Java Connector guide says:
    ===
    Then add {sapjco-install-path} to the LD_LIBRARY_PATH environment variable.
    Finally, add {sapjco-install-path}/sapjco.jar to your CLASSPATH environment variable.
    ===
    So, what to do?
    Thanks!

    Thanks for your help. So i copied the 2 files as mentioned in point 1.
    Where do I have to copy the file sapjco.jar to? There is no shared lib folder after installing BO Edge 3.1 on a Linux system.
    I copied the sapjco.jar to /bobje/tomcat/common/lib but still get the message that the Java Connector files are not in the correct directory.
    I already copied the files librfccm.so and libsapjcorfc.so to /bobje/enterprise120/linux_x86 .
    Thanks again!
    Edit: problem solved: Copying the sapjco.so to tomcat/shared/lib is correct, if the directory doesn't exist then just create it (mkdir). The message is just plain information 7 hint.

  • Enterprise JavaBeans and SNMP Java Connector

    There is possible to develop a Java Connector that will allow my J2EE application to collaborate ( send , receive) SNMP commands with various network devices ( sensors, Access Points, hardware devices).
    The information eventualy will be pushed back to the subscribed users using AJAX technologies.
    Mike

    Hi,
    I do not get your question.....
    You want to connect from MI7.1 directly to a BAPI in the Middleware? Well, in 7.0 there was Generic Sync to do that - and I think this should be still there. With Generic sync it was possible to connect to call any BAPI in the middleware directly - if your user had appropiate rights. Check MDK for details.
    And if you want to do that in our own app - if this is the intention of your question.... well.... then I would tell you this is under SAP (C), so as you know you could decompile the MI client code, but this is not allowed.
    But I guess it was the first thing you are after, so see if that answer helps. But even there you need the running MI middleware - and this thing confused me in your question - are you using MI already or not and what do you want to do?
    Regards,
    Oliver

  • Is this possible: SAP Java Connector - XI - R3 with XI RFC Adapter?

    Hi,
    I try to call a RFC on a remote R/3 System over the XI Server in a Java Application with SAP Java Connector.
    I have configured a RFC Sender Adapter in XI. I get the
    following Exception:
    "lookup of alternativeServiceIdentifier via CPA-cache failed for channel 'SenderChannel_RFC"!
    Is this scenario possible? Or do the connection from
    a SAP Java Connector App to the XI RFC Adapter not work?
    You can't set the Client and System ID of a Third-Party or
    Standalone Java system in the SLD.
    Thanks for any help!
    Regards
    Wolfgang

    Hi,
    We use a JCO for directly connecting to sap systems.
    In that case we need not use any XI also.
    But if you want to use RFC adapter and java application the best way is to use java proxies as sender and reciever as RFC adapter.
    I donot think there is any  architectural significance in using rfc adapter of XI while using JCO.
    Let me know if I mis-understood the context.

  • Using Java Connector Calling RFC.....But it's not returning correct result

    Hi Friends,
    In the code ....
    I am calling Remote Function module ZRFC_PO_VEND_VALID using java connector and passing PO_Number and Vendor Number as input parameters and after execution it returns (E_POVALID =1 [PO_NUMBER exists for Vendor number] otherwise E_POVALID = 0 )
    when i am executing the below code ....in both cases it is returning Zero value.
    I tested the function module in se37 its working....
    may i know the reason for this....
    import com.sap.mw.jco.*;
    @author Thomas G. Schuessler, ARAsoft GmbH
    http://www.arasoft.de
    public class TutorialBapi1 extends Object {
    JCO.Client mConnection;
    JCO.Repository mRepository;
    public TutorialBapi1() {
    try {
    // Change the logon information to your own system/user
    mConnection =
    JCO.createClient("100", // SAP client
    "abap", // userid
    "abap", // password
    "en", // language
    "sapdev1", // application server host name
    "00"); // system number
    mConnection.connect();
    mRepository = new JCO.Repository("ARAsoft", mConnection);
    catch (Exception ex) {
    ex.printStackTrace();
    System.exit(1);
    JCO.Function function = null;
    JCO.Table codes = null;
    try {
    function = this.createFunction("ZRFC_PO_VEND_VALID");
    if (function == null) {
    System.out.println("ZRFC_PO_VEND_VALID" +
    " not found in SAP.");
    System.exit(1);
    //mConnection.execute(function);
    JCO.Field vendID = function.getImportParameterList().getField("I_EBELN");
    JCO.Field poID = function.getImportParameterList().getField("I_LIFNR");
    vendID.setValue("20081");
    poID.setValue("4500000017");
    try {
    mConnection.execute(function);
    catch (Exception ex) {
         ex.printStackTrace();
         System.exit(1);
    JCO.Field povalid =
         function.getExportParameterList().getField("E_POVALID");
    //if (povalid.getValue() == null ){
         // System.out.println("Error Message");
    System.out.println(povalid.getValue());
         //if (povalid == null ){
              //System.out.println(povalid.getValue("E_POVALID"));
              //System.out.println("Error Message");
              //System.exit(1);
    catch (Exception ex) {
         ex.printStackTrace();
         System.exit(1);
    mConnection.disconnect();
    public JCO.Function createFunction(String name) throws Exception {
         try {
         IFunctionTemplate ft =
         mRepository.getFunctionTemplate(name.toUpperCase());
         if (ft == null)
         return null;
         return ft.getFunction();
         catch (Exception ex) {
         throw new Exception("Problem retrieving JCO.Function object.");
         public static void main (String args[]) {
         TutorialBapi1 app = new TutorialBapi1();
    with warm regards,
    Madhu.

    Hi Ravi ,
    I tried as per your sugggestion..still getting the same problem.
    Regards,
    Madhu!!

  • Need Standard BAPI To Create Opportunity in SAP Using Java Connector.

    Hi All,
         What is the standard BAPI to create an opportunity in SAP CRM through Java Connector.
    Please share code if available for doing same. I have found BAPI_OPPORTUNITY_CREATE_MULTI .
    How to create opportunity in SAP through java connector using BAPI_OPPORTUNITY_CREATE_MULTI .

    Hi,
    I think you can search for it or you can create a thread at ABAP section.

Maybe you are looking for

  • Go do I move my iTunes from one computer to another.

    How do I move my iTunes from one computer to another.

  • Macbook pro and Bootcamp for Windows 7 32bit

    looking for advice re setting up Bootcamp with Windows 7 on my new Macbook Pro 13".  Anything to be aware of??? Cheers

  • Merging 2 Hashmaps into 1

    What is the easyiest way to merge 2 Hashmaps into 1? So Say h1, h2 and hashmaps with data in, h3 is a empty hashmap that i want to contain all the values of h1 and h2. Only way I know how is to loop through each Hashmap and add the value pairs to the

  • Files missing(aif_core, aif_ogl, image_flow, image_runtime, and data_flow)

    Photoshop cannot start because Aif_core aif_ogl Image_flow image_runtime and data_flow are missing...? >.> aif_core aif_ogl image_flow image_runtime and data_flow are missing all my other cs4's have it but not photoshop i tried copying them from othe

  • Can I Lighten Photos in InDD?

    Hi Folks, Have a customer asking...can I lighten photos in InDD CS3? We typically pull it into PhotoShop, so have never tried. Can't find the capability anywhere, but it sure seems like it'd be something they'd build in to the program. Quark does it,