|
I'm defining a SearchMapping, which includes the following line:
.property("connectedGP", ElementType.FIELD).field().analyze(Analyze.NO).norms(Norms.NO).bridge(org.hibernate.search.bridge.builtin.impl.DefaultStringBridge.class)
Because DefaultStringBridge's constructor is private, I get the following exception during initialization:
I can't leave the bridge unspecified, because that causes an exception saying that Hibernate Search doesn't know how to map the field (which happens to be a JGroups UUID Address), and the SearchMapping API doesn't provide a way to give an instance of a bridge rather than the bridge's class.
I'm currently working around this by making a copy of the DefaultStringBridge class and commenting out the private constructor, so it ends up with the default public constructor which can be instantiated.
|