use of org.apache.kafka.common.requests.SyncGroupResponse in project apache-kafka-on-k8s by banzaicloud.
the class WorkerCoordinatorTest method syncGroupResponse.
private SyncGroupResponse syncGroupResponse(short assignmentError, String leader, long configOffset, List<String> connectorIds, List<ConnectorTaskId> taskIds, Errors error) {
ConnectProtocol.Assignment assignment = new ConnectProtocol.Assignment(assignmentError, leader, LEADER_URL, configOffset, connectorIds, taskIds);
ByteBuffer buf = ConnectProtocol.serializeAssignment(assignment);
return new SyncGroupResponse(error, buf);
}
use of org.apache.kafka.common.requests.SyncGroupResponse in project kafka by apache.
the class WorkerCoordinatorTest method syncGroupResponse.
private SyncGroupResponse syncGroupResponse(short assignmentError, String leader, long configOffset, List<String> connectorIds, List<ConnectorTaskId> taskIds, Errors error) {
ConnectProtocol.Assignment assignment = new ConnectProtocol.Assignment(assignmentError, leader, LEADER_URL, configOffset, connectorIds, taskIds);
ByteBuffer buf = ConnectProtocol.serializeAssignment(assignment);
return new SyncGroupResponse(new SyncGroupResponseData().setErrorCode(error.code()).setAssignment(Utils.toArray(buf)));
}
Aggregations