use of com.amazon.dataprepper.model.configuration.PluginSetting in project data-prepper by opensearch-project.
the class PeerForwarderTest method generatePeerForwarder.
private PeerForwarder generatePeerForwarder(final List<String> staticEndpoints, final int spansPerRequest) {
final HashMap<String, Object> settings = new HashMap<>();
settings.put(PeerForwarderConfig.DISCOVERY_MODE, "STATIC");
settings.put(PeerForwarderConfig.STATIC_ENDPOINTS, staticEndpoints);
settings.put(PeerForwarderConfig.MAX_NUM_SPANS_PER_REQUEST, spansPerRequest);
settings.put(PeerForwarderConfig.TIME_OUT, 300);
settings.put(PeerForwarderConfig.SSL, false);
final PluginSetting pluginSetting = new PluginSetting("peer_forwarder", settings);
pluginSetting.setPipelineName(TEST_PIPELINE_NAME);
return new PeerForwarder(pluginSetting);
}
use of com.amazon.dataprepper.model.configuration.PluginSetting in project data-prepper by opensearch-project.
the class ServiceMapStatefulPrepperTest method testPluginSettingConstructor.
@Test
public void testPluginSettingConstructor() {
final PluginSetting pluginSetting = new PluginSetting("testPluginSetting", Collections.emptyMap());
pluginSetting.setProcessWorkers(4);
pluginSetting.setPipelineName("TestPipeline");
// Nothing is accessible to validate, so just verify that no exception is thrown.
final ServiceMapStatefulPrepper serviceMapStatefulPrepper = new ServiceMapStatefulPrepper(pluginSetting);
}
use of com.amazon.dataprepper.model.configuration.PluginSetting in project data-prepper by opensearch-project.
the class DnsPeerListProvider_CreateTest method setup.
@BeforeEach
void setup() {
pluginSetting = new PluginSetting(PLUGIN_NAME, new HashMap<>()) {
{
setPipelineName(PIPELINE_NAME);
}
};
completableFuture = CompletableFuture.completedFuture(null);
pluginSetting.getSettings().put(PeerForwarderConfig.DISCOVERY_MODE, DiscoveryMode.DNS.toString());
pluginMetrics = mock(PluginMetrics.class);
}
use of com.amazon.dataprepper.model.configuration.PluginSetting in project data-prepper by opensearch-project.
the class PeerListProviderFactoryTest method setup.
@BeforeEach
void setup() {
factory = new PeerListProviderFactory();
pluginSetting = new PluginSetting(PLUGIN_NAME, new HashMap<>()) {
{
setPipelineName(PIPELINE_NAME);
}
};
}
use of com.amazon.dataprepper.model.configuration.PluginSetting in project data-prepper by opensearch-project.
the class ZipkinOpenSearchToOtel method getBuffer.
private static BlockingBuffer<Record<Object>> getBuffer() {
final HashMap<String, Object> integerHashMap = new HashMap<>();
integerHashMap.put("buffer_size", 5);
return new BlockingBuffer<>(new PluginSetting("blocking_buffer", integerHashMap));
}
Aggregations