My New Amazon Kindle

A few months ago I started thinking about getting a Kindle from Amazon. I’m not a big reader, but I do enjoy reading certain types of books and I have a pretty large collection of computer/technology related books. I thought it would be nice to be able to have all of my tech books easily available at all times, especially when I travel.

Before I could make my decision, Barnes and Noble released the Nook, which is their competitor to the Kindle.  Obviously I had to consider that as a viable options.  I was able to walk into my local Barnes and Noble store and check out the Nook.  It’s a nice device with some nice features.  There are plenty of sites out there with product comparisons, so I’m not going to get into those details.  What I will do is tell you why I ultimately decided to buy an Amazon Kindle.

While Barnes and Noble boasts having many more books available for the Nook than Amazon has for the Kindle, there was one small problem with that.  The problem is that there are hardly ANY computer/programming/technology books available for the Nook!  The Amazon Kindle, however, has a pretty good selection available.  That was really the key that drove me to buy an Amazon Kindle.  Those types of books are $10-$15 cheaper as Kindle books vs. regular books and it won’t take longer before I’ve saved enough money to recoup the cost of the Kindle.  It will also be nice to be able to use the Search feature on the Kindle to search across all of my technology books.

I also just saw that Amazon is releasing an SDK so developers can create apps and games for the Kindle.  It’s clear that Amazon is looking to keep one step ahead of the competition, and I think they’ll be successful with.  I’ve very glad with my decision!

Categories: General
January 21, 2010 12:36 pm


IPhone rocks

Just a quick post. I have an iPhone, which I love. I recently downloaded a Wordpress app for it. I am using right now to write and post this entry. Being able to quickly and easily write a post means I no longer have any excuse for not creating more posts!

Categories: General — Tags:
January 6, 2010 7:04 pm


TransactionScopeOption and TransactionOptions

I ran into an interesting issue today.  I have a .NET code object that access the database to read from a custom audit table.  Since the audit table gets inserted into as part of every transaction I wanted to make sure the code that reads from the table doesn’t get blocked and doesn’t block the normal business transactions.  I decided to have the reads run with an isolation level of “Read Uncommitted”.  I realize there is a risk of reading a record that isn’t committed, but the way the processing works the insert into the audit table is the last thing that happens before a transaction commits.  So I figure it is extremely low risk.

I decided to simply wrap my data access calls with a TransactionScope like the following:

TransactionOptions transactionOptions = new TransactionOptions();
transactionOptions.IsolationLevel = IsolationLevel.ReadUncommitted;

using (TransactionScope ts = 
new TransactionScope(TransactionScopeOption.Suppress, 
transactionOptions, EnterpriseServicesInteropOption.None))
{
  // Code that retrieves data from the database
  ts.Complete();
}

 

When I went to test this out it didn’t work.  It ran, but if another process had a lock on the audit table I was still getting blocked.  After thinking about this a bit I realized what was happening.  Because I set the TransactionScopeOption to “Suppress” the TransactionOptions parameter was completely ignored. After all, there wasn’t a transaction, so no need to worry about options. 

To get things to work I had to change the TransactionScopeOption to “RequiresNew”.  It seems a bit odd to have to do that, but my other option would have been to modify the SQL to use “WITH (NOLOCK)” or pass the SQL to set the isolation level directly.  Since I want to support multiple DBMS’s I wanted to avoid doing anything funky with the SQL.

Categories: General
December 8, 2009 11:33 am


Newer Posts »






Copyright 2008 Flintvalley LLC, All rights reserved.