-
Notifications
You must be signed in to change notification settings - Fork 28.2k
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
[SPARK-8688][YARN]Bug fix: disable the cache fs to gain the HDFS connection. #7069
Conversation
Merged build triggered. |
Merged build started. |
Test build #35935 has started for PR 7069 at commit |
*/ | ||
private[spark] def getDiscachedConf(hadoopConf: Configuration, path: Path): Configuration = { | ||
val newConf = new Configuration(hadoopConf) | ||
val confKey = s"fs.${path.toUri.getScheme}.impl.disable.cache" |
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.
"discached" isn't a word so I'd suggest ...ConfBypassingFSCache? wordy, but accurate
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.
Ok, rename it to be getConfBypassingFSCache
Merged build triggered. |
Test build #35935 has finished for PR 7069 at commit
|
Merged build finished. Test PASSed. |
Merged build started. |
Test build #35937 has started for PR 7069 at commit |
Test build #35937 has finished for PR 7069 at commit
|
Merged build finished. Test PASSed. |
@@ -65,6 +65,8 @@ private[yarn] class AMDelegationTokenRenewer( | |||
sparkConf.getInt("spark.yarn.credentials.file.retention.days", 5) | |||
private val numFilesToKeep = | |||
sparkConf.getInt("spark.yarn.credentials.file.retention.count", 5) | |||
private val discachedConfiguration = |
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.
echoing @srowen's comment, can you rename this? I don't understand what discached
means
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 would just call this freshHadoopConf
to be more explicit
Merged build triggered. |
Merged build started. |
Test build #36074 has started for PR 7069 at commit |
Test build #36074 has finished for PR 7069 at commit
|
Merged build finished. Test PASSed. |
* This is to prevent the DFSClient from using an old cached token to connect to the NameNode. | ||
*/ | ||
private[spark] | ||
def getConfBypassingFSCache(hadoopConf: Configuration, path: Path): Configuration = { |
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.
One line, and this does not need a Path
arg but just a scheme, perhaps.
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.
if it doesn't fit on one line:
private[spark] def getConfBypassingFSCache(
hadoopConf: Configuration,
scheme: String): Configuration = {
...
}
Looks great. I think this is basically ready for merge. @harishreedharan can you do a sign off? |
Merged build triggered. |
Merged build started. |
Test build #36221 has started for PR 7069 at commit |
Test build #36221 has finished for PR 7069 at commit
|
Merged build finished. Test PASSed. |
I am on vacation till Sunday. I can take a look after. If you want to merge On Tuesday, June 30, 2015, UCB AMPLab notifications@github.com wrote:
Thanks, |
Alright then, I'm merging this into master. Thanks @SaintBacchus. |
If
fs.hdfs.impl.disable.cache
wasfalse
(default),FileSystem
will use the cachedDFSClient
which use old token.AMDelegationTokenRenewer
Although the
credentials
had the new Token, but it still use the cached client and old token.So It's better to set the
fs.hdfs.impl.disable.cache
astrue
to avoid token expired.Jira