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

Can handle one to many & many to one relations in docstore only entities #1158

Merged
merged 1 commit into from
Oct 5, 2017

Conversation

rPraml
Copy link
Contributor

@rPraml rPraml commented Oct 5, 2017

Hello Rob,

We use the ebean-json stuff in conjunction with docstore-only entitites to convert complex object graphs to JSON (and we refer to real entities, that will then lazy load)

Here we had the problem that @onetomany relations did not work, as ebean thinks it requires a mappedBy field on the many-side. This is not true for docstore-only entities.

I added some unit-tests to provide a simple use case.

cheers
Roland

@rbygrave
Copy link
Member

rbygrave commented Oct 5, 2017

Nice catch - I like it.

@rbygrave rbygrave added the bug label Oct 5, 2017
@rbygrave rbygrave added this to the 11.2.2 milestone Oct 5, 2017
@rbygrave rbygrave merged commit bbe8abc into ebean-orm:master Oct 5, 2017
@rPraml rPraml deleted the fix-relations-docstore-only branch March 1, 2018 23:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants