@Override public Substitution newInstance() { return new MetadataSubstitution(this.conf.getKey(), this.conf.getIncludes(), this.conf.getExcludes(), this.conf.getFailDstNotFound()); } }
@Override protected void doSubstitution(InternalEvent ievent, DeserializedEvent devent, Map<String, Object> nested) { Map<String, Object> metadata = getMetadata(ievent); nested.put(this.key, metadata); }
@Override public boolean equals(Object o) { if (!super.equals(o)) { return false; } if (!(o instanceof MetadataSubstitutionConfig)) { return false; } MetadataSubstitutionConfig other = (MetadataSubstitutionConfig) o; if (this.includes.equals(other.getIncludes())) { return false; } if (this.excludes.equals(other.getExcludes())) { return false; } return true; }
@Override public Substitution newInstance() { return new MetadataSubstitution(this.conf.getKey(), this.conf.getIncludes(), this.conf.getExcludes(), this.conf.getFailDstNotFound()); } }
@Override public boolean equals(Object o) { if (!super.equals(o)) { return false; } if (!(o instanceof MetadataSubstitutionConfig)) { return false; } MetadataSubstitutionConfig other = (MetadataSubstitutionConfig) o; if (this.includes.equals(other.getIncludes())) { return false; } if (this.excludes.equals(other.getExcludes())) { return false; } return true; }
@Override protected void doSubstitution(InternalEvent ievent, DeserializedEvent devent, Map<String, Object> nested) { Map<String, Object> metadata = getMetadata(ievent); nested.put(this.key, metadata); }
@Override protected void doSubstitution(InternalEvent ievent, DeserializedEvent devent) { Map<String, Object> metadata = getMetadata(ievent); try { devent.setField(this.key, metadata); } catch (FieldNotFoundException e) { if (this.failDstNotFound) { throw new OperationException(e); } } }
@Override protected void doSubstitution(InternalEvent ievent, DeserializedEvent devent) { Map<String, Object> metadata = getMetadata(ievent); try { devent.setField(this.key, metadata); } catch (FieldNotFoundException e) { if (this.failDstNotFound) { throw new OperationException(e); } } }