Couchbase
  • Why NoSQL?
  • Couchbase Server
  • Download
  • Resources
  • Careers
Home | Forums | SDKs | SDKs

Couchbase .NET Client Library 1.1

4 replies [Last post]
  • Login or register to post comments
Wed, 05/02/2012 - 14:58
john
Offline
Joined: 01/05/2012
Groups: None

The Couchbase .NET Client Library 1.1 has been released!

New in this version is a complimentary API with methods that provide detailed information about an operation.

Where previously, you would call the Store method as follows:

var result = client.Store(StoreMode.Set, "foo", bar");
if (! result) {
   Console.WriteLine("Store failed");
}

You could now use the ExecuteStore method as follows:

var result = client.ExecuteStore(StoreMode.Set, "foo", bar");
if (! result.Success) {
   Console.WriteLine("Store failed with message {0}", result.Message);
}

In addition to the Store method, the Get, Cas, Append, Prepend, Increment, Decrement and Remove methods all have Execute variations that return an instance of an IOperationResult implementation.

var getResult = client.Get<Beer>("beer_american_pale_ale");
 
if (getResult.Success && getResult.HasValue) {
   var beer = getResult.Value;
   beer.Brewery = "Thomas Hooker Brewing Company";
 
   var casResult = client.Cas(StoreMode.Set, "beer_american_pale_ale", beer, getResult.Cas);
 
   if (! casResult.Success && casResult.Exception != null) {
      logger.Error(casResult.Message, casResult.Exception);
   }
}

Downloads - now with Enyim.Caching logging assemblies:

Nuget: http://nuget.org/packages/CouchbaseNetClient

Zip: http://packages.couchbase.com/clients/net/1.1/Couchbase-Net-Client-1.1.zip

Documentation:

Release notes: http://www.couchbase.com/docs/couchbase-sdk-net-1.1/couchbase-sdk-net-rn...

Logging: http://www.couchbase.com/docs/couchbase-sdk-net-1.1/couchbase-sdk-net-lo...

API Reference: http://www.couchbase.com/docs/couchbase-sdk-net-1.1/api-reference-summar...

New Method Summary: http://www.couchbase.com/docs/couchbase-sdk-net-1.1/api-overview.html#co...

Further Reading:

http://www.couchbase.com/develop/net/current (see Operation Results section)

If you have any questions, please post them.

-- John

Top
  • Login or register to post comments
Thu, 05/03/2012 - 11:08
jackneel
Offline
Joined: 05/03/2012
Groups: None

Hi John,

What happened to GetView() for views/queries?. This was available in previous version.

Thanks

Top
  • Login or register to post comments
Thu, 05/03/2012 - 11:34
john
Offline
Joined: 01/05/2012
Groups: None

GetView() is in the Developer Preview for the 1.2 Client Library. That's at http://www.couchbase.com/develop/net/next. Going forward, Nuget will likely have only official releases. The 1.1 functionality will get merged into 1.2 before it's released.

Top
  • Login or register to post comments
Thu, 05/03/2012 - 23:27
jackneel
Offline
Joined: 05/03/2012
Groups: None

Hi John,

Thanks for the info. When will the new version available?

Jackneel

Top
  • Login or register to post comments
Fri, 05/04/2012 - 06:25
john
Offline
Joined: 01/05/2012
Groups: None

The new version will be released along with the official release of Couchbase Server 2.0. The exact schedule for that is still being worked out though. I'll update the forums with an announcement the next time I release a developer preview...

Top
  • Login or register to post comments
  • Login or register to post comments
  • Login
  • Register

Company

  • About Us
  • Leadership
  • Customers
  • Partners
  • Contact Us

Product

  • Couchbase Server
  • Couchbase SDKs
  • Use Cases
  • Documentation
  • Forums

Open Source

  • Couchbase Project
  • Couchbase vs. CouchDB

Commercial

  • Subscriptions & Support
  • Training & Services

News

  • Blog
  • Newsletter
  • Press Releases
  • Buzz

Follow Us

    
  • Customer Login
  • Terms of Service
  • Privacy Policy
  • Trademark Policy
  • Site Map

© 2013 COUCHBASE All rights reserved.

Sign in to Couchbase Community

close
  • Create new account
  • Request new password
You are logging into the Forums, Wiki and Issue Tracker