Wednesday August 18, 2004
Should I ditch Tiles in AppFuse?
I've haven't been developing applications with AppFuse since May. Instead, I've been using Equinox. One of the main things in Equinox I've grown to love is SiteMesh. It's worked in all the webapps I've written, which utilize frameworks like Struts, Spring MVC, WebWork, Tapestry and JSF. Tiles will only work in 3 of those.
I think it's time to make an executive decision on AppFuse and ditch Tiles in place of SiteMesh. It's faster and easier to develop with, and it doesn't get in your way. In fact, I didn't have to change a single line of SiteMesh-related code to support any of the aforementioned frameworks. Furthermore, using SiteMesh would also greatly reduce the duplicate between frameworks. I've thought about keeping Tiles around, but it's a pain in the ass to maintain parallel sets of documentation.
Whaddya think - any reason you can think of to keep Tiles? I can't. In fact, I think I'd cringe if I had to start my next AppFuse-based project w/o SiteMesh.
Posted in Java
at Aug 18 2004, 10:11:56 AM MDT
33 Comments
Search This Site
Recent Entries
- Jack's Mohawk
- LinkedIn Cuts 10% (a.k.a. The Journey is Over)
- Happy Birthday Abbie!
- Moving from Spring's XML to Annotations in AppFuse
- Free Maven Training in New Orleans on Election Day
- AppFuse Light ยป AppFuse, Maven Archetypes and Shared Web Assets
- Great Weekend in Montana
- Colorado Software Summit 2008 Wrapup
- RESTful Web Applications with Subbu Allamaraju
- Core Animation with Bill Dudney
Posted by Greg Jones on August 18, 2004 at 10:41 AM MDT #
Posted by Van Riper on August 18, 2004 at 10:44 AM MDT #
Posted by Mark Janveaux on August 18, 2004 at 10:53 AM MDT #
Posted by Gilberto C. Andrade on August 18, 2004 at 11:00 AM MDT #
Posted by Joe Walnes on August 18, 2004 at 11:01 AM MDT #
Posted by Mike T on August 18, 2004 at 11:16 AM MDT #
Posted by Mathias Bogaert on August 18, 2004 at 11:30 AM MDT #
Posted by Jason Carreira on August 18, 2004 at 11:45 AM MDT #
Posted by jack hart on August 18, 2004 at 12:12 PM MDT #
Posted by Matt Raible on August 18, 2004 at 12:24 PM MDT #
Posted by Dan Allen on August 18, 2004 at 12:42 PM MDT #
Posted by Lars Fischer on August 18, 2004 at 12:44 PM MDT #
Posted by Joe Walnes on August 18, 2004 at 01:47 PM MDT #
Posted by Andre Mermegas on August 18, 2004 at 02:13 PM MDT #
Posted by Matt Raible on August 18, 2004 at 02:23 PM MDT #
Posted by gerryg on August 18, 2004 at 03:29 PM MDT #
Posted by Carlos Sanchez on August 18, 2004 at 04:03 PM MDT #
Posted by grego on August 18, 2004 at 04:58 PM MDT #
> I've just used a tiles controller to make a pda friendly website, changing tiles
> attributes (e.g. css files) based on user browser. Can this be done with SiteMesh?
Carlos, yes. SiteMesh comes bundled with something called the AgentDecoratorMapper which allows you to select a decorator based on the User-Agent HTTP header. Once configured, all you have to do is complement your mydecorator.jsp with mydecorator-ie.jsp, mydecorator-lynx.jsp, mydecorator-pda.jsp, etc and SiteMesh will automatically choose the best fit.
Posted by Joe Walnes on August 18, 2004 at 09:53 PM MDT #
Posted by Pål Brattberg on August 19, 2004 at 02:21 AM MDT #
>> Can you be more specific? SiteMesh has been designed to be a non-intrusive framework so you can use
>> whatever technologies you want to get the job done without constraining you to an API. If you can do it
>> without SiteMesh, then there's no reason why it would get in your way.
For examples, check: <ul class="glassList">
Posted by Ville on August 19, 2004 at 02:52 AM MDT #
Posted by Joe Walnes on August 19, 2004 at 04:14 AM MDT #
Joe, you might want to override default behaviour of TilesRequestProcessor if you're going to implement your own security mechnanism.
When a request comes in, it gets passed to this request processor, there you can check if user is already authenticated, and then check if he has rights to invoke requested action. From there you can redirect to either login action or to forbidden action or continue normal flow.I found this solution quite handy and elegant, especially compared to not-standardized realms in tomcat.
Needless to say, that all your jsps should go beneath WEB-INF, so only actions will be exposed.
Posted by Vadim on August 19, 2004 at 05:50 AM MDT #
Posted by Ben C on August 19, 2004 at 09:02 AM MDT #
Posted by Vadim on August 19, 2004 at 10:00 AM MDT #
Posted by bolivariano on August 19, 2004 at 04:59 PM MDT #
Posted by Matt Raible on August 19, 2004 at 05:07 PM MDT #
Posted by Matt Raible on August 19, 2004 at 05:17 PM MDT #
If there is need to override default behaviour of SiteMesh what would you do? Make another filter?
Posted by Ville on August 20, 2004 at 12:18 AM MDT #
Using a layout library such as Tiles to do authentication seems like a good solution to you?
Also, you said all the right words: ...which is almost static code and can be copy/pasted from a project to a project without any hassle... ... Mmm, the golden principle of code re-use: copy-paste!
Posted by Santa Claus on August 20, 2004 at 01:16 AM MDT #
Posted by Johann Reyes on August 20, 2004 at 05:35 AM MDT #
Posted by Vadim on August 20, 2004 at 05:43 AM MDT #
Posted by 66.27.52.214 on August 20, 2004 at 06:22 PM MDT #