• 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
  • Paul Clapham
  • Ron McLeod
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Rob Spoor
  • Devaka Cooray
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
  • Tim Holloway
Bartenders:
  • Jj Roberts
  • Al Hobbs
  • Piet Souris

NoSuchEJBException vs NoSuchObjectException

 
Bartender
Posts: 2124
13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In JSR 318, it says two things:
1. "If a stateful session bean has been removed, attempted invocation on the no-interface view reference mus result in a javax.ejb.NoSuchEJBException.
2. "Attempted remote invocation on a stateful session object that does not exist result in a java.rmi.NoSuchObjectException."

If the stateful session bean is removed/does not exist, two different exceptions can be thrown when the method of the bean is attempted to be invoked.

Are these two statements contradicting with each other?

 
Creator of Enthuware JWS+ V6
Posts: 3398
312
Android Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Don't get confused, the EJB 3.1 specification mentions EJB 2.x behaviour for backwards compatibility.

The javax.ejb.NoSuchEJBException is the exception for EJB 3.1 (and the only one you should learn).
 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic