Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ final class EnrichProcessorFactory implements Processor.Factory, Consumer<Cluste
public Processor create(Map<String, Processor.Factory> processorFactories, String tag, Map<String, Object> config) throws Exception {
String policyName = ConfigurationUtils.readStringProperty(TYPE, tag, config, "policy_name");
String policyAlias = EnrichPolicy.getBaseName(policyName);
if (metadata == null) {
throw new IllegalStateException("enrich processor factory has not yet been initialized with cluster state");
}
IndexAbstraction indexAbstraction = metadata.getIndicesLookup().get(policyAlias);
if (indexAbstraction == null) {
throw new IllegalArgumentException("no enrich index exists for policy with name [" + policyName + "]");
Expand Down