|
From: Colin S. <col...@ex...> - 2004-03-30 16:00:04
|
I think we should make the proposed change, then people can use JdbcTemplate either way. As for the samples, at that point, I personally think they can be left the same; pre-instantiating the template is no longer a preferred solution. It may in fact be less desireable since people have to pass in both a DataSource and JdbcTemplate to beans that need it, instead of just a DataSource. tho...@tr... wrote: >I noticed this while preparing for my JDBC presentation. All our samples >preconfigure a DAO with a DataSource. Would it make sense to switch that to a >preconfigured JdbcTemplate if that is the preferred way to work, or should we >just make this proposed change and leave it at that? > >I made the change locally, but it broke a bunch of tests where the mock objects >expected some calls for the meta data. I'll try to clean that up and check >things in by tomorrow some time. > >Thomas > > >Quoting rod...@in...: > > > >>>Well one solution of course (as mentioned at the time I >>> >>> >>brought this up) >>was to just use a premade JdbcTemplate which comes from the >>context, >>since it is of threadsafe. >> >>That's what I've always done, so I've never been bothered by >>the lookups. >> >> >>------------------------------------------------------- >>This SF.Net email is sponsored by: IBM Linux Tutorials >>Free Linux tutorial presented by Daniel Robbins, President and CEO of >>GenToo technologies. Learn everything from fundamentals to system >>administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click >>_______________________________________________ >>Springframework-developer mailing list >>Spr...@li... >>https://lists.sourceforge.net/lists/listinfo/springframework-developer >> >> >> > > > > > >------------------------------------------------------- >This SF.Net email is sponsored by: IBM Linux Tutorials >Free Linux tutorial presented by Daniel Robbins, President and CEO of >GenToo technologies. Learn everything from fundamentals to system >administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click >_______________________________________________ >Springframework-developer mailing list >Spr...@li... >https://lists.sourceforge.net/lists/listinfo/springframework-developer > > |