Win a copy of Five Lines of Code this week in the OO, Patterns, UML and Refactoring forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Incomplete Deployment

 
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am trying to run the example codes of Oreilly EJB 3.0 book. When I deploy my ejb3mockproject.jar in JBOSS, it gives this message.



Persistence.xml:



Can anyone please tell me what I need to do to solve this?
 
Sheriff
Posts: 10445
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

<jta-data-source>java: /DefaultDS</jta-data-source>



There's a space between java: and the /. Remove that space and start JBoss. This entry should look like:

 
Abhijith Prabhakar
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Jai, that solved the deployment issue.

But after been deployed also it was giving NotBoundException for TavelAgentRemote. It started working when I added

@org.jboss.annotation.ejb.RemoteBinding(jndiBinding = "TravelAgentRemote")

Any specific reason behind this? I am curious as Oreilly book doesn't state any such annotation to be added
 
Jaikiran Pai
Sheriff
Posts: 10445
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by Abhijith Prabhakar:
Any specific reason behind this? I am curious as Oreilly book doesn't state any such annotation to be added



By default, if you are deploying the bean in an ear file, then JBoss binds the beans to a jndi-name which is like "earName/BeanImplementationClassName/remote" (for local it is earName/BeanImplementationClassName/local). Ex: myApp/TestBean/remote. If you are deploying the bean in a jar file then the default jndi-name is BeanImplementationClassName/remote (and BeanImplementationClassName/local for local interface). Ex: TestBean/remote.

You can use these default jndi-names to do the lookup or else specify your own jndi-names for the beans. You followed the latter approach by using the @RemoteBinding annotation
 
    Bookmark Topic Watch Topic
  • New Topic