cancel
Showing results for 
Search instead for 
Did you mean: 

Please Can any one guide me, I am new to JAVA Server Proxy

Former Member
0 Kudos

One of my scenarios, I need to call Remote EJB from WEBLogicserver, to send request with employee no, employee name and get response from legacy with quite number of files like da,house rent details etc. Please can any help me in a way how call ejb remotely and application code to get response back.. this is very very big help folks. I never forget your help at all.

Thanks in advance

Regards

R

Accepted Solutions (0)

Answers (7)

Answers (7)

Former Member
0 Kudos

Hi Guys,

Did any one work on this sort of scenario.

Web Dynpro can call XI with BAPI, BAPI which is on XI platform. If i am wrong please correct me, how can we communicate WEB DYNPRO to XI.

Please quicker.

Thanks in advance

Regards

R

Message was edited by:

Roger Bass

Former Member
0 Kudos
Former Member
0 Kudos

Hi Shaji,

One more idea on this scenario, Can we call EJB from Webdynpro without XI. After Webdynpro supports views and model we can call EJB am I right in this. if yes How to call EJB without this process? have you got any idea? Please

Thanks for your great help.

Regards

R

Former Member
0 Kudos

Yes you can call EJBs from web dynapro as it is being consumed by a JAVA client. Problem and concern around using a JAVA client is that, you are calling an EJB from another vendor's EJB container, it can have some way an attachement like point to point integration cuz you have to start worry about EJB client APIs, different containers, different versions etc.

In a single word it is possible but it is not a recomended approach. Any application components running in an application framework, if necessary to be consumed by a service enabled technology framework such XI, it is should be done using service enablement approach prescribed for the respective application component.

Here your application component is an EJB. EJBs can be easily exposed as a web service without making any troubles and it should be the AGILE approach.

Former Member
0 Kudos

Hi Shaji,

The answer is very useful, But can you give me some more bit elaborately, that would be really helpful. You know about this scenaio completely, have you got any sample scenario like call EJB from weblogic server, offcourse api's and handlers are bit differnt. Can you please help me to solve this problem.

Regards

R

Message was edited by:

Roger Bass

Former Member
0 Kudos

Hi Shaji,

I was discussed about publishing EJB with my Weblogic server management team, they said, some more servers are calling that EJB. They got some licensing issue to publish this EJB as web services. Only way is we need to call that EJB with JAVA Server Proxy. I must need to an application code to access EJB response fields.

The procedures are as follows: Please correct me if I am wrong.

1. Created Request and Response Message types.

2. Interfaces created, Proxy generated (.zip).

3. Open a J2EE project on NWDS – EJB Module Project.

4. Imported .zip (Proxy) file in ejbModule.

5. Add External jar files (4 of them).

6. “xxx_PortTypeImpl.templete” file changed to .Java extension to write Application code. (Waiting for application code)

7. Once I put application code in above .java file.

8. Creating the EJBs form the Java Proxy (Porttype Bean).

9. Assign JNDI name in the ejb-j2ee-engine.xml (Session bean stateless)

10. Build EJB Archive.

11. Create an Enterprise Application Archive (EAR), need to assign libraries.

Please Guys where and which bit I am missing please correct. Which is very big favour.

Regards

R

Former Member
0 Kudos

They have licensing issue to publish a J2EE component as web service???. Very strange. I have worked in more than 15 weblogic project, never heard it, BEA do not license their server for components, it is licensed for CPU. EJB is part of an enterprise J2EE application running in a weblogic server. All they are doing is create another web application using BEA IDES and create a web service component for the EJB available from same application server as web service.

Ask them to run an APPC program on the EJB and create the EJB client JAR file which will pack all necessary JAVA code to access the EJB from a remote JAVA code.

When you use that client jar source code in NWDS , make sure your JDK, BEA weblogic JDK are same also their J2EE version and your J2EE version also same.

Also keep in mind the way you are using the EJB client source code inside your proxy is nothing but looking into a JNDI tree from weblogic server using j2EE JNDI specification, get a handler, get a home interface of the EJB as per J2EE specification, get the remote interface of the EJB, call the business method.

You can invoke the EJB via ur client proxy java class you have created inside the NWDS for the XI integration scenario, so that weblogic access will be via JAVA client instead of WS client.

This will change your scenario from SAP Dynopro - XI - JAVA proxy (Instead of WS)

Thanks

Former Member
0 Kudos

Hi Ashutosh Moharir ,

Can you please give me an idea how to wrap EJB with web services.

Regards

Txs in advance

R

Former Member
0 Kudos

Please use the outbound scenario details outlined in the following how to guide to work with WEB Dynapro WS - > XI

https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/befdeb90-0201-0010-059b-f22...

Former Member
0 Kudos

I think your question is

How to call Remote EJB from Weblogic Server or Call Weblogic EJB from XI/PI framework.

