use of org.apache.hadoop.hdds.protocol.proto.StorageContainerLocationProtocolProtos.ListPipelineRequestProto in project ozone by apache.
the class StorageContainerLocationProtocolClientSideTranslatorPB method listPipelines.
@Override
public List<Pipeline> listPipelines() throws IOException {
ListPipelineRequestProto request = ListPipelineRequestProto.newBuilder().setTraceID(TracingUtil.exportCurrentSpan()).build();
ListPipelineResponseProto response = submitRequest(Type.ListPipelines, builder -> builder.setListPipelineRequest(request)).getListPipelineResponse();
List<Pipeline> list = new ArrayList<>();
for (HddsProtos.Pipeline pipeline : response.getPipelinesList()) {
Pipeline fromProtobuf = Pipeline.getFromProtobuf(pipeline);
list.add(fromProtobuf);
}
return list;
}
Aggregations