use of org.apache.kafka.common.message.IncrementalAlterConfigsRequestData in project kafka by apache.
the class RequestResponseTest method createIncrementalAlterConfigsRequest.
private IncrementalAlterConfigsRequest createIncrementalAlterConfigsRequest(short version) {
IncrementalAlterConfigsRequestData data = new IncrementalAlterConfigsRequestData();
AlterableConfig alterableConfig = new AlterableConfig().setName("retention.ms").setConfigOperation((byte) 0).setValue("100");
IncrementalAlterConfigsRequestData.AlterableConfigCollection alterableConfigs = new IncrementalAlterConfigsRequestData.AlterableConfigCollection();
alterableConfigs.add(alterableConfig);
data.resources().add(new AlterConfigsResource().setResourceName("testtopic").setResourceType(ResourceType.TOPIC.code()).setConfigs(alterableConfigs));
return new IncrementalAlterConfigsRequest.Builder(data).build(version);
}
Aggregations