以下代码在AppHarbor上运行良好。
public virtual void button1Clicked (object sender, EventArgs args)
{
button1.Text = "You clicked me";
MongoServer ms=MongoServer.Create("mongodb://sbose78:xxxxx@staff.mongohq.com:10068/BOSE");
MongoDatabase db= ms.GetDatabase("BOSE");
MongoCollection<User> users=db.GetCollection<User>("users");
button1.Text=users.Count().ToString();
}
但是,它在我的 Ubuntu 机器上遇到了异常。我正在使用 Monodevelop。
Server Error in '/' Application
recursionPolicy != NoRecursion not currently implemented
Description: HTTP 500. Error processing request.
Stack Trace:
System.NotImplementedException: recursionPolicy != NoRecursion not currently implemented
at System.Threading.ReaderWriterLockSlim..ctor (LockRecursionPolicy recursionPolicy) [0x00000] in <filename unknown>:0
at MongoDB.Bson.Serialization.BsonSerializer..cctor () [0x00000] in <filename unknown>:0
Version information: Mono Runtime Version: 2.6.7 (Debian 2.6.7-3ubuntu1); ASP.NET Version: 2.0.50727.1433
可能会发生什么?