javaweb-applicationsweb-application-design

How to develop a web application with a bunch of feature modules


I am developing a web application using spring framework and google app engine. I am wondering if there is a design pattern or framework with the help of which I can develop features of my application as pluggable modules. For example I have identified 4 features of the application:

  1. Oauth Login
  2. User Profile Management
  3. User Group creation
  4. User File management

Now what I need is to develop all these features as independent modules, so that i can detach any of them dynamically and they are as loosely coupled as possible. They can have their own database implementation, their own set of technologies etc. Is there a design principle to implement modules in such a way.


Solution

  • You can take a look at MQ systems (such as RabbitMQ, ActiveMQ). MQ system will work as intermediate layer, which provide you loosely coupling. Communication between modules will be implemented as posting messages to queue and listening for posting.

    Also, OSGI may help you. It gives you possibility to make your application as a set of pluggable modules, which might be loaded dynamically.