cancel
Showing results for 
Search instead for 
Did you mean: 

JNDI lookup failure

Former Member
0 Kudos

Hi Experts!

I want to execute java proxy call from my standalone java application as described here in the 3.13 section:

https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/d06315a6-e66e-2910-039c-ba8bbbd2...

I imported all the needed jar files I think.

My project is a simple java project not a ejb one.

In the ID I generated successfully the proxy object for the interface name FlightSeatAvailabilityQueryOut .

I could successfully get the initial context to my java application.

Now I want to look up my object called FlightQueryOut as the pdf said,but I can't, because the error said: <b>Object not found in lookup of FlightQueryOut</b>

my revelant code:

Object ref = ctx.lookup("FlightQueryOut");

How can I my bind my proxy object to my J2ee naming system?

It is not done automatically when I am generating the proxy in the ID?

If it does, then where can I see generated proxy object name in JNDI service in the J2ee engine?

I also tried the Object ref = ctx.lookup("java:comp/env/ejb/FlightQueryOut");

but it didn't work also.

Please help

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Gerg,

Hope you have deployed the Java Proxy EAR in to J2EE Engine.

Then, try the following name for lookup

Object ref = ctx.lookup("sap.com/<EAR Name of the JavaProxy>/<Java Proxy BeanName>");

eg: Object ref = ctx.lookup("sap.com/JavaProxyTest/JPOB_PortTypeBean");

JavaProxyTest - EAR Name

JPOB_PortTypeBean - Bean Name

JNDI Name can be found in Visual Admin of the J2EE Engine under Server Servcie 'JNDI Registry'.

Regards,

Sudharshan N A

Message was edited by:

Sudharshan Aravamudan

Former Member
0 Kudos

Hi SudHarsan!

I did not deploy the java Proxy EAR. Beacuse I can't even create an EJB modul project in my eclipse, because I use a simple one, not the SAP developer studio.

How can I upgreade my eclipse to be able to do this and the others.

with this: or there is another way?

<a href="http://download.eclipse.org/webtools/">Eclipse webtool platform</a>.

Former Member
0 Kudos

Gerg,

There are two portions.

1) In NWDS you import the Java Client Proxy generated form Integration builder, build EJB, then create an Enterprise Application, EAR and deploy the EAR to the desired J2EE Engine (i.e XI J2EE engine).

2) In eclipse or any IDE, use standard J2SE code to look up the bean deployed in the J2EE Engine.

Use the How to document for reference.

Regards,

Sudharshan N A

Former Member
0 Kudos

Hi!

Let's see the second option please, because I have not got NWDS.

Because my eclipse in not so smart, I can't create an ejb project, therefore I can't deploy my beans to look it up with the JNDI.

So what should I do?

Upgrade my Eclipse? Or I can do something else?

Is it right that the beans belonging to my proxy object which I am generated in the ID from an interface, is not deployed automatically? And I must do it manually therefore?

Thanks for help

stefan_grube
Active Contributor
0 Kudos

You can use the deploy tool.

See note 653833 for details.

Regards

Stefan

Former Member
0 Kudos

Hi !

I made all the configurations and operations until I got to the 'deploy the ear file' point.

When I want to my deploy my ear file, the deploy tool pops up this message:

ERROR: Not deployed. Deploy Service returned ERROR:

java.rmi.RemoteException: Cannot deploy application sap.com/FlightQueryOut..

Reason: Incorrect application sap.com/FlightQueryOut:

Bean FlightSeatAvailabilityQueryOut_PortTypeBean: Cannot load class com.sap.xi.xI.demo.agency.FlightSeatAvailabilityQueryOut_PortTypeBean.; nested exception is:

com.sap.engine.services.deploy.container.DeploymentException: <--Localization failed: ResourceBundle='com.sap.engine.services.deploy.DeployResourceBundle', ID='com.sap.engine.services.ejb.exceptions.deployment.EJBDeploymentException: Incorrect application sap.com/FlightQueryOut:

Bean FlightSeatAvailabilityQueryOut_PortTypeBean: Cannot load class com.sap.xi.xI.demo.agency.FlightSeatAvailabilityQueryOut_PortTypeBean.

