-
Notifications
You must be signed in to change notification settings - Fork 215
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
migrate Blocking Buffer and StdInSource configurations off of plugin …
…setting (#5317) migrate Blocking Buffer configuration off of plugin setting Migrate StdInSource configuration off of pluginSetting Signed-off-by: Maxwell Brown <mxwelwbr@amazon.com>
- Loading branch information
1 parent
1a41705
commit 1309cda
Showing
11 changed files
with
200 additions
and
79 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
...n/java/org/opensearch/dataprepper/plugins/buffer/blockingbuffer/BlockingBufferConfig.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/* | ||
* Copyright OpenSearch Contributors | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
package org.opensearch.dataprepper.plugins.buffer.blockingbuffer; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
|
||
public class BlockingBufferConfig { | ||
public static final int DEFAULT_BUFFER_CAPACITY = 12_800; | ||
public static final int DEFAULT_BATCH_SIZE = 200; | ||
|
||
|
||
@JsonProperty("buffer_size") | ||
private int bufferSize = DEFAULT_BUFFER_CAPACITY; | ||
|
||
public int getBufferSize() { | ||
return bufferSize; | ||
} | ||
|
||
@JsonProperty("batch_size") | ||
private int batchSize = DEFAULT_BATCH_SIZE; | ||
|
||
public int getBatchSize() { | ||
return batchSize; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
...ins/common/src/main/java/org/opensearch/dataprepper/plugins/source/StdInSourceConfig.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/* | ||
* Copyright OpenSearch Contributors | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
package org.opensearch.dataprepper.plugins.source; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
|
||
public class StdInSourceConfig { | ||
private static final int WRITE_TIMEOUT = 5_000; | ||
|
||
@JsonProperty("write_timeout") | ||
private int writeTimeout = WRITE_TIMEOUT; | ||
|
||
public int getWriteTimeout() { | ||
return writeTimeout; | ||
} | ||
} |
Oops, something went wrong.