<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Brian blogs on ObjectBuilder and EntLib</title><link>http://blogs.msdn.com/tomholl/archive/2006/01/09/511079.aspx</link><description>More than a few people have peeked behind the curtain of Enterprise Library for .NET 2.0 and have raised some excellent questions about ObjectBuilder and its role in Enterprise Library. Brian Button , our new fearless development leader has just written</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: Brian blogs on ObjectBuilder and EntLib</title><link>http://blogs.msdn.com/tomholl/archive/2006/01/09/511079.aspx#511297</link><pubDate>Tue, 10 Jan 2006 22:01:40 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:511297</guid><dc:creator>Alois Kraus</dc:creator><description>Hi Tom,&lt;br&gt;&lt;br&gt;just in case anybody is interested in following topics:&lt;br&gt;- Using System.Configuration classes with thelp of Entlib&lt;br&gt;- Instrumentation of Enterprise Library&lt;br&gt;- Configuration of Application Blocks &lt;br&gt;&lt;br&gt;then you can have a look at &lt;a rel="nofollow" target="_new" href="http://geekswithblogs.net/akraus1/"&gt;http://geekswithblogs.net/akraus1/&lt;/a&gt;&lt;br&gt;&lt;br&gt;Yours,&lt;br&gt;&lt;br&gt;  Alois Kraus&lt;br&gt;</description></item><item><title>re: Brian blogs on ObjectBuilder and EntLib</title><link>http://blogs.msdn.com/tomholl/archive/2006/01/09/511079.aspx#512952</link><pubDate>Sun, 15 Jan 2006 01:03:19 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:512952</guid><dc:creator>Ivan</dc:creator><description>Tom,&lt;br&gt;&lt;br&gt;I have a question regarding the Data Access block. How can I reuse a connection object across multiple reads using the Database object?&lt;br&gt;&lt;br&gt;I know I can create a transaction and pass it to the Database methods but as I am doing only selects I wand to create a connection open it, perform multiple selects and then close it. In EntLib 1 this was possible.&lt;br&gt;&lt;br&gt;Thank you&lt;br&gt;Ivan</description></item><item><title>re: Brian blogs on ObjectBuilder and EntLib</title><link>http://blogs.msdn.com/tomholl/archive/2006/01/09/511079.aspx#512953</link><pubDate>Sun, 15 Jan 2006 01:03:54 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:512953</guid><dc:creator>Ivan</dc:creator><description>Tom,&lt;br&gt;&lt;br&gt;I have a question regarding the Data Access block. How can I reuse a connection object across multiple reads using the Database object?&lt;br&gt;&lt;br&gt;I know I can create a transaction and pass it to the Database methods but as I am doing only selects I wand to create a connection open it, perform multiple selects and then close it. In EntLib 1 this was possible.&lt;br&gt;&lt;br&gt;Thank you&lt;br&gt;Ivan&lt;br&gt;</description></item><item><title>re: Brian blogs on ObjectBuilder and EntLib</title><link>http://blogs.msdn.com/tomholl/archive/2006/01/09/511079.aspx#512984</link><pubDate>Sun, 15 Jan 2006 03:52:51 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:512984</guid><dc:creator>tomholl</dc:creator><description>Hi Ivan -&lt;br&gt;&lt;br&gt;Although it may seem counterintuitive, in general it is best to open and close a connection with each use. This is because &amp;quot;closing&amp;quot; a connection doesn't really close it at all - it returns the open connection to the connection pool so it can be reused by a different thread. &lt;br&gt;&lt;br&gt;That said, if you're not doing anything else between queries, I can imagine it may be more efficient to keep the one connection open. I don't think there's an easy way of doing this with EntLib v2 - but I didn't think it was easy in v1 either. We did rename Database.GetConnection() to Database.CreateConnection() to more accurately reflect its behavior, but IIRC we didn't change what it did.&lt;br&gt;&lt;br&gt;Tom</description></item><item><title>re: Brian blogs on ObjectBuilder and EntLib</title><link>http://blogs.msdn.com/tomholl/archive/2006/01/09/511079.aspx#513071</link><pubDate>Sun, 15 Jan 2006 18:01:17 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:513071</guid><dc:creator>Ivan</dc:creator><description>Hi Tom,&lt;br&gt;&lt;br&gt;Thank you for your comment. EntLib v1 actually had methods where you could pass an open connection. &lt;br&gt;&lt;br&gt;I looked at the Database class and created only several overloads in order to be able to pass an open connection. Most of the functionality is actually there and handles the transaction parameter, which comes with an open connection. I could send you the code if you are interested. &lt;br&gt;&lt;br&gt;I find this feature useful as sometimes I have to perform several reads from the database with little application logic between them. Using the same open connection speeds the whole operation a lot.&lt;br&gt;&lt;br&gt;Regards&lt;br&gt;Ivan</description></item></channel></rss>