|
From: Lars F. <lar...@gm...> - 2003-08-22 10:17:17
|
Hi Jürgen, you're just too smart ... My previous mail explaining the error somehow got lost in cyberspace. Still don't know what I was struggling with. It just doesn't make any sense (that it doesn't work) and that's why I was so frustrated. Just started everything from scratch (and I mean everything - even wrote a new build.xml). Before I used the tutorial as starting point. The example behaves as expected, there's only one thing I'm wondering about: I've change the MySQL stuff to Postgres - no problem. At this point I do NOT provide the database table for the example object. The application starts up fine and does not tell me anything about a mapping problem. Is this the default behaviour ? Another question about WebWork (2). I know the difference about Spring and WebWork and that it's 'no problem' to combine the two frameworks. But does it make any sense ? Is WebWork MVC superior ? IMO it does make more sense to stay with Spring alone so you don't have to deal with two technologies. Thanks Lars > Hi Lars, > > I don't know what you're struggling with - m > apping a hbm file should be pretty simple. I even get a n > ice error message when specifying a wrong one. I guess yo > u're rather struggling with Hibernate than with Spring, b > ut I can't really judge as you didn't provide any details > . Did you manage to set up Hibernate *standalone*, for ex > ample? Does the web app with Spring start up standalone, > without your LocalSessionFactoryBean? > > I've attached a > simple setup of a Spring/Hibernate web app, just includi > ng a 1-listener web.xml, a 2-bean application context, 1 > hbm file, and one persistent class file. That should star > t up, Hibernate will just complain that it can't access M > ySQL at the specified port for extracting meta data - but > startup will proceed. You'll see in the log if the hbm g > ets loaded, you can also try to break it and see if Hiber > nate complains on restarting. > > Regarding WebWork: WebW > ork and especially WebWork2 are nice web frameworks, no d > oubt. But you definitely won't any particular middle tier > support, not in terms of transactions and not in terms o > f persistence. It might even make sense to use Spring as > middle tier framework in combination with WebWork for the > web tier, if you don't like Spring's own web MVC. There > are already people doing that, even more with Struts for > the web tier. > > There are numerous companies using a Sp > ring/Hibernate combo for various applications, including > the one that I'm with. Admittedly, my main experience is > with Tomcat and Resin, but WebLogic should work nicely to > o. Try it with a local DataSource first, as I've done in > the simple setup that I've attached. Provide me with deta > ils on errors that you encounter. All things considered: > Don't give up :-) > > Regards, > Juergen > > > > -----Ur > sprüngliche Nachricht----- > Von: Lars Fischer [mailto: > lar...@gm...] > Gesendet: Do 21.08.2003 15:04 > > An: spr...@li... > > Cc: > Betreff: [Springframework-developer] Giving up > > > > Finally I've wasted to much time trying to get S > pring work with Hibernate > without an example about conf > iguration. > > Never had so many problems using a frame > work despite the fact that this one > is better documente > d than most of the rest. Documentation is just too > abst > ract > at the moment to help with real world problems. I > just can't get Spring to > map my *.hbm.xml file defined > under 'mappingResources'. Even worse I don't > get any > > kind of useful error message. Maybe this is a BEA problem > with reading > configuration > inside of the war, maybe > not. > Maybe I'll continue if there's a working example w > ith Hibernate (all I would > need is > a COMPLETE configu > ration example). IMO the skeletons are not very useful. > > On the other hand I don't want to wait until October > so I'll take a look > at WebWork2. I could solve all my p > roblems with WebWork 1 myself without > documentation. > > > Thanks a lot for helping me in the past. > Lars > > > > > > ------------------------------------------------- > ------ > This SF.net email is sponsored by: VM Ware > Wit > h VMware you can run multiple operating systems on a sing > le machine. > WITHOUT REBOOTING! Mix Linux / Windows / No > vell virtual machines > at the same time. Free trial clic > k here:http://www.vmware.com/wl/offer/358/0 > ___________ > ____________________________________ > Springframework-de > veloper mailing list > Spr...@li... > urceforge.net > https://lists.sourceforge.net/lists/listi > nfo/springframework-developer > > |