at com.sap.engine.services.ejb.deploy.verifier.Verifier.check(Verifier.java:66)

at com.sap.engine.services.ejb.deploy.DeployAdmin.generate(DeployAdmin.java:253)

at com.sap.engine.services.ejb.EJBAdmin.deploy(EJBAdmin.java:2144)

at com.sap.engine.services.deploy.server.application.DeploymentTransaction.makeComponents(DeploymentTransaction.java:606)

at com.sap.engine.services.deploy.server.application.DeployUtilTransaction.commonBegin(DeployUtilTransaction.java:321)

at com.sap.engine.services.deploy.server.application.DeploymentTransaction.begin(DeploymentTransaction.java:307)

at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:292)

at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhases(ApplicationTransaction.java:326)

at com.sap.engine.services.deploy.server.DeployServiceImpl.makeGlobalTransaction(DeployServiceImpl.java:3184)

at com.sap.engine.services.deploy.server.DeployServiceImpl.deploy(DeployServiceImpl.java:553)

at com.sap.engine.services.deploy.server.DeployServiceImplp4_Skel.dispatch(DeployServiceImplp4_Skel.java:1555)

at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:320)

at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:198)

at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4SessionProcessor.java:129)

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:100)

at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)

', Arguments: []--> : Can't find resource for bundle java.util.PropertyResourceBundle, key com.sap.engine.services.ejb.exceptions.deployment.EJBDeploymentException: Incorrect application sap.com/FlightQueryOut:

Bean FlightSeatAvailabilityQueryOut_PortTypeBean: Cannot load class com.sap.xi.xI.demo.agency.FlightSeatAvailabilityQueryOut_PortTypeBean.

<b>I think this says, that my bean class file cannot be loaded</b>. I do not why because, I add my folder to the path, where my class can be found,and the "add j2ee component "" part of the deploy, where I can set the local remote interfaces no error occurs after saving, so my class can be seen by the tool, because the first step I set it correctly, I think

Please help.

stefan_grube
Active Contributor
0 Kudos

I am sorry, note 653833 is for XI 2.0.

See note 758048 instead.

Regards

Stefan

Former Member
0 Kudos

Hi!!

Yes you were right! I made all the revelant setting. I made my bean jar, I assemple it to an ear file without any error.

In the deploy tab in the the extra information tab I added the libraries corretctly I think.

I also connected to the j2ee engine.

But when I tried to deploy my ear file this exeption occured:

07/10/01 11:21:38 - ERROR: Not deployed. Deploy Service returned ERROR:

java.rmi.RemoteException: Cannot deploy application sap.com/FlightQueryOut..

Reason: Exception during generation of components of application sap.com/FlightQueryOut in container EJBContainer.; nested exception is:

com.sap.engine.services.deploy.exceptions.ServerDeploymentException: Exception during generation of components of application sap.com/FlightQueryOut in container EJBContainer.

What is wrong?

Former Member
0 Kudos

Hi!

I found something. My <b>com.sap.guid</b> component has not been deployed yet I think, because I can't see this in j2ee visual administrator server-libraries node.

But I must set this component as a reference in the extra information tab in the deployer tab.

can this occur the error while deploying the ear file?

If it could? how can I deploy this library. I found a documentation, the I must use the SDM tool. But when I try to deploy the guidgenerator.jar this error occur:

The information about the development component found in the manifest is either missing or incomplete!

I tried this with lots of jar files which all contains the manifest.fm file, but the error always occurs.

If I install the developer studio is it possible to deploy my proxies easier?or this com.sap.guid will be missed too while deploying?

Please help.

Former Member
0 Kudos

Anybody?

I just want to deploy the guidgenerator.jar library, because without this jar file, I cannot deploy my own ear file.

I found a documentation, the I must use the SDM tool. But when I try to deploy this error occur:

The information about the development component found in the manifest is either missing or incomplete!

I tried this with lots of jar files which all contains the manifest.fm file, but the error always occurs.

Please help

ravi_raman2
Active Contributor
0 Kudos

Gerg,

All versions of eclipse can do the ejb generation as far as i am aware..

Open a j2ee perspective and work.............

Regards

Ravi Raman