I am creating One POC for CRUD opeartions using Couchbase, but getting exception as
"An unhandled exception of type ‘System.Configuration.ConfigurationErrorsException’ occurred in System.Configuration.dll
Additional information: Unrecognized attribute ‘OperationLifeSpan’. Note that attribute names are case-sensitive."
while connecting to couchbase server. I am attaching C# code and config, Please let me know if I am doing anything wrong.
-------C# code-----------------------
public static void CreateOrder()
{
using (var cluster = new Cluster(“couchbaseClients/couchbase”))
{
IBucket bucket = null;
try
{
bucket = cluster.OpenBucket();
var order = new Document<Order>
{
Id = Guid.NewGuid().ToString(),
Content = new Order
{
Name="Tiffin",
Location="WITP",
Quantity=2
}
};
var result = bucket.Insert(order);
if(result.Success)
{
Console.WriteLine("Order Created '{0}'", order.Id);
}
}
finally
{
if (bucket != null)
{
cluster.CloseBucket(bucket);
}
}
}
}
---------------------Config----------------------------
<?xml version="1.0" encoding="utf-8" ?>