use of org.apache.kafka.connect.runtime.isolation.Plugins in project apache-kafka-on-k8s by banzaicloud.
the class TransformationConfigTest method testEmbeddedConfigCast.
@Test
public void testEmbeddedConfigCast() {
// Validate that we can construct a Connector config containing the extended config for the transform
HashMap<String, String> connProps = new HashMap<>();
connProps.put("name", "foo");
connProps.put("connector.class", MockConnector.class.getName());
connProps.put("transforms", "example");
connProps.put("transforms.example.type", Cast.Value.class.getName());
connProps.put("transforms.example.spec", "int8");
// Safe when we're only constructing the config
Plugins plugins = null;
new ConnectorConfig(plugins, connProps);
}
use of org.apache.kafka.connect.runtime.isolation.Plugins in project apache-kafka-on-k8s by banzaicloud.
the class TransformationConfigTest method testEmbeddedConfigHoistField.
@Test
public void testEmbeddedConfigHoistField() {
// Validate that we can construct a Connector config containing the extended config for the transform
HashMap<String, String> connProps = new HashMap<>();
connProps.put("name", "foo");
connProps.put("connector.class", MockConnector.class.getName());
connProps.put("transforms", "example");
connProps.put("transforms.example.type", HoistField.Value.class.getName());
connProps.put("transforms.example.field", "field");
// Safe when we're only constructing the config
Plugins plugins = null;
new ConnectorConfig(plugins, connProps);
}
use of org.apache.kafka.connect.runtime.isolation.Plugins in project apache-kafka-on-k8s by banzaicloud.
the class TransformationConfigTest method testEmbeddedConfigTimestampRouter.
@Test
public void testEmbeddedConfigTimestampRouter() {
// Validate that we can construct a Connector config containing the extended config for the transform
HashMap<String, String> connProps = new HashMap<>();
connProps.put("name", "foo");
connProps.put("connector.class", MockConnector.class.getName());
connProps.put("transforms", "example");
connProps.put("transforms.example.type", TimestampRouter.class.getName());
// Safe when we're only constructing the config
Plugins plugins = null;
new ConnectorConfig(plugins, connProps);
}
use of org.apache.kafka.connect.runtime.isolation.Plugins in project apache-kafka-on-k8s by banzaicloud.
the class TransformationConfigTest method testEmbeddedConfigFlatten.
@Test
public void testEmbeddedConfigFlatten() {
// Validate that we can construct a Connector config containing the extended config for the transform
HashMap<String, String> connProps = new HashMap<>();
connProps.put("name", "foo");
connProps.put("connector.class", MockConnector.class.getName());
connProps.put("transforms", "example");
connProps.put("transforms.example.type", Flatten.Value.class.getName());
// Safe when we're only constructing the config
Plugins plugins = null;
new ConnectorConfig(plugins, connProps);
}
use of org.apache.kafka.connect.runtime.isolation.Plugins in project apache-kafka-on-k8s by banzaicloud.
the class TransformationConfigTest method testEmbeddedConfigExtractField.
@Test
public void testEmbeddedConfigExtractField() {
// Validate that we can construct a Connector config containing the extended config for the transform
HashMap<String, String> connProps = new HashMap<>();
connProps.put("name", "foo");
connProps.put("connector.class", MockConnector.class.getName());
connProps.put("transforms", "example");
connProps.put("transforms.example.type", ExtractField.Value.class.getName());
connProps.put("transforms.example.field", "field");
// Safe when we're only constructing the config
Plugins plugins = null;
new ConnectorConfig(plugins, connProps);
}
Aggregations