• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Struts Framework vs JSP,Servlets,EJBs.

 
Ranch Hand
Posts: 104
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello all,
We have recently moved from Development phase to Maintenance phase.
Initially we did not have Struts framework at the web tier. We used the standard MVC architecture with JSPs (as Views), Servlets (as Controllers) and EJBs. (as Model).
We used Session Facade pattern where all the business logics were placed and from session ejbs Entity ejbs were invoked for inserting/updating records. (Oracle DB).
Now the client has come out with a new requirement of using Struts as the Web framework.
Could you please clarify the following.
1.Already we have a good MVC in place. By introducing Struts in between EJBs and the Client side JSPs, is it going to make any significant improvement?
2.In case if we proceed with Struts, do we have to remove all the business logic placed in Session EJBs and place it in Sruts action beans etc?
Any input from you'll will be really helpful.
Thanks,
Suresh Selvaraj
 
Ranch Hand
Posts: 238
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
We're developing with STRUTS and, from your description, it does the same thing you already do, except it's very frustrating having to remember what xml file controls which item. I'm not a fan of it, but I have to use it, so I do.
Good luck...
 
Ranch Hand
Posts: 567
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Suresh,
first of all I sympathise with you because I hate it when customers stipulate that you have to use something that they know little about.
However from your description of your architecture, are you sure that the MVC model is properly implemented?
The controller should seperate the model and the view. The main benefit is that you should be able to change your view completely without having to touch your model.
But you say that your EJBs call your JSPs directly? Maybe I misunderstand you. If your EJBs are your model, they shouldn't call your JSPs. Unfortunately I don't do EJB so I'm not quite sure what session facade, session EJBs and entity EJBs are.
I don't think you should implement struts if you don't need it, and I'll gladly help explain struts if that helps you - but you'll have to explain the EJB bit.
 
Ranch Hand
Posts: 2676
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The action classes in struts represent an extension of the controller, so they are not the best place for business logic. The action classes would call the appropriate EJB for business logic processing and then pass control back to the JSPs for presentation.
 
Ranch Hand
Posts: 2166
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
These "bean null in scope unknown not found"- or some such errormessages has frustrated me and are frustrating me. Strut's quite complex.
But I believe in standards. Especially when I find out things like this morning that in JSTL you use the same dotted notation to access say properties of objects of beans.
I have heard that the chief developer of struts is chief developer of Java Server Faces. Struts is so prominent, that they might to design a lot of openSource components/frameworks along the lines of struts.
Axel
 
reply
    Bookmark Topic Watch Topic
  • New Topic