作业启动注释添加
This commit is contained in:
parent
b58553bb1e
commit
aa9f3e1da4
@ -277,6 +277,7 @@ static DFSOutputStream newStreamForCreate(DFSClient dfsClient, String src,
|
||||
while (shouldRetry) {
|
||||
shouldRetry = false;
|
||||
try {
|
||||
// 通过rpc调用namenode(或者router,router最终还是会调用到namnode)创建文件。
|
||||
stat = dfsClient.namenode.create(src, masked, dfsClient.clientName,
|
||||
new EnumSetWritable<>(flag), createParent, replication,
|
||||
blockSize, SUPPORTED_CRYPTO_VERSIONS, ecPolicyName,
|
||||
|
@ -42,6 +42,9 @@
|
||||
*
|
||||
* This is responsible for sending edits as well as coordinating
|
||||
* recovery of the nodes.
|
||||
* 主要适用于Journal组件中处理edits log:
|
||||
* 1、 接受edit log
|
||||
* 2、 发送edit给namenode,方便恢复
|
||||
*/
|
||||
@KerberosInfo(
|
||||
serverPrincipal = DFSConfigKeys.DFS_JOURNALNODE_KERBEROS_PRINCIPAL_KEY,
|
||||
|
@ -785,6 +785,7 @@ public HdfsFileStatus create(String src, FsPermission masked,
|
||||
String storagePolicy)
|
||||
throws IOException {
|
||||
checkNNStartup();
|
||||
// 获取客户端的ip
|
||||
String clientMachine = getClientMachine();
|
||||
if (stateChangeLog.isDebugEnabled()) {
|
||||
stateChangeLog.debug("*DIR* NameNode.create: file "
|
||||
|
@ -1669,12 +1669,14 @@ public void submit()
|
||||
throws IOException, InterruptedException, ClassNotFoundException {
|
||||
ensureState(JobState.DEFINE);
|
||||
setUseNewAPI();
|
||||
// 连接RM
|
||||
connect();
|
||||
final JobSubmitter submitter =
|
||||
getJobSubmitter(cluster.getFileSystem(), cluster.getClient());
|
||||
status = ugi.doAs(new PrivilegedExceptionAction<JobStatus>() {
|
||||
public JobStatus run() throws IOException, InterruptedException,
|
||||
ClassNotFoundException {
|
||||
// 提交作业
|
||||
return submitter.submitJobInternal(Job.this, cluster);
|
||||
}
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user