-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The specified type for the complex property is not a complex type. #24
Comments
Hi, if (complexType.ResourceTypeKind != ResourceTypeKind.ComplexType) It's hard to say what kind of data might cause this but perhaps you can debug it find out. |
Do you have a small database that you can share so I could try to reproduce the issue? |
Here's a mongodump of the database and collection I'm trying to get data from. |
Thanks, I will have a look at it. |
Any luck? |
Sorry, didn't have time to investigate yet (was busywith work and other open source project). Hope to check this out in the next few days. |
Hello again, |
When I connect to one of my Mongo databases, I get this error when trying to call the data service:
Here's the stack trace:
at DataServiceProvider.DSPMetadata.AddComplexProperty(ResourceType resourceType, String name, ResourceType complexType)
at Mongo.Context.MongoMetadataCache.AddComplexProperty(ResourceType resourceType, String propertyName, ResourceType propertyType)
at Mongo.Context.MongoMetadata.AddDocumentProperty(MongoContext context, String collectionName, ResourceType collectionType, String propertyName, BsonElement element, Boolean isCollection)
at Mongo.Context.MongoMetadata.AddResourceProperty(MongoContext context, String collectionName, ResourceType collectionType, BsonElement element, Boolean treatObjectIdAsKey)
at Mongo.Context.MongoMetadata.RegisterResourceProperty(MongoContext context, ResourceType resourceType, BsonElement element)
at Mongo.Context.MongoMetadata.RegisterDocumentProperty(MongoContext context, ResourceType resourceType, BsonElement element)
at Mongo.Context.MongoMetadata.UpdateResourceSet(MongoContext context, ResourceSet resourceSet, BsonDocument document)
at Mongo.Context.MongoMetadata.PopulateMetadataFromCollection(MongoContext context, String collectionName, ResourceSet resourceSet)
at Mongo.Context.MongoMetadata.PopulateMetadata(MongoContext context)
at Mongo.Context.MongoMetadata..ctor(String connectionString, Metadata metadata)
at Mongo.Context.MongoDataServiceBase
2.<.ctor>b__1(String x) at Mongo.Context.MongoDataServiceBase
2..ctor(String connectionString, MongoConfiguration mongoConfiguration)at Mongo.Context.Queryable.MongoQueryableDataService..ctor(String connectionString, MongoConfiguration mongoConfiguration)
at MongODataTest.MongoDataService..ctor() in c:\Projects\Sandbox\MongODataTest\MongODataTest\MongoDataService.cs:line 12
at CreateMongODataTest.MongoDataService()
at System.ServiceModel.Dispatcher.InstanceProvider.GetInstance(InstanceContext instanceContext, Message message)
at System.ServiceModel.Dispatcher.InstanceBehavior.GetInstance(InstanceContext instanceContext, Message request)
at System.ServiceModel.InstanceContext.GetServiceInstance(Message message)
at System.ServiceModel.Dispatcher.InstanceBehavior.EnsureServiceInstance(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage41(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage4(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage31(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage3(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage2(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage11(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage1(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)
I was able to connect to a different database, but the one I want the most throws this error.
Thoughts?
The text was updated successfully, but these errors were encountered: