T
Tom Anderson
Arguably the keywords should actually be in a full text index in the
RDBMS, and let the proper full text indexing support handle it
instead. That will be more efficient than scanning a table of keywords
joined back to the table of documents
Maybe, maybe not:
http://www.pui.ch/phred/archives/2005/06/tagsystems-performance-tests.html
Depends on the data.
On the other hand, I've no idea if JPA supports full text indexes and if
it does how you'd go about using them...
JPA itself doesn't, AFAIK. However, you can take a JPA-mapped database,
add a fulltext index on the side, and then access it using native queries.
It's a leak in the abstraction, and a point of nonportability, but it's
easily confined to the data access layer, and probably not too big a deal
in practice.
There are also fulltext search options for JPA that don't use the
database's own indexing - notably Compass, which indexes a JPA repository
with Lucene:
http://www.compass-project.org/overview.html
Hibernate also has Hibernate Search, which does much the same thing. I
understand that its existence is pushing towards the next major version of
JPA including fulltext search. Whether there will be implementations on
top of database fulltext search as well as Lucene and similar, i don't
know.
tom