-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HBASE-26646 WALPlayer should obtain token from filesystem #4003
Conversation
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
@mymeiyi Can you add a test case with secure cluster setup ? |
@@ -344,6 +345,9 @@ public Job createSubmittableJob(String[] args) throws IOException { | |||
try { | |||
TableMapReduceUtil.addDependencyJarsForClasses(job.getConfiguration(), | |||
Class.forName(codecCls)); | |||
// get delegation token for the filesystem | |||
TokenCache.obtainTokensForNamenodes(job.getCredentials(), new Path[] { new Path(inputDirs) }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think JobSubmitter get a token from hdfs for yarn cluster, here we also need a token from hdfs for hbase cluster
I think this should be done in WALInputFormat. Looking at the code of FileInputFormat, TokenCache.obtainTokensForNamenodes will be called in listStatus method, which will be called in getSplits method. So I think for WALInputFormat, we should also call TokenCache.obtainTokensForNamenodes in getSplits method? Thanks. |
So could this solve your problem? |
Yes, it works in our cluster. |
OK, good. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
Signed-off-by: Duo Zhang <[email protected]>
Signed-off-by: Duo Zhang <[email protected]>
Signed-off-by: Duo Zhang <[email protected]>
Signed-off-by: Duo Zhang <[email protected]>
Signed-off-by: Duo Zhang <[email protected]> (cherry picked from commit b68c4aa) Change-Id: Id879fda366d2063fa97c73c41d394e436b8aad35
No description provided.