• 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

Patterns in web applications?

 
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, I've been in Java for 2 years mostly developing web applications. I am new to design patterns, but I ve been reading a lot about it. Now, what I want to ask is what are the situations and problems in web apps where I can find patterns usefull?
Thanks,
Vlad
 
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Vladimir Ergovich:
Hi, I've been in Java for 2 years mostly developing web applications. I am new to design patterns, but I ve been reading a lot about it. Now, what I want to ask is what are the situations and problems in web apps where I can find patterns usefull?
Thanks,
Vlad


Patterns are simply reusable solutions to common, recurring problems. It's often easier to start looking directly at the problems you have and then branching out to more general, less technology-specific kinds of solutions. As other posts have suggested, you might want to start with the book "Core J2EE Patterns", which provide specific solutions that have worked in multiple J2EE projects. Then you might want to read the featured book, and/or the original "Design Patterns: Elements of Reusable Object Oriented Design" book, and start thinking about ways in which you can apply these general principles to your specific problems.
Design Patterns are general-purpose tools. You can't just ask someone "how do I use nails in building a house?" The answer would be too broad to be useful. Your question is similar. Take some time to learn about the patterns first, and then you'll start seeing the applicablity on your own.
Kyle Brown

------------------
Kyle Brown,
Author of Enterprise Java (tm) Programming with IBM Websphere
 
Ranch Hand
Posts: 149
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I would agree that this is a hard question to give a cut and dry answer to but I can suggest one example.
Consider login authentication. This is a situation where you could apply the Command Pattern. It is a process you will want to repeat frequently. You take incoming requests and forward them to a controlling servlet which will perform the authentication and create the command object. For a more detailed description of the implementation you could refer to O'Reilly's Servlet Programming book (I believe it is the one with the tea kettle on the cover) although they don't refer to it as the Command Pattern.Yoou can review the Command pattern at http://myweb.onramp.net/~huston/dp/patterns.html
 
Kyle Brown
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Another suggestion (that I can't believe I've forgotten to make so far) is that Patterns are by far best learned in groups. Get together with a couple of your buddies and do a reading group that meets once a week over lunch to discuss one pattern a week. You'll see that it's much easier to learn this in a group than it is alone. Another possiblility is to look at http://www.hillside.net and see if there isn't a patterns reading group already formed in your area that you can join.
Good luck!
------------------
Kyle Brown,
Author of Enterprise Java (tm) Programming with IBM Websphere
See my homepage at http://members.aol.com/kgb1001001 for other WebSphere information.
[This message has been edited by Kyle Brown (edited October 04, 2001).]
 
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Regarding design patterns - as they relate specifically to web applications - I have always found the IBM redbooks (anything about VAJ/WAS/EJB/XML) to be very useful (www.redbooks.ibm.com). Even if you don't use the IBM product range, there is a lot of good information included here (I work for IBM, but this is my objective opinion!).
The Apache Struts project also has some information on the basic motivation for MVC in web apps.
For more enterprise oriented patterns in a 'web' context - the SUN site has some J2EE patterns.
All of these sources discuss to a greater/lesser extent, the motivation and advantages of employing particular patterns.
regards,
paul.
 
tumbleweed
Posts: 5089
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Another suggestion (that I can't believe I've forgotten to make so far) is that Patterns are by far best learned in groups. Get together with a couple of your buddies and do a reading group that meets once a week over lunch to discuss one pattern a week.
Good idea Kyle
[This message has been edited by Johannes de Jong (edited October 05, 2001).]
 
Vladimir Ergovic
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks guys those links were helpfull!
 
Ranch Hand
Posts: 65
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Folks,
At some level, web application development is like other software development activities. However, as a particular application domain, there are some special issues, especially for user interface design.
You might check out: http://www.welie.com/patterns is a pretty good collection that addresses such issues.
David
------------------
David Kane
david_kane@houseofyin.com
Author of Software Architecture: Organizational Principles and Patterns
http://www.vraps.com
http://www.houseofyin.com
 
The only cure for that is hours of television radiation. And this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic