Skip to content
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

Kundera ClassCastException with MongoDB #808

Closed
oscarduque018 opened this issue Nov 23, 2015 · 4 comments
Closed

Kundera ClassCastException with MongoDB #808

oscarduque018 opened this issue Nov 23, 2015 · 4 comments
Assignees

Comments

@oscarduque018
Copy link

I'm using Kundera to do the persistence in MongoDB. I can persist some documents in my collection, but everytime that I try to find a specific document by id, I get this error

java.lang.ClassCastException: java.lang.String cannot be cast to com.mongodb.BasicDBList com.impetus.kundera.persistence.AbstractEntityReader.findById(AbstractEntityReader.java:95) com.impetus.client.mongodb.MongoEntityReader.findById(MongoEntityReader.java:72) com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:com.impetus.kundera.graph.Node.find(Node.java:500) com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:225) com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:174) com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:263)

@devender-yadav
Copy link
Contributor

@cosmicgarden

Can you please share your Entity Class & query used to find the document by id ?

-Dev

@devender-yadav devender-yadav self-assigned this Nov 24, 2015
@devender-yadav
Copy link
Contributor

@cosmicgarden

I answered your question at : http://stackoverflow.com/questions/33879771/kundera-classcastexception-with-mongodb

@devender-yadav
Copy link
Contributor

@cosmicgarden
Are we good to close this?

@chhavigangwal chhavigangwal added this to the 3.3 milestone Dec 1, 2015
@chhavigangwal chhavigangwal removed this from the 3.3 milestone Jan 16, 2016
@chhavigangwal
Copy link
Collaborator

Closing it with Kundera-3.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants