addressalign-toparrow-leftarrow-leftarrow-right-10x10arrow-rightbackbellblockcalendarcameraccwcheckchevron-downchevron-leftchevron-rightchevron-small-downchevron-small-leftchevron-small-rightchevron-small-upchevron-upcircle-with-checkcircle-with-crosscircle-with-pluscontroller-playcredit-cardcrossdots-three-verticaleditemptyheartexporteye-with-lineeyefacebookfolderfullheartglobe--smallglobegmailgooglegroupshelp-with-circleimageimagesinstagramFill 1languagelaunch-new-window--smalllight-bulblightning-boltlinklocation-pinlockm-swarmSearchmailmediummessagesminusmobilemoremuplabelShape 3 + Rectangle 1ShapeoutlookpersonJoin Group on CardStartprice-ribbonprintShapeShapeShapeShapeImported LayersImported LayersImported Layersshieldstar-shapestartickettrashtriangle-downtriangle-uptwitteruserwarningyahooyoutube

Re: [ljc] Please help with [Java] MVC framework adoption

From: Abdenour B.
Sent on: Monday, July 16, 2012, 10:40 AM
Hi Deepak,

From first glance, you're mixing java within jsp pages, which is a bad practice, and maintenance nightmare,

In the future if you want to migrate to different version, you won't be able to use tools which can do that.

Better practice is to create custom tags, to hide the logic.

To decide what framework you want to use, it depends on several factors, 

Size of the project, what environment is going to be deployed on, how much time you have.

I used struts before, I won't recommend that, if you start from scratch, 

I like spring MVC, it's easy to use, and offer good separation between MVC.

Hope that has helped.

Abdenour.

On Mon, Jul 16, 2012 at 10:29 AM, abdenour Bali <[address removed]> wrote:


---------- Forwarded message ----------
From: Deepak Nayal <[address removed]>
Date: Mon, Jul 16, 2012 at 10:23 AM
Subject: [ljc] Please help with [Java] MVC framework adoption
To: [address removed]


Hi All,

I am new to web development and have been working on my first web project using Java/JSP for some time now. For this project I decided to (probably, naively) not use any web framework and implemented a loose MVC type framework of my own in which some JSPs call the FrontController and other use the Java beans directly. After a few code iterations, my JSP code has turned into something like this https://gist.github.com/3118742

Can some expert please let me know - 
1) Is the level of Java/JSP/HTML code mixup (as shown in this GIST) normal or is it bad?
2a) If I use an MVC framework, such as Spring MVC or Grails or Apache Wicket, will that help me clean up this mess and separate the Java code from HTML pages?
2b) Probably the most controversial question - if the answer to the previous question is YES, then which is the best framework for a person such as me (who is a LOW to AVERAGE skilled developer) to use: Spring MVC/Grails/etc. or even client side MVC such as Backbone.js?

Thanks in advance for your help.

Cheers,
Deepak





--
Please Note: If you hit "REPLY", your message will be sent to everyone on this mailing list ([address removed])
This message was sent by Deepak Nayal ([address removed]) from LJC - London Java Community.
To learn more about Deepak Nayal, visit his/her member profile
Set my mailing list to email me As they are sent | In one daily email | Don't send me mailing list messages

Meetup, PO Box 4668 #37895 New York, New York[masked] | [address removed]


People in this
group are also in: