Skip to content

Commit

Permalink
Remove unused imports
Browse files Browse the repository at this point in the history
Signed-off-by: Dinu John <[email protected]>
  • Loading branch information
dinujoh committed Sep 17, 2024
1 parent 317c4a6 commit ac93eff
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,7 @@
import org.opensearch.dataprepper.model.plugin.InvalidPluginConfigurationException;
import org.opensearch.dataprepper.model.processor.Processor;

import java.util.HashMap;
import java.util.Map;
import java.util.Objects;
import java.util.regex.Pattern;

/**
* This processor takes in a key and changes its value by replacing each occurrence of from substring to target substring.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
import java.util.List;
import java.util.Map;
import java.util.UUID;
import java.util.regex.PatternSyntaxException;

import static org.hamcrest.CoreMatchers.equalTo;
import static org.hamcrest.CoreMatchers.is;
Expand Down Expand Up @@ -176,17 +175,16 @@ public boolean equals(Object other) {

private ReplaceStringProcessorConfig.Entry createEntry(final String source, final String from, final String to, final String ReplaceWhen) {
final EventKey sourceKey = eventKeyFactory.createEventKey(source);
final ReplaceStringProcessorConfig.Entry entry = new ReplaceStringProcessorConfig.Entry(sourceKey, from, to, ReplaceWhen);

return entry;
return new ReplaceStringProcessorConfig.Entry(sourceKey, from, to, ReplaceWhen);
}

private ReplaceStringProcessor createObjectUnderTest() {
return new ReplaceStringProcessor(pluginMetrics, config, expressionEvaluator);
}

private Record<Event> getEvent(Object message) {
final Map<String, Object> testData = new HashMap();
final Map<String, Object> testData = new HashMap<>();
testData.put("message", message);
return buildRecordWithEvent(testData);
}
Expand Down

0 comments on commit ac93eff

Please sign in to comment.