org.apache.hadoop.yarn.server.resourcemanager.recovery.ZKRMStateStore.doDeleteMultiWithRetries()方法的使用及代码示例

x33g5p2x  于2022-02-05 转载在 其他  
字(4.9k)|赞(0)|评价(0)|浏览(94)

本文整理了Java中org.apache.hadoop.yarn.server.resourcemanager.recovery.ZKRMStateStore.doDeleteMultiWithRetries()方法的一些代码示例,展示了ZKRMStateStore.doDeleteMultiWithRetries()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZKRMStateStore.doDeleteMultiWithRetries()方法的具体详情如下:
包路径:org.apache.hadoop.yarn.server.resourcemanager.recovery.ZKRMStateStore
类名称:ZKRMStateStore
方法名:doDeleteMultiWithRetries

ZKRMStateStore.doDeleteMultiWithRetries介绍

[英]Helper method that creates fencing node, executes the passed delete related operations and deletes the fencing node.
[中]创建围栏节点、执行传递的删除相关操作并删除围栏节点的助手方法。

代码示例

代码示例来源:origin: ch.cern.hadoop/hadoop-yarn-server-resourcemanager

private void doDeleteMultiWithRetries(final Op op) throws Exception {
 doDeleteMultiWithRetries(Collections.singletonList(op));
}

代码示例来源:origin: com.github.jiayuhan-it/hadoop-yarn-server-resourcemanager

private void doDeleteMultiWithRetries(final Op op) throws Exception {
 doDeleteMultiWithRetries(Collections.singletonList(op));
}

代码示例来源:origin: com.github.jiayuhan-it/hadoop-yarn-server-resourcemanager

@Override
protected synchronized void removeRMDelegationTokenState(
  RMDelegationTokenIdentifier rmDTIdentifier) throws Exception {
 String nodeRemovePath =
   getNodePath(delegationTokensRootPath, DELEGATION_TOKEN_PREFIX
     + rmDTIdentifier.getSequenceNumber());
 if (LOG.isDebugEnabled()) {
  LOG.debug("Removing RMDelegationToken_"
    + rmDTIdentifier.getSequenceNumber());
 }
 if (existsWithRetries(nodeRemovePath, false) != null) {
  ArrayList<Op> opList = new ArrayList<Op>();
  opList.add(Op.delete(nodeRemovePath, -1));
  doDeleteMultiWithRetries(opList);
 } else {
  LOG.debug("Attempted to delete a non-existing znode " + nodeRemovePath);
 }
}

代码示例来源:origin: ch.cern.hadoop/hadoop-yarn-server-resourcemanager

@Override
protected synchronized void removeRMDTMasterKeyState(
  DelegationKey delegationKey) throws Exception {
 String nodeRemovePath =
   getNodePath(dtMasterKeysRootPath, DELEGATION_KEY_PREFIX
     + delegationKey.getKeyId());
 if (LOG.isDebugEnabled()) {
  LOG.debug("Removing RMDelegationKey_" + delegationKey.getKeyId());
 }
 if (existsWithRetries(nodeRemovePath, false) != null) {
  doDeleteMultiWithRetries(Op.delete(nodeRemovePath, -1));
 } else {
  LOG.debug("Attempted to delete a non-existing znode " + nodeRemovePath);
 }
}

代码示例来源:origin: ch.cern.hadoop/hadoop-yarn-server-resourcemanager

@Override
protected synchronized void removeRMDelegationTokenState(
  RMDelegationTokenIdentifier rmDTIdentifier) throws Exception {
 String nodeRemovePath =
   getNodePath(delegationTokensRootPath, DELEGATION_TOKEN_PREFIX
     + rmDTIdentifier.getSequenceNumber());
 if (LOG.isDebugEnabled()) {
  LOG.debug("Removing RMDelegationToken_"
    + rmDTIdentifier.getSequenceNumber());
 }
 if (existsWithRetries(nodeRemovePath, false) != null) {
  ArrayList<Op> opList = new ArrayList<Op>();
  opList.add(Op.delete(nodeRemovePath, -1));
  doDeleteMultiWithRetries(opList);
 } else {
  LOG.debug("Attempted to delete a non-existing znode " + nodeRemovePath);
 }
}

代码示例来源:origin: com.github.jiayuhan-it/hadoop-yarn-server-resourcemanager

@Override
protected synchronized void removeRMDTMasterKeyState(
  DelegationKey delegationKey) throws Exception {
 String nodeRemovePath =
   getNodePath(dtMasterKeysRootPath, DELEGATION_KEY_PREFIX
     + delegationKey.getKeyId());
 if (LOG.isDebugEnabled()) {
  LOG.debug("Removing RMDelegationKey_" + delegationKey.getKeyId());
 }
 if (existsWithRetries(nodeRemovePath, false) != null) {
  doDeleteMultiWithRetries(Op.delete(nodeRemovePath, -1));
 } else {
  LOG.debug("Attempted to delete a non-existing znode " + nodeRemovePath);
 }
}

代码示例来源:origin: com.github.jiayuhan-it/hadoop-yarn-server-resourcemanager

@Override
public synchronized void removeApplicationStateInternal(
  ApplicationStateData  appState)
  throws Exception {
 String appId = appState.getApplicationSubmissionContext().getApplicationId()
   .toString();
 String appIdRemovePath = getNodePath(rmAppRoot, appId);
 ArrayList<Op> opList = new ArrayList<Op>();
 for (ApplicationAttemptId attemptId : appState.attempts.keySet()) {
  String attemptRemovePath = getNodePath(appIdRemovePath, attemptId.toString());
  opList.add(Op.delete(attemptRemovePath, -1));
 }
 opList.add(Op.delete(appIdRemovePath, -1));
 if (LOG.isDebugEnabled()) {
  LOG.debug("Removing info for app: " + appId + " at: " + appIdRemovePath
    + " and its attempts.");
 }
 doDeleteMultiWithRetries(opList);
}

代码示例来源:origin: ch.cern.hadoop/hadoop-yarn-server-resourcemanager

@Override
public synchronized void removeApplicationStateInternal(
  ApplicationStateData  appState)
  throws Exception {
 String appId = appState.getApplicationSubmissionContext().getApplicationId()
   .toString();
 String appIdRemovePath = getNodePath(rmAppRoot, appId);
 ArrayList<Op> opList = new ArrayList<Op>();
 for (ApplicationAttemptId attemptId : appState.attempts.keySet()) {
  String attemptRemovePath = getNodePath(appIdRemovePath, attemptId.toString());
  opList.add(Op.delete(attemptRemovePath, -1));
 }
 opList.add(Op.delete(appIdRemovePath, -1));
 if (LOG.isDebugEnabled()) {
  LOG.debug("Removing info for app: " + appId + " at: " + appIdRemovePath
    + " and its attempts.");
 }
 doDeleteMultiWithRetries(opList);
}

相关文章

微信公众号

最新文章

更多