Bridging the Client-Server Solution Gap

[Java API] [Implemented Patterns] [J2EE Web Application] [Marrow-MUSCLE Application] [SF Project]

Intercepting Filter

Reference

Implemented only for the servlet based HttpFrontController. This may be refactored in the future to bring filtering support into the protocol abstract ApplicationController.

Context Object

Reference

Requests, Responses, and Sessions are all converted and maintained as Context Objects. Contexts are maintained through delegation to protocol contexts wherever possible to eliminate the duplication of in-memory data.

Front Controller

Reference

Marrow comes with concrete implementations in the form of HttpFrontController, and MuscleFrontController. These two Front Controllers handle request transformation, response transformation, and view dispatch for their respective protocols. Additional FrontControllers can be implemented, and easily plugged in or added to Marrow by extending the AbstractFrontController.

Application Controller

Reference

Through the use of an ApplicationController in conjunction with the Context pattern, we acheive total protocol abstraction without a major performance impact. Our ApplicationController implements a few basic design considerations: Among them are a SynchronizerToken, and full server-side validation framework.

Business Delegate

Reference

Aside from being able to implement Commands directly as Business Delegates, Marrow supplies an AbstractBusinessDelegate that carries an InvokerCache. Frequently invoked long-running tasks can be wrapped by the AbstractBusinessDelegate and InvokerCache. Subsequent invocations with matching parameters will return cached results. Commands which alter the state of the cached result can easily flush the InvokerCache to eliminate concurrency problems.

Service Locator (Requries J2EE)

Reference

Implemented to centralize and ease the lookup resources from JNDI trees, the current ServiceLocator in CVS implements methods for retrival of EJBHome and EJBLocalHome objects. These methods make compilation dependent on available J2EE libraries. A compile-time ant property, omit.j2ee will allow individuals without a full J2EE library to build applications that don't make use of the ServiceLocator.

Dispatcher View (JSP Views)

Reference

Marrow promotes the use of JSPs as views when operating in a Servlet Container. In doing so, we utilize the Dispatcher built into the Servlet Container. When we're not running in a Servlet Container, we expect the client application to know what to do with the responses it gets. The HTTPBridge for Marrow-MUSCLE turns all response objects into XML documents, easily parsable by any AJAX toolkit.

Application Service

Reference

The use of abstract FrontControllers, Context Objects, and allowing multiple clients across multiple protocols to access the same ApplicationController is how we implement Application Service. Indeed, we probably go a bit above and beyond the normal ideal of how this gets implemented.


SourceForge.net Logo