Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

about JSR 318 session 4.3.14

 
Himai Minh
Ranch Hand
Posts: 1399
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
On p.82 of JSR 318 , session 4.3.14 Serializing Session Bean Methods:
1."By default, clients are allowed to make concurrent calls to a stateful session object and the container is required to serialize such concurrent requests."
2."Note that the container never permits multi-threaded access to the actual stateful session bean instance"

Sentence 1 means a stateful session object can be access concurrently (or access by multiple threads) and the container can serialize the concurrent requests.
Sentence 2 means the container cannot permit mutlti-thread (concurrent) access the the stateful bean.

Are sentence 1 and 2 conflicting each other?
 
Himai Minh
Ranch Hand
Posts: 1399
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think I can answer my own question.
What the specification means is:
A client can create multiple threads of requests to access a stateful session bean. But the container only allows one thread to access the bean at a time.
 
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!