For an example of using Hibernate with Struts (although it still needs improvements) you can checkout my struts-resume project. It's in SourceForge's CVS in the struts project at http://sf.net/projects/struts. Contributions welcome!
Browse the code here: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/struts/struts-resume/ Or download it here: http://raibledesigns.com/struts HTH, Matt > -----Original Message----- > From: Brandon Goodin [mailto:[EMAIL PROTECTED]] > Sent: Monday, January 20, 2003 7:01 AM > To: Struts Users Mailing List > Subject: RE: DAO and Struts Best Practice > > > That's great. I was using OJB here not too long ago. I felt > it was a great > product. But, it still has some maturing to do, especially in the > fine-grained caching department. (IMHO). I went back to > straight SQL for now > and started using the Sun DAO Abstract Factory Pattern on my > newest project. > I'll look into hibernate. I've heard some great things about > it. Thanks for > the advice. > > Brandon Goodin > Phase Web and Multimedia > P (406) 862-2245 > F (406) 862-0354 > [EMAIL PROTECTED] > http://www.phase.ws > > > -----Original Message----- > From: Raible, Matt [mailto:[EMAIL PROTECTED]] > Sent: Monday, January 20, 2003 6:03 AM > To: 'Struts Users Mailing List' > Subject: RE: DAO and Struts Best Practice > > > I'm using it and it seems to work pretty well. However, on > my last project, > I used such things like UserDAOMySQL, and it seems like it > would be a real > pain (right now) to write a bunch of new classes for Oracle > (UserDAOOracle). > This is mainly because of all the SQL inside my DAO, and it > would be much > cleaner to tweak everything so it worked on all RDBMs. > > What I've been doing lately is still using the DAO pattern, > but abstracting > based on a framework, rather than a Database. So now I use > concrete classes > like UserDAOHibernate and UserDAOCastor. These frameworks > allow me to talk > to a whole bunch of different databases without changing any code. > Hibernate is really slick, and I've actually been able to > change from MySQL > to Oracle just by changing some configuration parameters. > > HTH, > > Matt > > -----Original Message----- > From: Brandon Goodin [mailto:[EMAIL PROTECTED]] > Sent: Friday, January 17, 2003 5:30 PM > To: Struts Users Mailing List > Subject: RE: DAO and Struts Best Practice > > > I have read the official DAO pattern on the Sun's website. > WOW! Good stuff. > If you don't understand it that is a good place to start. Is > there anyone > using the strict DAO Abstract Factory Pattern? Yes? No? Why > or why not? > > http://java.sun.com/blueprints/corej2eepatterns/Patterns/DataA > ccessObject.ht > ml > http://java.sun.com/blueprints/patterns/DAO.html > > Brandon Goodin > Phase Web and Multimedia > P (406) 862-2245 > F (406) 862-0354 > [EMAIL PROTECTED] > http://www.phase.ws > > > -----Original Message----- > From: J Aaron Farr [mailto:[EMAIL PROTECTED]] > Sent: Friday, January 17, 2003 12:45 PM > To: [EMAIL PROTECTED] > Subject: RE: DAO and Struts Best Practice > > > Hello all. > > I've looked at a lot of DAO based projects and I haven't yet > found one that > I > really like. My problem is that often I end up having to > access similiar > data > from very different sources. For example, my current project > needs to be > able > to gather the same data via JDBC, JMS, or static XML files > (and down the > line, > probably SOAP). Most implementations of DAO (or other > datasource packages) > that I've seen are so SQL oriented that I find I cannot use them. > Additionally, the SQL that I do use is often very complex so > it's not as > simple > as just updating rows or columns. Perhaps the problem is > that I just don't > understand DAO or other packages like JDO or OBJ well enough. > > That said, I think I go along with option #2 (Instantiated > DAO with Method > parameters) more often than not. > > jaaron > > __________________________________________________ > Do you Yahoo!? > Yahoo! Mail Plus - Powerful. Affordable. Sign up now. > http://mailplus.yahoo.com > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > > > -- > To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>