> |could a read only entity be treated as a stateful session bean in terms
of
> |cluster logic?
> |the only difference would be that you could have more than one client
> |hanging on (holding a reference) to it.
>
> It would become "pinned entities" in the sense that once you assign an
> entity to a node it stays there. There were some discussions made by
> Inprise chief alien recently that argued against this...
Pinned entity beans will give you distributed transactions so any gain you
get from pinning an entity is lost due to tx's going between nodes.
That's basically the problem.
But also realize that even if you don't pinan entity you can still get
read-only usage of beans that do not require db access on each client
access. You only need to access the db when you do writes. So, if you're in
a read-mostly scenario you can have extremely efficient cache (with the
scheme I outlined to you Marc).
> The price of "distributed synchronization seems to be deemed less than the
> price of "pinned" entities... gee I don't know...
Yes, that is correct. Distributed synch is very cheap in read-mostly (again
with the scheme I outlined to you Marc), and since pinned entities require
so much distributed tx's they're expensive.
/Rickard