You can only call EJBs through reference as long as they are part of same container implementation either through a clustered setup or between applications.

If you want to call EJB from a remote container, please expose the EJB as a web service. Use a web service client framework as access the remote EJB functionalities.

In case of XI

bring the remote EJB web service WSDL into the XI framework, build an inbound service using WSDL message types.

Configure an inbound SOAP adaptor using WSDL service URI

invoke the inbound service using SOAP inbound adaptor to call the remote EJB as part of a configuration scenario.

Thanks

Former Member
0 Kudos

Hi Friends,

I checked all, But these are not solving my problem. Let me explain bit more about my problem. I created interfaces, created proxies(.zip), On NWDS open a EJB project, imported proxy, added external jars done. After this I need an Application code for (send request with two fields get response from Weblogic server(legacy system) with 10 fields.) I believe you got my request.

Kindly help me guys.

Regards

R

Former Member
0 Kudos

In order to send request to Weblogic Server and get a response, you have to access the weblogic server application component such as an EJB or POJO.

In order to access the weblogic server component, you have to get a remote method call using some kind of technology implementation. When you publish the weblogic application component as a web service you are getting the remote access to the component method using web service technology.

In NWDS what you have done with proxies are for the service interfaces you created inside XI or PI. It has nothing to do with EJB access from weblogic server.

However, If you like to access weblogic EJB using XI or PI, you have to associate the weblogic server component's WSDL definition with an inbound service in XI.

If you want to invoke the inbound service (Weblogic component web service) using an outbound service implemented via AVA proxies in NWDS you have to configure the outbound service as a JAVA proxy service, which is being called from the proxy source code you have imported into the NWDS.

Former Member
0 Kudos

Hi Shaji,

With your conversations I got very good awarness. Let me explain my way can you please give me solution: I need to call EJB(on legacy system) from XI get response back from Legacy system.

I believe i need to write application code in .templete file to rename with .Java in NWDS. This help of application code we can response details as xml string format. This string format I need to Parse it( am I right) if not please let me know mate.

Regards

R

Former Member
0 Kudos

In order to access an EJB from Weblogic Server using SAP XI you do not have to write JAVA code.

1. EJB is a J2EE application component with associated code implementation.

2. Inside EJB functionalities are implemented using EJB implementation class methods.

3. EJB provide access to the implementation class method using local and remote interface classes which expose implementation class methods through RMI protocol.

SO your EJB implementation in Weblogic has always a implementation available.

You can use application to application EJB component access using RMI protocol using JNDI look up only if both application is under same type of J2EE container.

In your case you have to access weblogic ejb using an EAI/ESB framework such as XI. EAI and ESB framework use web service technology to access the remote components. In order to support web service based access to J2EE components, J2EE container provide web service enablement approach for J2EE components.

So in order to access the weblogic EJB component from ESB framework such as XI use the following step.

1. Ask the weblogic application provider to publish the EJB as a web service.

2. BEA weblogic can publish any EJB or POJO implementation as web service with minimum effort.

3. Import the WSDL from the EJB web service into your XI repository.

4. Note that a WSDL file have all information necessary to access the underling component using web service technology that include (data types, message types, method name as ports, biding of method access with a protocol supported by web service technology, and service to identify the location of the service)

5. once you have the WSDL in XI create an inbound service using the datatype, inside the WSDL for the each method.

6. Make the new inbound service an synchronous in nature.

7. Associate the inbound service with an integration scenario.

8. During the configuration associate the inbound service with a SOAP adaptor receiver chanel pointing to the service location in weblogic host.

9. SOAP receiver chanel help XI to access the EJB functionalities from the weblogic server using the newly defined inbound interface.

Thanks

Former Member
0 Kudos

Hi Shaji,

I can what ever you sujjested, thanks for your help(Inbound). But i got an issue from outbound side Bapi comes from (Webdynpro) application. Can I wrap BAPI with Webservices? (But my scenario some one they designed with BAPI/RFC), if you have any clue about this please give me your valuable idea.

Scenario looks like this

Webdynpro (BAPI) --> XI --> call EJB from (weblogic server) (synchronously)

Thanks in Advance

Regards

Former Member
0 Kudos

Hi Roger Bass,

Refer the below links for JAVA Proxies:

https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/a068cf2f-0401-0010-2aa9-f5ae4b20...

https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/f272165e-0401-0010-b4a1-e7eb8903...

/people/prasad.ulagappan2/blog/2005/06/27/asynchronous-inbound-java-proxy

/people/rashmi.ramalingam2/blog/2005/06/25/an-illustration-of-java-server-proxy

Cheers

Veera

vikas_agarwal
Contributor
0 Kudos

Hi Roger,

Please go through this blog:

/people/rashmi.ramalingam2/blog/2005/06/25/an-illustration-of-java-server-proxy

Regards,

Vikas