Skip to content

Commit

Permalink
MAINT: revert the change
Browse files Browse the repository at this point in the history
Signed-off-by: George Chen <[email protected]>
  • Loading branch information
chenqi0805 committed Oct 18, 2024
1 parent 7ac0d67 commit 64585c6
Showing 1 changed file with 1 addition and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
import com.fasterxml.jackson.annotation.JsonValue;
import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import org.opensearch.dataprepper.model.annotations.AlsoRequired;

import java.util.Arrays;
import java.util.List;
Expand All @@ -24,8 +23,6 @@
@JsonClassDescription("The <code>list_to_map</code> processor converts a list of objects from an event, " +
"where each object contains a <code>key</code> field, into a map of target keys.")
public class ListToMapProcessorConfig {
static final String KEY_KEY = "key";

public enum FlattenedElement {
FIRST("first"),
LAST("last");
Expand Down Expand Up @@ -67,12 +64,9 @@ public String getOptionValue() {
@JsonProperty("use_source_key")
@JsonPropertyDescription("When <code>true</code>, keys in the generated map will use original keys from the source. " +
"Default is <code>false</code>.")
@AlsoRequired(values = {
@AlsoRequired.Required(name = KEY_KEY)
})
private boolean useSourceKey = false;

@JsonProperty(KEY_KEY)
@JsonProperty("key")
@JsonPropertyDescription("The key of the fields to be extracted as keys in the generated mappings. Must be " +
"specified if <code>use_source_key</code> is <code>false</code>.")
private String key;
Expand Down

0 comments on commit 64585c6

Please sign in to comment.