org.apache.hadoop.yarn.proto.YarnProtos.ContainerIdProto Java Examples
The following examples show how to use
org.apache.hadoop.yarn.proto.YarnProtos.ContainerIdProto.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: StopContainersResponsePBImpl.java From hadoop with Apache License 2.0 | 5 votes |
private void addSucceededRequestsToProto() { maybeInitBuilder(); builder.clearSucceededRequests(); if (this.succeededRequests == null) { return; } Iterable<ContainerIdProto> iterable = new Iterable<ContainerIdProto>() { @Override public Iterator<ContainerIdProto> iterator() { return new Iterator<ContainerIdProto>() { Iterator<ContainerId> iter = succeededRequests.iterator(); @Override public boolean hasNext() { return iter.hasNext(); } @Override public ContainerIdProto next() { return convertToProtoFormat(iter.next()); } @Override public void remove() { throw new UnsupportedOperationException(); } }; } }; builder.addAllSucceededRequests(iterable); }
Example #2
Source File: StartContainersResponsePBImpl.java From hadoop with Apache License 2.0 | 5 votes |
private void initSucceededContainers() { if (this.succeededContainers != null) return; StartContainersResponseProtoOrBuilder p = viaProto ? proto : builder; List<ContainerIdProto> list = p.getSucceededRequestsList(); this.succeededContainers = new ArrayList<ContainerId>(); for (ContainerIdProto c : list) { this.succeededContainers.add(convertFromProtoFormat(c)); } }
Example #3
Source File: AllocateRequestPBImpl.java From hadoop with Apache License 2.0 | 5 votes |
private void addReleasesToProto() { maybeInitBuilder(); builder.clearRelease(); if (release == null) return; Iterable<ContainerIdProto> iterable = new Iterable<ContainerIdProto>() { @Override public Iterator<ContainerIdProto> iterator() { return new Iterator<ContainerIdProto>() { Iterator<ContainerId> iter = release.iterator(); @Override public boolean hasNext() { return iter.hasNext(); } @Override public ContainerIdProto next() { return convertToProtoFormat(iter.next()); } @Override public void remove() { throw new UnsupportedOperationException(); } }; } }; builder.addAllRelease(iterable); }
Example #4
Source File: AllocateRequestPBImpl.java From hadoop with Apache License 2.0 | 5 votes |
private void initReleases() { if (this.release != null) { return; } AllocateRequestProtoOrBuilder p = viaProto ? proto : builder; List<ContainerIdProto> list = p.getReleaseList(); this.release = new ArrayList<ContainerId>(); for (ContainerIdProto c : list) { this.release.add(convertFromProtoFormat(c)); } }
Example #5
Source File: StartContainersResponsePBImpl.java From hadoop with Apache License 2.0 | 5 votes |
private void addSucceededContainersToProto() { maybeInitBuilder(); builder.clearSucceededRequests(); if (this.succeededContainers == null) { return; } Iterable<ContainerIdProto> iterable = new Iterable<ContainerIdProto>() { @Override public Iterator<ContainerIdProto> iterator() { return new Iterator<ContainerIdProto>() { Iterator<ContainerId> iter = succeededContainers.iterator(); @Override public boolean hasNext() { return iter.hasNext(); } @Override public ContainerIdProto next() { return convertToProtoFormat(iter.next()); } @Override public void remove() { throw new UnsupportedOperationException(); } }; } }; builder.addAllSucceededRequests(iterable); }
Example #6
Source File: GetContainerStatusesRequestPBImpl.java From big-c with Apache License 2.0 | 5 votes |
private void addLocalContainerIdsToProto() { maybeInitBuilder(); builder.clearContainerId(); if (this.containerIds == null) return; List<ContainerIdProto> protoList = new ArrayList<ContainerIdProto>(); for (ContainerId id : containerIds) { protoList.add(convertToProtoFormat(id)); } builder.addAllContainerId(protoList); }
Example #7
Source File: NodeHeartbeatResponsePBImpl.java From hadoop with Apache License 2.0 | 5 votes |
private void addContainersToBeRemovedFromNMToProto() { maybeInitBuilder(); builder.clearContainersToBeRemovedFromNm(); if (containersToBeRemovedFromNM == null) return; Iterable<ContainerIdProto> iterable = new Iterable<ContainerIdProto>() { @Override public Iterator<ContainerIdProto> iterator() { return new Iterator<ContainerIdProto>() { Iterator<ContainerId> iter = containersToBeRemovedFromNM.iterator(); @Override public boolean hasNext() { return iter.hasNext(); } @Override public ContainerIdProto next() { return convertToProtoFormat(iter.next()); } @Override public void remove() { throw new UnsupportedOperationException(); } }; } }; builder.addAllContainersToBeRemovedFromNm(iterable); }
Example #8
Source File: NodeHeartbeatResponsePBImpl.java From big-c with Apache License 2.0 | 5 votes |
private void addContainersToCleanupToProto() { maybeInitBuilder(); builder.clearContainersToCleanup(); if (containersToCleanup == null) return; Iterable<ContainerIdProto> iterable = new Iterable<ContainerIdProto>() { @Override public Iterator<ContainerIdProto> iterator() { return new Iterator<ContainerIdProto>() { Iterator<ContainerId> iter = containersToCleanup.iterator(); @Override public boolean hasNext() { return iter.hasNext(); } @Override public ContainerIdProto next() { return convertToProtoFormat(iter.next()); } @Override public void remove() { throw new UnsupportedOperationException(); } }; } }; builder.addAllContainersToCleanup(iterable); }
Example #9
Source File: StartContainersResponsePBImpl.java From big-c with Apache License 2.0 | 5 votes |
private void initSucceededContainers() { if (this.succeededContainers != null) return; StartContainersResponseProtoOrBuilder p = viaProto ? proto : builder; List<ContainerIdProto> list = p.getSucceededRequestsList(); this.succeededContainers = new ArrayList<ContainerId>(); for (ContainerIdProto c : list) { this.succeededContainers.add(convertFromProtoFormat(c)); } }
Example #10
Source File: StopContainersResponsePBImpl.java From hadoop with Apache License 2.0 | 5 votes |
private void initSucceededRequests() { if (this.succeededRequests != null) return; StopContainersResponseProtoOrBuilder p = viaProto ? proto : builder; List<ContainerIdProto> list = p.getSucceededRequestsList(); this.succeededRequests = new ArrayList<ContainerId>(); for (ContainerIdProto c : list) { this.succeededRequests.add(convertFromProtoFormat(c)); } }
Example #11
Source File: StopContainersRequestPBImpl.java From big-c with Apache License 2.0 | 5 votes |
private void addLocalContainerIdsToProto() { maybeInitBuilder(); builder.clearContainerId(); if (this.containerIds == null) return; List<ContainerIdProto> protoList = new ArrayList<ContainerIdProto>(); for (ContainerId id : containerIds) { protoList.add(convertToProtoFormat(id)); } builder.addAllContainerId(protoList); }
Example #12
Source File: NodeHeartbeatResponsePBImpl.java From big-c with Apache License 2.0 | 5 votes |
private void addContainersToBeRemovedFromNMToProto() { maybeInitBuilder(); builder.clearContainersToBeRemovedFromNm(); if (containersToBeRemovedFromNM == null) return; Iterable<ContainerIdProto> iterable = new Iterable<ContainerIdProto>() { @Override public Iterator<ContainerIdProto> iterator() { return new Iterator<ContainerIdProto>() { Iterator<ContainerId> iter = containersToBeRemovedFromNM.iterator(); @Override public boolean hasNext() { return iter.hasNext(); } @Override public ContainerIdProto next() { return convertToProtoFormat(iter.next()); } @Override public void remove() { throw new UnsupportedOperationException(); } }; } }; builder.addAllContainersToBeRemovedFromNm(iterable); }
Example #13
Source File: StartContainersResponsePBImpl.java From big-c with Apache License 2.0 | 5 votes |
private void addSucceededContainersToProto() { maybeInitBuilder(); builder.clearSucceededRequests(); if (this.succeededContainers == null) { return; } Iterable<ContainerIdProto> iterable = new Iterable<ContainerIdProto>() { @Override public Iterator<ContainerIdProto> iterator() { return new Iterator<ContainerIdProto>() { Iterator<ContainerId> iter = succeededContainers.iterator(); @Override public boolean hasNext() { return iter.hasNext(); } @Override public ContainerIdProto next() { return convertToProtoFormat(iter.next()); } @Override public void remove() { throw new UnsupportedOperationException(); } }; } }; builder.addAllSucceededRequests(iterable); }
Example #14
Source File: AllocateRequestPBImpl.java From big-c with Apache License 2.0 | 5 votes |
private void initReleases() { if (this.release != null) { return; } AllocateRequestProtoOrBuilder p = viaProto ? proto : builder; List<ContainerIdProto> list = p.getReleaseList(); this.release = new ArrayList<ContainerId>(); for (ContainerIdProto c : list) { this.release.add(convertFromProtoFormat(c)); } }
Example #15
Source File: AllocateRequestPBImpl.java From big-c with Apache License 2.0 | 5 votes |
private void addReleasesToProto() { maybeInitBuilder(); builder.clearRelease(); if (release == null) return; Iterable<ContainerIdProto> iterable = new Iterable<ContainerIdProto>() { @Override public Iterator<ContainerIdProto> iterator() { return new Iterator<ContainerIdProto>() { Iterator<ContainerId> iter = release.iterator(); @Override public boolean hasNext() { return iter.hasNext(); } @Override public ContainerIdProto next() { return convertToProtoFormat(iter.next()); } @Override public void remove() { throw new UnsupportedOperationException(); } }; } }; builder.addAllRelease(iterable); }
Example #16
Source File: NodeHeartbeatResponsePBImpl.java From hadoop with Apache License 2.0 | 5 votes |
private void initContainersToCleanup() { if (this.containersToCleanup != null) { return; } NodeHeartbeatResponseProtoOrBuilder p = viaProto ? proto : builder; List<ContainerIdProto> list = p.getContainersToCleanupList(); this.containersToCleanup = new ArrayList<ContainerId>(); for (ContainerIdProto c : list) { this.containersToCleanup.add(convertFromProtoFormat(c)); } }
Example #17
Source File: ContainerStartDataPBImpl.java From hadoop with Apache License 2.0 | 4 votes |
private ContainerIdProto convertToProtoFormat(ContainerId containerId) { return ((ContainerIdPBImpl) containerId).getProto(); }
Example #18
Source File: PreemptionContainerPBImpl.java From big-c with Apache License 2.0 | 4 votes |
private ContainerIdProto convertToProtoFormat(ContainerId t) { return ((ContainerIdPBImpl)t).getProto(); }
Example #19
Source File: ContainerResourceIncreaseRequestPBImpl.java From big-c with Apache License 2.0 | 4 votes |
private ContainerIdPBImpl convertFromProtoFormat(ContainerIdProto p) { return new ContainerIdPBImpl(p); }
Example #20
Source File: StopContainersResponsePBImpl.java From big-c with Apache License 2.0 | 4 votes |
private ContainerIdPBImpl convertFromProtoFormat(ContainerIdProto p) { return new ContainerIdPBImpl(p); }
Example #21
Source File: StopContainersRequestPBImpl.java From big-c with Apache License 2.0 | 4 votes |
private ContainerIdPBImpl convertFromProtoFormat(ContainerIdProto p) { return new ContainerIdPBImpl(p); }
Example #22
Source File: AMInfoPBImpl.java From big-c with Apache License 2.0 | 4 votes |
private ContainerIdProto convertToProtoFormat(ContainerId t) { return ((ContainerIdPBImpl) t).getProto(); }
Example #23
Source File: ContainerFinishDataPBImpl.java From hadoop with Apache License 2.0 | 4 votes |
private ContainerIdPBImpl convertFromProtoFormat(ContainerIdProto containerId) { return new ContainerIdPBImpl(containerId); }
Example #24
Source File: ContainerFinishDataPBImpl.java From hadoop with Apache License 2.0 | 4 votes |
private ContainerIdProto convertToProtoFormat(ContainerId containerId) { return ((ContainerIdPBImpl) containerId).getProto(); }
Example #25
Source File: ContainerPBImpl.java From big-c with Apache License 2.0 | 4 votes |
private ContainerIdPBImpl convertFromProtoFormat(ContainerIdProto p) { return new ContainerIdPBImpl(p); }
Example #26
Source File: NMContainerStatusPBImpl.java From hadoop with Apache License 2.0 | 4 votes |
private ContainerIdPBImpl convertFromProtoFormat(ContainerIdProto p) { return new ContainerIdPBImpl(p); }
Example #27
Source File: AMInfoPBImpl.java From hadoop with Apache License 2.0 | 4 votes |
private ContainerIdProto convertToProtoFormat(ContainerId t) { return ((ContainerIdPBImpl) t).getProto(); }
Example #28
Source File: NodeHeartbeatResponsePBImpl.java From hadoop with Apache License 2.0 | 4 votes |
private ContainerIdPBImpl convertFromProtoFormat(ContainerIdProto p) { return new ContainerIdPBImpl(p); }
Example #29
Source File: ContainerStatusPBImpl.java From hadoop with Apache License 2.0 | 4 votes |
private ContainerIdProto convertToProtoFormat(ContainerId t) { return ((ContainerIdPBImpl)t).getProto(); }
Example #30
Source File: ContainerResourceDecreasePBImpl.java From big-c with Apache License 2.0 | 4 votes |
private ContainerIdPBImpl convertFromProtoFormat(ContainerIdProto p) { return new ContainerIdPBImpl(p); }