Summary


Successful Web applications are built on technologies whose failure modes are well understood. Nothing beats simplicity of design and unquestioned support for scalability when a Web site must run 24 7. When introducing JDO into this deployment environment, the one-pm-per-request design offers many advantages. It leverages the sophistication of the JDO implementation when it comes to the caching of persistent state and connections. Whatever scheme is adopted to support conversational state, support for clustering and session spooling is not compromised. Debugging this design appears to be straightforward. In essence, this design uses JDO to simplify the access to persistent state without introducing any complexities, limitations, or potential flaws. The only limitation of this design that is not addressed by JDO or opened to being addressed by the JDO implementation is support for an optimistic concurrency control that spans client requests. The application can address this deficiency for the simple cases with a minimal amount of application code that supports an application-defined versioning scheme.

On the other hand, the one-pm-per-update design, if used with a JDO implementation that supports cache synchronization across persistence managers, promises somewhat better performance. To realize the better performance, the application needs to avoid making persistent objects transient—an act that would create the garbage that the design otherwise avoids.

The next chapter examines the use of JDO in Enterprise JavaBeans. It examines a stateless session bean that implements yet another variation on the reservation services that have been presented so far. Since EJBs are not themselves applications, a variation of the rental Web application described in this chapter rounds out the complete application presented in the next chapter.




Using and Understanding Java Data Objects
Using and Understanding Java Data Objects
ISBN: 1590590430
EAN: 2147483647
Year: 2005
Pages: 156
Authors: David Ezzio

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net