ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Clinton Begin <clinton.be...@gmail.com>
Subject Re: SqlMapClientBuilder or SqlSessionFactoryBuilder
Date Thu, 03 Sep 2009 14:37:32 GMT
Sorry, pushed send too fast... to the second part of your question:

>> What's the difference between SqlMapClient or SqlSessionFactory?

The primary difference is that SqlSessionFactory does not contain the
"ThreadLocal" convenience methods that SqlMapClient did.

If you look at SqlMapClient, there's an .openSession() method.  That
approach is the one I focused on when building iBATIS 3, as I wasn't sure
that the ThreadLocal based methods were a good development pattern or not...

So far, I think we'd all agree in theory that using the session objects is
cleaner and better....

But a lot of people miss the simplicity of the ThreadLocal methods.

I'm undecided as to what to do about that, if anything at all.


On Thu, Sep 3, 2009 at 8:34 AM, Clinton Begin <clinton.begin@gmail.com>wrote:

> There are no Javadocs for iB3 yet.  There's a full user guide though...
> On Thu, Sep 3, 2009 at 8:18 AM, liny <innocentliny@gmail.com> wrote:
>> Hi,
>> I'd like to ask why I can't find SqlSessionFactoryBuilder in oneline java
>> doc of iBatis web site?
>> I downloaded iBatis3 user guide, and this guide told me to use
>> SqlSessionFactory.
>> What's the difference between SqlMapClient or SqlSessionFactory?
>> --
>> View this message in context:
>> http://www.nabble.com/SqlMapClientBuilder-or-SqlSessionFactoryBuilder-tp25277076p25277076.html
>> Sent from the iBATIS - User - Java mailing list archive at Nabble.com.
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-java-unsubscribe@ibatis.apache.org
>> For additional commands, e-mail: user-java-help@ibatis.apache.org

View raw message