O'Reilly logo

Hibernate Search in Action by John Griffin, Emmanuel Bernard

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 4. Mapping more advanced data structures

This chapter covers
  • Custom bridges
  • Mapping relationships

Although Hibernate Search comes with built-in bridges for most useful Java types, they won’t cover all your needs. It’s not uncommon in an application to need to define specific types. Even if the type you’re wanting to index is supported, its string representation generated by Hibernate Search and indexed by Lucene might not be appropriate for the kind of full-text query you’re looking for. Generally speaking, what happens when you need to map the unexpected? Hibernate Search has the notion of a bridge, which converts the object structure into the Lucene structure. You can extend the supporting types and their behavior by writing your ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required