cancel
Showing results for 
Search instead for 
Did you mean: 

Regarding : EJB and webdynpro.....

Former Member
0 Kudos

Hiii....

I am new for EJB and webdynpro. I have a webdynpro frontend, in that front end I m retriving data from my dictionary. Second I dont know how to create a EJB project for that webdynpro application.

I have created a ejb project but i dont know the concept of Beans. In which Bean I have to implement the coding part in session bean of EJB project or in command bean.

Also we need a EAR project in EJB , but I dont know how to create a EAR project ??

It is created from EJB project or we make it seperately.

What is the use of it and Which type of setting we have to do ??

My project has teo methods Save and cancel I dont know thw coding of it . and also pls tell me Hoe to reteive data from a Dictionary.

Pls give some step by step solution , I m very new for this.

Thanks in advance....

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

[Creating EJB Project|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/ca4a9c90-0201-0010-c389-8738cd51a88e]

[Using EJB in Webdynpro|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/1f5f3366-0401-0010-d6b0-e85a49e93a5c]

Regards,

Naga

Answers (5)

Answers (5)

Former Member
0 Kudos

Not answered

Former Member
0 Kudos

Hi,

if you are on 7.0, you can check out this tutorial: [NWDI tutorial|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/c0b53558-6df6-2910-cfbf-a63316bb0fad]

If you don't work with NWDI, just skip the NWDI relevant steps!

kind regards

Stefanie

Former Member
0 Kudos

Steps for creation of WebServices

Go to NWDS  open perspective j2ee

 select EJB Module Project create a project with name (calculator EJB)Finish

RC on ejb-jar.xml  Select new  EJB Give name to EJB Bean (First letter should be in capital letters)

 Select the type of bean as Stateless session bean

 Give the package name to store that EJB bean nextFinish.

After that Expand ejb-jar.xml and then select the CalculateEJB  double click on Method tab

 Click on business methods folder Add Create business method like a add as a method name with two parameters n1,n2

Double click on CalculateEJB RC on bean tab write required business logic in bean window as follows (based on requirement we will design business logic)

Go to project  rebuild

Till now we have created one EJB jar file then Go to FileEnterprise Application Project Create a project (CalculateEAR)

After creating a project next here we will have ear projects and then we select specific project required for our application.(here select CalculateEJB)

Here we are exposing Calculatebean as Web Service

Right click on Calculate Bean here select NewWeb Service give a name to web service and select Default configuration type as simple SOAP click on next  Select the methods which we want to expose to WebServiceNext Finish.

Created WebService and related are in ejb-jar.xml File .Expand the ejb-jar.xmlDouble click on calculate WebService

RC CalculateEJB  Build EJB Archive

RC on CalculateEAR Build Application Archive

Expand the CalculateEAR

RC on CalculateEAR.ear

Double click on calculateEAR.ear Webservice navigator tab Click on servers Expand the node select the specific WebService DC on WebService

Deploy to J2EE Engine

After that go to Web Dynpro perspective  create one WebDynpro Project Create Component CalculateComp

RC on model Select import Web Service model (last) give model name and package and select radio button as local file system or URL

Go to WSNavigatorcopy the WSDL path and paste it in model WSDL NextFinish

Afterthat same process as Adaptive RFC model

I hope it will helpful

Thanks,

Tulasi

Former Member
0 Kudos

hii,

For the first step,

1) you have to create table in the dictionary project

2)entity beans is used for accessing database tables i,e. dictionary tables in this case.

3)Refer the name of the table in persistent.xml

4)write your business method in session bean and refer the name of entitybean in JNDI name.

5)call the sessionbean method from the command bean and the commandbean method from the webdynpro perspective.

PradeepBondla
Active Contributor
0 Kudos

Hi,

go through the links in this thread

PradeeP