SlideShare uses cookies to improve functionality and performance, and to provide you with relevant advertising. If you continue browsing the site, you agree to the use of cookies on this website. See our User Agreement and Privacy Policy.
SlideShare uses cookies to improve functionality and performance, and to provide you with relevant advertising. If you continue browsing the site, you agree to the use of cookies on this website. See our Privacy Policy and User Agreement for details.
Successfully reported this slideshow.
Activate your 14 day free trial to unlock unlimited reading.
Dynamic and modular Web Applications with Equinox and Vaadin
This presentation introduces a little demo application that uses OSGi (Equixox) on the server. The demo uses Vaadin as UI technology and shows how you can create dynamicly changing UIs within a server-side OSGi Web application.
This presentation introduces a little demo application that uses OSGi (Equixox) on the server. The demo uses Vaadin as UI technology and shows how you can create dynamicly changing UIs within a server-side OSGi Web application.
14.
The Whiteboard Pattern
Problem: Often a service provides an
implementation of the publisher/subscriber
design pattern and provides methods to
register listeners for notifications
The OSGi service model provides a service
registry with these notification mechanisms
already!
So:
Don’t get a service and register as listener
Be a service yourself and register with the OSGi
service registry!
14
15.
Example: The Listener Pattern
Clients use ApplicationService to register view and
action contributions
Client is responsible for handling dynamic behavior
15
16.
Example: The Whiteboard Pattern
Clients register view and action contributions as services
Application manager is responsible for handling dynamic
behavior
16
17.
Whiteboard Pattern in Vaadin Demo
The Action and View contribution managers
are NOT services
Instead, they are wrapped in a OSGi Declarative
Services (DS) component
All action and view contributions are OSGi
services and implement
IActionContribution
IViewContribution
17