So, yes, you can add this to Poll
Code:
@OneToOne(optional=false,fetch=FetchType.LAZY,mappedBy="poll")
@ContainedIn
public Post getPost(){
return post;
}
But as far as I'm concerned, Hibernate Search now forced me to tightly couple something that I don't want to tightly couple. But ok, it now works.
However, when I modify a
Poll object, I see
all of the other (some Lazy, some Extra Lazy because they never
ever should be loaded as a whole)
unchanged children of
Post being loaded by Hibernate, presumably to recreate the entire index record, when only a single field changed. That's a performance killer and it puzzles me each and every time I see something like that happen (I got rid of classbridges alltogether for this very reason).
Any ideas (using Hsearch 4.1.1)?
Cheers,
Marc