• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Use of @EJB name and mappedName

 
Ranch Hand
Posts: 149
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am using Glassfish server and have deployed a bean @Stateful(name="ThePlaceOrderBean", mappedName="ThePlaceOrderBean"). The deployment is Successful.

In the Client, I have the following


When the client is run, I get a Unresolved Ejb-Ref error. That is the client is not able to pick the Remote or reach a particular Bean.

Could you please help me on how to reach the "named" beans from the Client?

Where to look at the JNDI mapping in the Glassfish server, so that we could see the key/value of beans?

What is the use of name and mappedName in @EJB?

Thanks in advance,
Raj
 
Ranch Hand
Posts: 413
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Could you please help me on how to reach the "named" beans from the Client?



Seems your code is ok. post the whole code for more help

Where to look at the JNDI mapping in the Glassfish server, so that we could see the key/value of beans?



logto localhost:4848 and select the application server link in left. select jndi view on right.

also you can list the bounded jndi names using context.list method

What is the use of name and mappedName in @EJB?


name is bounded name. beanname is only valid within the application. mappedname is vendor specific. in general its not portable and dont use.



 
Rajesh So
Ranch Hand
Posts: 149
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Chaminda.

One other link on this topic was also useful.
http://forums.sun.com/thread.jspa?threadID=5332558&tstart=15
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic