Win a copy of Mastering Corda: Blockchain for Java Developers this week in the Cloud/Virtualization 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
  • Paul Clapham
  • Ron McLeod
  • Bear Bibeault
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Tim Cooke
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Jj Roberts
  • Carey Brown
  • salvin francis
  • Frits Walraven
  • Piet Souris

Spec question

Ranch Hand
Posts: 271
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Section 6.3 , the last sentence just before the start of 6.3.1 says:

� Obtain a handle for the remote home interface. The home handle can be serialized and written
to stable storage. Later, possibly in a different JVM, the handle can be deserialized from stable
storage and used to obtain back a reference of the remote home interface.

Why would one want to do this , given that session beans are indentical?Why would one serialize the handle and reuse it , if you gonna get a bean similar to what you had initially(i.e before serialization)?Or is this statement to make a point that "it can be done" , even though it doesn't make sense?Or i'm just not thinking hard enuff

jeff mutonho
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the spec discusses Statefull Session beans as being the most common or intended type of session bean. in reality that may or may not be the case, but regardless, this handle allows you to get a reference to the component interface without going through jndi, get reference to home, create bean.

these handles aren't used much from my experience, but the test probably doesn't include only popular features.
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's the Home that's get serielized, not bean itself.
Here is one way I want to use it:
You can send this home handle through MDB as a message, on client side, you can get the Home without going through JNDI call. That's a big performance increase.
    Bookmark Topic Watch Topic
  • New Topic