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

extra data found in OneToMany collection #772

Closed
oswaldl opened this issue Aug 11, 2015 · 7 comments
Closed

extra data found in OneToMany collection #772

oswaldl opened this issue Aug 11, 2015 · 7 comments
Assignees

Comments

@oswaldl
Copy link

oswaldl commented Aug 11, 2015

still using hbase jpa client, this is my entity definition:

@Entity
@Table(name="Oswaldl")
public class Man {
    @Id
    @GeneratedValue(strategy = GenerationType.TABLE)
    private String id;

    @Column(name = "name")
    private String name;

    @OneToMany(cascade=CascadeType.REMOVE)
    @OrderBy("id ASC")
    private Set<Man> boys = new HashSet<Man>();  
}

test code:

        Man m1 = new Man();
        m1.setId("id1");
        m1.setName("attr1");

        // add one boy here
        Man subm2 = new Man();
        subm2.setId("id2");
        subm2.setName("attr2");
        subm2.getBoys().add(subm2);

after save 'm1' and refetch it, i got two boys in m1 instead of one(the extra one is m1 itself)!

@devender-yadav
Copy link
Contributor

Are you using kundera-hbase or kundera-hbase-v2 ?

@oswaldl
Copy link
Author

oswaldl commented Aug 11, 2015

com.impetus.kundera.client:kundera-hbase-v2:2.17

@devender-yadav
Copy link
Contributor

We are marking it as a bug. We will add a fix soon.

@devender-yadav devender-yadav self-assigned this Aug 12, 2015
devender-yadav pushed a commit that referenced this issue Aug 12, 2015
@devender-yadav
Copy link
Contributor

Thanks for raising the issue. Fix has been added in the trunk. Please build it and let us know.

@devender-yadav
Copy link
Contributor

Find this testcase for more details.

@oswaldl
Copy link
Author

oswaldl commented Aug 13, 2015

ok, thanks

@oswaldl
Copy link
Author

oswaldl commented Aug 13, 2015

closed

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

2 participants