0

When i think of Modular applications i think of mostly a component based architecture application (not necessary i know).

JSF is designed to do Component Web applications. Spring's Web Framework (Spring Web MVC) is a request/response model - mostly used to build a multi-layered architecture application so it is a different concept to what JSF is and what it is intended to do.

Can Spring Framework allow the workings of a componentized web application?

did some research and i found that Spring Dynamic Modules is based on OSGi framework but this Spring Project has been moved over to Eclipse Foundation. Is OSGi the way forward?

BalusC
  • 1,082,665
  • 372
  • 3,610
  • 3,555
SoftwareDeveloper
  • 1,094
  • 2
  • 15
  • 26
  • What is a "*componentized web application*"? – Tiny Sep 03 '15 at 15:23
  • web application consisting of web components on screen. Visual onscreen widgets would be components where they would be backed by bean objects. So there's data binding between the front end & the backend bean where that would have the business logic - unlike a request/response model where we would go and request the data and return data as response upon clicking a button let's say – SoftwareDeveloper Sep 03 '15 at 15:24
  • 1
    OSGi is a whole different can of worms. It is unclear what you want to do but if it's just source code separation then of course Spring can do it. If it's dynamic loading of modules at runtime then yes, OSGi would be required. – Boris the Spider Sep 03 '15 at 15:27
  • ASP.Net moved from Component-based to MVC based, FYI – Neil McGuigan Sep 03 '15 at 18:05

1 Answers1

1

Spring Framework is not a web framework per se. It's web tier is traditionally created using Spring MVC. It was originally was a subproject but is now included logically in the core libraries.

Spring MVC gives you a lot of freedom when selecting the view layer. Multiple template engines are supported out of the box with Thymeleaf, Velocity and FreeMarker mentioned in the documentation IIRC.

You can also throw Spring MVC out, and integrate Spring with a different web framework with compoment based views if you wish. Integration with JSF is mentioned in the reference documentation (briefly, though). Here's a webinar about integrating with Vaadin - another cool component based framework.

Apokralipsa
  • 2,674
  • 17
  • 28
  • i'm confused here.. by what you're saying MVC is different from Component based? I'm not sure if that's correct though. Please enlighten me if you can - because i have found many articles (and also a presentation) describing Request/Response MVC vs. Component based MVC.... So i always compare Request (or Action where some frameworks like to call it) against Component. – SoftwareDeveloper Sep 03 '15 at 20:57
  • maybe i'm wrong but i tend to think MVC as a 'pattern' whereas component & request/response as an 'Architecture' – SoftwareDeveloper Sep 03 '15 at 20:57
  • I have rephrased my answer. Sorry for not beeing clear - when I used MVC, I actually meant Spring MVC. And yes, MVC pattern (or some mutation) will pop up in most web frameworks. JSF also uses that pattern internally. – Apokralipsa Sep 03 '15 at 21:43