@Documented @Target(value={METHOD,FIELD}) @Retention(value=RUNTIME) @PropertyMapping(processor=@PropertyMappingAnnotationProcessorRef(type=org.hibernate.search.mapper.pojo.mapping.definition.annotation.processing.impl.IndexingDependencyProcessor.class)) public @interface IndexingDependency
This annotation is generally not needed, as the default behavior is to consider all properties that are actually used in the indexing process as dependencies that trigger reindexing when they are updated.
However, some tuning may be required for some properties:
reindexOnUpdate().
The index will be slightly out-of-sync whenever the property is modified,
but this can be solved by triggering reindexing manually, for example every night.
derivedFrom().
| Modifier and Type | Optional Element and Description |
|---|---|
ObjectPath[] |
derivedFrom |
ContainerExtraction |
extraction |
ReindexOnUpdate |
reindexOnUpdate |
public abstract ReindexOnUpdate reindexOnUpdate
public abstract ObjectPath[] derivedFrom
public abstract ContainerExtraction extraction
Map<TypeA, TypeB>:
defining the extraction as @ContainerExtraction(BuiltinContainerExtractors.MAP_KEY)
allows referencing map keys instead of map values.
By default, Hibernate Search will try to apply a set of extractors for common container types.ContainerExtractionCopyright © 2006-2019 Red Hat, Inc. and others. Licensed under the GNU Lesser General Public License (LGPL), version 2.1 or later.