This week's book giveaway is in the NodeJS forum.
We're giving away four copies of Serverless Applications with Node.js and have Slobodan Stojanovic & Aleksandar Simovic on-line!
See this thread for details.
Win a copy of Serverless Applications with Node.js this week in the NodeJS 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 ...
  • Campbell Ritchie
  • Liutauras Vilda
  • Bear Bibeault
  • Jeanne Boyarsky
  • paul wheaton
  • Junilu Lacar
  • Paul Clapham
  • Knute Snortum
Saloon Keepers:
  • Stephan van Hulst
  • Ron McLeod
  • Tim Moores
  • salvin francis
  • Carey Brown
  • Tim Holloway
  • Frits Walraven
  • Vijitha Kumara

Bug in Pet Store 1.0.1  RSS feed

Ranch Hand
Posts: 350
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am going through Pet Store 1.0.1 as a part of my Assignment, I think I have found a coding (desing) error. Could some one confirm this.
The EJB 1.1 specification (� 6.5.6) specifically disallows multiple simultaneous accesses to the same stateful session bean.
The EJB container throws a RemoteException if a client accesses a stateful session bean that is already serving a request from another client.
This problem has been taken care of in the case of ShoppingClientControllerWebImpl class (this class is in the web tier and it acts as a proxy to the session bean in the EJB Tier)in this class the method calls are synchronized.
But in the case of the other Session Bean Class ( and the corresponding Proxy Classes in the Web Tire )
ShoppingCartEJB (session bean ) and ShoppingCartWebImpl ( web tier proxy class )
Whenever a method is accsed in ShoppingCartWebImpl the methods are not synchronized, hence we will get a RemoteException as stated in the EJB Specification. The method 'getDetails' on ShoppingCartEJB is called from the method 'performUpdate' in ShoppingCartWebImpl
this method is called when the all the models are updated in
public void processRequest(HttpServletRequest req) {

Vivek V
Ranch Hand
Posts: 139
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am going to look at the petstore too. Can you tell how you start to go through it? what server do you use to run it? thx
Vivek Viswanathan
Ranch Hand
Posts: 350
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have installed pet store 1.1.2 on j2ee reference implentation 1.3.1. You should get this at
I am going through the source code using JBuilder 6. This is a very good tool for understading existing code since it provides nice features like UML diagrams, searching for variable reference.

We've gotta get close enough to that helmet to pull the choke on it's engine and flood his mind! Or, we could just read this tiny ad:
global solutions you can do at home or in your backyard
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!