Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8264843
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T04:36:02+00:00 2026-06-08T04:36:02+00:00

I have an EAR app with an ejb module inside and SomeService: some-ear.ear ->

  • 0

I have an EAR app with an ejb module inside and SomeService:

some-ear.ear -> some-ejb.jar -> SomeBean implements ISomeBean   

In Java EE specification I see that the JNDI name of this bean should be

java:comp/env/ISomeService    

when I deploy my app on WebLogic 10.3 then new InitialContext().lookup("java:comp/env/ISomeService"); works well

Now I deploy this app on JBoss 4.2.3 and I see the following in the log:

DEBUG [org.jboss.ejb3.stateless.BaseStatelessProxyFactory] Binding proxy for SomeBean in JNDI at some-ear/SomeBean/local    

OMG! JNDI name of my bean is some-ear/SomeBean/local and
new InitialContext().lookup("java:comp/env/ISomeService"); – not working
new InitialContext().lookup("some-ear/SomeBean/local"); – works well

Now I deploy my app on GlassFish 3.1 and I see the following in the log:

Portable JNDI names for EJB SomeBean : [java:global/some-ear/some-jar/SomeBean ...  

Again new JNDI name!

new InitialContext().lookup("java:global/some-ear/some-jar/SomeBean"); – works well

Can you explain to me why on different AS different JNDI names exist of the same bean and why this JNDI name is different with Java EE specification?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T04:36:04+00:00Added an answer on June 8, 2026 at 4:36 am

    The JavaEE naming chaos was a long time issue until JavaEE6 spec addressed it. Now we have standard namespaces for various components of Java EE AppServer. To be fair, you should compare Java EE 6 AppServers, like JBossAS7, Websphere 8, Glassfish 3.1.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Suppose I have a Maven multi-module Java EE 6 app: foobar/ foobar-ear/ src/ main/
I have next package structure webService.ear -- dependency.jar -- some.class Can I remove some.class
I have created a simple EAR the contains a EJB module and a Application
Let's say I have two ear file and one .jar file with an EJB
I have a EAR package that contains a web module and EJB. The EJB
I have an ear app with two EJB and one WEB (war) projects all
I have inherited an app which is packaged as ear file that has inside
I have an EAR that has a WAR inside, which has a jar inside
I have a J2EE app deployed as an EAR file, which in turn contains
Currently my setup is: in my ear META-INF/jboss-app.xml <jboss-app> <module> <service>datasource-ds.xml</service> </module> </jboss-app> and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.