Browse files

The client tells you if it couldn't found the specified bucket.

  • Loading branch information...
1 parent 35966bf commit c366f584f4fe255db18296dead29d75a6e1ceb4b @enyim enyim committed Oct 20, 2010
Showing with 5 additions and 1 deletion.
  1. +5 −1 Membase/ConfigHelper.cs
View
6 Membase/ConfigHelper.cs
@@ -70,8 +70,12 @@ public ClusterConfig ResolveBucket(Uri poolUri, string name)
{
var root = this.GetBucketsRoot(poolUri);
var allBuckets = this.DeserializeUri<ClusterConfig[]>(root);
+ var retval = allBuckets.FirstOrDefault(b => b.name == name);
- return allBuckets.FirstOrDefault(b => b.name == name);
+ if (retval == null && log.IsWarnEnabled)
+ log.WarnFormat("Could not find the pool '{0}' at {1}", name, poolUri);
+
+ return retval;
}
public Uri[] GetBucketStreamingUris(Uri[] pools, string name)

0 comments on commit c366f58

Please sign in to comment.