[21/50] [abbrv] hadoop git commit: YARN-7250. Update Shared cache client api to use URLs.
YARN-7250. Update Shared cache client api to use URLs. Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/c114da5e Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/c114da5e Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/c114da5e Branch: refs/heads/YARN-6592 Commit: c114da5e64d14b1d9e614081c4171ea0391cb1aa Parents: 6f789fe Author: Chris TrezzoAuthored: Thu Sep 28 15:28:06 2017 -0700 Committer: Chris Trezzo Committed: Thu Sep 28 15:28:06 2017 -0700 -- .../yarn/client/api/SharedCacheClient.java | 22 .../client/api/impl/SharedCacheClientImpl.java | 36 +--- .../api/impl/TestSharedCacheClientImpl.java | 31 + 3 files changed, 23 insertions(+), 66 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hadoop/blob/c114da5e/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java index 60c1bd98..a9c1a07 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java @@ -27,6 +27,7 @@ import org.apache.hadoop.classification.InterfaceStability.Unstable; import org.apache.hadoop.fs.Path; import org.apache.hadoop.service.AbstractService; import org.apache.hadoop.yarn.api.records.ApplicationId; +import org.apache.hadoop.yarn.api.records.URL; import org.apache.hadoop.yarn.client.api.impl.SharedCacheClientImpl; import org.apache.hadoop.yarn.exceptions.YarnException; @@ -58,34 +59,25 @@ public abstract class SharedCacheClient extends AbstractService { * * * The SharedCacheManager responds with whether or not the - * resource exists in the cache. If the resource exists, a Path - * to the resource in the shared cache is returned. If the resource does not + * resource exists in the cache. If the resource exists, a URL to + * the resource in the shared cache is returned. If the resource does not * exist, null is returned instead. * * * - * Once a path has been returned for a resource, that path is safe to use for + * Once a URL has been returned for a resource, that URL is safe to use for * the lifetime of the application that corresponds to the provided * ApplicationId. * * - * - * Additionally, a name for the resource should be specified. A fragment will - * be added to the path with the desired name if the desired name is different - * than the name of the provided path from the shared cache. This ensures that - * if the returned path is used to create a LocalResource, then the symlink - * created during YARN localization will match the name specified. - * - * * @param applicationId ApplicationId of the application using the resource * @param resourceKey the key (i.e. checksum) that identifies the resource - * @param resourceName the desired name of the resource - * @return Path to the resource, or null if it does not exist + * @return URL to the resource, or null if it does not exist */ @Public @Unstable - public abstract Path use(ApplicationId applicationId, String resourceKey, - String resourceName) throws YarnException; + public abstract URL use(ApplicationId applicationId, String resourceKey) + throws YarnException; /** * http://git-wip-us.apache.org/repos/asf/hadoop/blob/c114da5e/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java index b910c28..3191d36 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java @@ -21,8 +21,6 @@ package org.apache.hadoop.yarn.client.api.impl; import java.io.IOException; import
[12/50] [abbrv] hadoop git commit: YARN-7250. Update Shared cache client api to use URLs.
YARN-7250. Update Shared cache client api to use URLs. Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/c114da5e Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/c114da5e Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/c114da5e Branch: refs/heads/HDFS-9806 Commit: c114da5e64d14b1d9e614081c4171ea0391cb1aa Parents: 6f789fe Author: Chris TrezzoAuthored: Thu Sep 28 15:28:06 2017 -0700 Committer: Chris Trezzo Committed: Thu Sep 28 15:28:06 2017 -0700 -- .../yarn/client/api/SharedCacheClient.java | 22 .../client/api/impl/SharedCacheClientImpl.java | 36 +--- .../api/impl/TestSharedCacheClientImpl.java | 31 + 3 files changed, 23 insertions(+), 66 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hadoop/blob/c114da5e/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java index 60c1bd98..a9c1a07 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java @@ -27,6 +27,7 @@ import org.apache.hadoop.classification.InterfaceStability.Unstable; import org.apache.hadoop.fs.Path; import org.apache.hadoop.service.AbstractService; import org.apache.hadoop.yarn.api.records.ApplicationId; +import org.apache.hadoop.yarn.api.records.URL; import org.apache.hadoop.yarn.client.api.impl.SharedCacheClientImpl; import org.apache.hadoop.yarn.exceptions.YarnException; @@ -58,34 +59,25 @@ public abstract class SharedCacheClient extends AbstractService { * * * The SharedCacheManager responds with whether or not the - * resource exists in the cache. If the resource exists, a Path - * to the resource in the shared cache is returned. If the resource does not + * resource exists in the cache. If the resource exists, a URL to + * the resource in the shared cache is returned. If the resource does not * exist, null is returned instead. * * * - * Once a path has been returned for a resource, that path is safe to use for + * Once a URL has been returned for a resource, that URL is safe to use for * the lifetime of the application that corresponds to the provided * ApplicationId. * * - * - * Additionally, a name for the resource should be specified. A fragment will - * be added to the path with the desired name if the desired name is different - * than the name of the provided path from the shared cache. This ensures that - * if the returned path is used to create a LocalResource, then the symlink - * created during YARN localization will match the name specified. - * - * * @param applicationId ApplicationId of the application using the resource * @param resourceKey the key (i.e. checksum) that identifies the resource - * @param resourceName the desired name of the resource - * @return Path to the resource, or null if it does not exist + * @return URL to the resource, or null if it does not exist */ @Public @Unstable - public abstract Path use(ApplicationId applicationId, String resourceKey, - String resourceName) throws YarnException; + public abstract URL use(ApplicationId applicationId, String resourceKey) + throws YarnException; /** * http://git-wip-us.apache.org/repos/asf/hadoop/blob/c114da5e/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java index b910c28..3191d36 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java @@ -21,8 +21,6 @@ package org.apache.hadoop.yarn.client.api.impl; import java.io.IOException; import
[11/35] hadoop git commit: YARN-7250. Update Shared cache client api to use URLs.
YARN-7250. Update Shared cache client api to use URLs. Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/c114da5e Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/c114da5e Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/c114da5e Branch: refs/heads/HDFS-7240 Commit: c114da5e64d14b1d9e614081c4171ea0391cb1aa Parents: 6f789fe Author: Chris TrezzoAuthored: Thu Sep 28 15:28:06 2017 -0700 Committer: Chris Trezzo Committed: Thu Sep 28 15:28:06 2017 -0700 -- .../yarn/client/api/SharedCacheClient.java | 22 .../client/api/impl/SharedCacheClientImpl.java | 36 +--- .../api/impl/TestSharedCacheClientImpl.java | 31 + 3 files changed, 23 insertions(+), 66 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hadoop/blob/c114da5e/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java index 60c1bd98..a9c1a07 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java @@ -27,6 +27,7 @@ import org.apache.hadoop.classification.InterfaceStability.Unstable; import org.apache.hadoop.fs.Path; import org.apache.hadoop.service.AbstractService; import org.apache.hadoop.yarn.api.records.ApplicationId; +import org.apache.hadoop.yarn.api.records.URL; import org.apache.hadoop.yarn.client.api.impl.SharedCacheClientImpl; import org.apache.hadoop.yarn.exceptions.YarnException; @@ -58,34 +59,25 @@ public abstract class SharedCacheClient extends AbstractService { * * * The SharedCacheManager responds with whether or not the - * resource exists in the cache. If the resource exists, a Path - * to the resource in the shared cache is returned. If the resource does not + * resource exists in the cache. If the resource exists, a URL to + * the resource in the shared cache is returned. If the resource does not * exist, null is returned instead. * * * - * Once a path has been returned for a resource, that path is safe to use for + * Once a URL has been returned for a resource, that URL is safe to use for * the lifetime of the application that corresponds to the provided * ApplicationId. * * - * - * Additionally, a name for the resource should be specified. A fragment will - * be added to the path with the desired name if the desired name is different - * than the name of the provided path from the shared cache. This ensures that - * if the returned path is used to create a LocalResource, then the symlink - * created during YARN localization will match the name specified. - * - * * @param applicationId ApplicationId of the application using the resource * @param resourceKey the key (i.e. checksum) that identifies the resource - * @param resourceName the desired name of the resource - * @return Path to the resource, or null if it does not exist + * @return URL to the resource, or null if it does not exist */ @Public @Unstable - public abstract Path use(ApplicationId applicationId, String resourceKey, - String resourceName) throws YarnException; + public abstract URL use(ApplicationId applicationId, String resourceKey) + throws YarnException; /** * http://git-wip-us.apache.org/repos/asf/hadoop/blob/c114da5e/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java index b910c28..3191d36 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java @@ -21,8 +21,6 @@ package org.apache.hadoop.yarn.client.api.impl; import java.io.IOException; import
[03/50] [abbrv] hadoop git commit: YARN-7250. Update Shared cache client api to use URLs.
YARN-7250. Update Shared cache client api to use URLs. Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/c114da5e Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/c114da5e Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/c114da5e Branch: refs/heads/HDFS-10467 Commit: c114da5e64d14b1d9e614081c4171ea0391cb1aa Parents: 6f789fe Author: Chris TrezzoAuthored: Thu Sep 28 15:28:06 2017 -0700 Committer: Chris Trezzo Committed: Thu Sep 28 15:28:06 2017 -0700 -- .../yarn/client/api/SharedCacheClient.java | 22 .../client/api/impl/SharedCacheClientImpl.java | 36 +--- .../api/impl/TestSharedCacheClientImpl.java | 31 + 3 files changed, 23 insertions(+), 66 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hadoop/blob/c114da5e/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java index 60c1bd98..a9c1a07 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java @@ -27,6 +27,7 @@ import org.apache.hadoop.classification.InterfaceStability.Unstable; import org.apache.hadoop.fs.Path; import org.apache.hadoop.service.AbstractService; import org.apache.hadoop.yarn.api.records.ApplicationId; +import org.apache.hadoop.yarn.api.records.URL; import org.apache.hadoop.yarn.client.api.impl.SharedCacheClientImpl; import org.apache.hadoop.yarn.exceptions.YarnException; @@ -58,34 +59,25 @@ public abstract class SharedCacheClient extends AbstractService { * * * The SharedCacheManager responds with whether or not the - * resource exists in the cache. If the resource exists, a Path - * to the resource in the shared cache is returned. If the resource does not + * resource exists in the cache. If the resource exists, a URL to + * the resource in the shared cache is returned. If the resource does not * exist, null is returned instead. * * * - * Once a path has been returned for a resource, that path is safe to use for + * Once a URL has been returned for a resource, that URL is safe to use for * the lifetime of the application that corresponds to the provided * ApplicationId. * * - * - * Additionally, a name for the resource should be specified. A fragment will - * be added to the path with the desired name if the desired name is different - * than the name of the provided path from the shared cache. This ensures that - * if the returned path is used to create a LocalResource, then the symlink - * created during YARN localization will match the name specified. - * - * * @param applicationId ApplicationId of the application using the resource * @param resourceKey the key (i.e. checksum) that identifies the resource - * @param resourceName the desired name of the resource - * @return Path to the resource, or null if it does not exist + * @return URL to the resource, or null if it does not exist */ @Public @Unstable - public abstract Path use(ApplicationId applicationId, String resourceKey, - String resourceName) throws YarnException; + public abstract URL use(ApplicationId applicationId, String resourceKey) + throws YarnException; /** * http://git-wip-us.apache.org/repos/asf/hadoop/blob/c114da5e/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java index b910c28..3191d36 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java @@ -21,8 +21,6 @@ package org.apache.hadoop.yarn.client.api.impl; import java.io.IOException; import
[01/26] hadoop git commit: YARN-7250. Update Shared cache client api to use URLs.
Repository: hadoop Updated Branches: refs/heads/HDFS-7240 8d5208146 -> 3bf591fd8 YARN-7250. Update Shared cache client api to use URLs. Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/5f494fc3 Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/5f494fc3 Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/5f494fc3 Branch: refs/heads/HDFS-7240 Commit: 5f494fc3d9ecbedc8999aded3acb4b9aebc9c61c Parents: 16c6299 Author: Chris TrezzoAuthored: Thu Sep 28 15:28:06 2017 -0700 Committer: Xiaoyu Yao Committed: Mon Oct 2 11:00:33 2017 -0700 -- .../yarn/client/api/SharedCacheClient.java | 22 .../client/api/impl/SharedCacheClientImpl.java | 36 +--- .../api/impl/TestSharedCacheClientImpl.java | 31 + 3 files changed, 23 insertions(+), 66 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hadoop/blob/5f494fc3/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java index 60c1bd98..a9c1a07 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java @@ -27,6 +27,7 @@ import org.apache.hadoop.classification.InterfaceStability.Unstable; import org.apache.hadoop.fs.Path; import org.apache.hadoop.service.AbstractService; import org.apache.hadoop.yarn.api.records.ApplicationId; +import org.apache.hadoop.yarn.api.records.URL; import org.apache.hadoop.yarn.client.api.impl.SharedCacheClientImpl; import org.apache.hadoop.yarn.exceptions.YarnException; @@ -58,34 +59,25 @@ public abstract class SharedCacheClient extends AbstractService { * * * The SharedCacheManager responds with whether or not the - * resource exists in the cache. If the resource exists, a Path - * to the resource in the shared cache is returned. If the resource does not + * resource exists in the cache. If the resource exists, a URL to + * the resource in the shared cache is returned. If the resource does not * exist, null is returned instead. * * * - * Once a path has been returned for a resource, that path is safe to use for + * Once a URL has been returned for a resource, that URL is safe to use for * the lifetime of the application that corresponds to the provided * ApplicationId. * * - * - * Additionally, a name for the resource should be specified. A fragment will - * be added to the path with the desired name if the desired name is different - * than the name of the provided path from the shared cache. This ensures that - * if the returned path is used to create a LocalResource, then the symlink - * created during YARN localization will match the name specified. - * - * * @param applicationId ApplicationId of the application using the resource * @param resourceKey the key (i.e. checksum) that identifies the resource - * @param resourceName the desired name of the resource - * @return Path to the resource, or null if it does not exist + * @return URL to the resource, or null if it does not exist */ @Public @Unstable - public abstract Path use(ApplicationId applicationId, String resourceKey, - String resourceName) throws YarnException; + public abstract URL use(ApplicationId applicationId, String resourceKey) + throws YarnException; /** * http://git-wip-us.apache.org/repos/asf/hadoop/blob/5f494fc3/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java index b910c28..3191d36 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java @@ -21,8 +21,6 @@ package
hadoop git commit: YARN-7250. Update Shared cache client api to use URLs.
Repository: hadoop Updated Branches: refs/heads/branch-2 11ac10fe1 -> cba1891b6 YARN-7250. Update Shared cache client api to use URLs. (cherry picked from commit c114da5e64d14b1d9e614081c4171ea0391cb1aa) Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/cba1891b Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/cba1891b Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/cba1891b Branch: refs/heads/branch-2 Commit: cba1891b61e8c049d79b110da9dd4832467a9f08 Parents: 11ac10f Author: Chris TrezzoAuthored: Thu Sep 28 15:28:06 2017 -0700 Committer: Chris Trezzo Committed: Thu Sep 28 15:32:18 2017 -0700 -- .../yarn/client/api/SharedCacheClient.java | 22 .../client/api/impl/SharedCacheClientImpl.java | 36 +--- .../api/impl/TestSharedCacheClientImpl.java | 31 + 3 files changed, 23 insertions(+), 66 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hadoop/blob/cba1891b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java index 60c1bd98..a9c1a07 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java @@ -27,6 +27,7 @@ import org.apache.hadoop.classification.InterfaceStability.Unstable; import org.apache.hadoop.fs.Path; import org.apache.hadoop.service.AbstractService; import org.apache.hadoop.yarn.api.records.ApplicationId; +import org.apache.hadoop.yarn.api.records.URL; import org.apache.hadoop.yarn.client.api.impl.SharedCacheClientImpl; import org.apache.hadoop.yarn.exceptions.YarnException; @@ -58,34 +59,25 @@ public abstract class SharedCacheClient extends AbstractService { * * * The SharedCacheManager responds with whether or not the - * resource exists in the cache. If the resource exists, a Path - * to the resource in the shared cache is returned. If the resource does not + * resource exists in the cache. If the resource exists, a URL to + * the resource in the shared cache is returned. If the resource does not * exist, null is returned instead. * * * - * Once a path has been returned for a resource, that path is safe to use for + * Once a URL has been returned for a resource, that URL is safe to use for * the lifetime of the application that corresponds to the provided * ApplicationId. * * - * - * Additionally, a name for the resource should be specified. A fragment will - * be added to the path with the desired name if the desired name is different - * than the name of the provided path from the shared cache. This ensures that - * if the returned path is used to create a LocalResource, then the symlink - * created during YARN localization will match the name specified. - * - * * @param applicationId ApplicationId of the application using the resource * @param resourceKey the key (i.e. checksum) that identifies the resource - * @param resourceName the desired name of the resource - * @return Path to the resource, or null if it does not exist + * @return URL to the resource, or null if it does not exist */ @Public @Unstable - public abstract Path use(ApplicationId applicationId, String resourceKey, - String resourceName) throws YarnException; + public abstract URL use(ApplicationId applicationId, String resourceKey) + throws YarnException; /** * http://git-wip-us.apache.org/repos/asf/hadoop/blob/cba1891b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java index b910c28..3191d36 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java +++
hadoop git commit: YARN-7250. Update Shared cache client api to use URLs.
Repository: hadoop Updated Branches: refs/heads/branch-3.0 a6630f703 -> 3d2352211 YARN-7250. Update Shared cache client api to use URLs. (cherry picked from commit c114da5e64d14b1d9e614081c4171ea0391cb1aa) Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/3d235221 Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/3d235221 Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/3d235221 Branch: refs/heads/branch-3.0 Commit: 3d235221106bd1ff2d99f660e89c6f3306f578ad Parents: a6630f7 Author: Chris TrezzoAuthored: Thu Sep 28 15:28:06 2017 -0700 Committer: Chris Trezzo Committed: Thu Sep 28 15:31:23 2017 -0700 -- .../yarn/client/api/SharedCacheClient.java | 22 .../client/api/impl/SharedCacheClientImpl.java | 36 +--- .../api/impl/TestSharedCacheClientImpl.java | 31 + 3 files changed, 23 insertions(+), 66 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hadoop/blob/3d235221/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java index 60c1bd98..a9c1a07 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java @@ -27,6 +27,7 @@ import org.apache.hadoop.classification.InterfaceStability.Unstable; import org.apache.hadoop.fs.Path; import org.apache.hadoop.service.AbstractService; import org.apache.hadoop.yarn.api.records.ApplicationId; +import org.apache.hadoop.yarn.api.records.URL; import org.apache.hadoop.yarn.client.api.impl.SharedCacheClientImpl; import org.apache.hadoop.yarn.exceptions.YarnException; @@ -58,34 +59,25 @@ public abstract class SharedCacheClient extends AbstractService { * * * The SharedCacheManager responds with whether or not the - * resource exists in the cache. If the resource exists, a Path - * to the resource in the shared cache is returned. If the resource does not + * resource exists in the cache. If the resource exists, a URL to + * the resource in the shared cache is returned. If the resource does not * exist, null is returned instead. * * * - * Once a path has been returned for a resource, that path is safe to use for + * Once a URL has been returned for a resource, that URL is safe to use for * the lifetime of the application that corresponds to the provided * ApplicationId. * * - * - * Additionally, a name for the resource should be specified. A fragment will - * be added to the path with the desired name if the desired name is different - * than the name of the provided path from the shared cache. This ensures that - * if the returned path is used to create a LocalResource, then the symlink - * created during YARN localization will match the name specified. - * - * * @param applicationId ApplicationId of the application using the resource * @param resourceKey the key (i.e. checksum) that identifies the resource - * @param resourceName the desired name of the resource - * @return Path to the resource, or null if it does not exist + * @return URL to the resource, or null if it does not exist */ @Public @Unstable - public abstract Path use(ApplicationId applicationId, String resourceKey, - String resourceName) throws YarnException; + public abstract URL use(ApplicationId applicationId, String resourceKey) + throws YarnException; /** * http://git-wip-us.apache.org/repos/asf/hadoop/blob/3d235221/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java index b910c28..3191d36 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java +++
hadoop git commit: YARN-7250. Update Shared cache client api to use URLs.
Repository: hadoop Updated Branches: refs/heads/trunk 6f789fe05 -> c114da5e6 YARN-7250. Update Shared cache client api to use URLs. Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/c114da5e Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/c114da5e Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/c114da5e Branch: refs/heads/trunk Commit: c114da5e64d14b1d9e614081c4171ea0391cb1aa Parents: 6f789fe Author: Chris TrezzoAuthored: Thu Sep 28 15:28:06 2017 -0700 Committer: Chris Trezzo Committed: Thu Sep 28 15:28:06 2017 -0700 -- .../yarn/client/api/SharedCacheClient.java | 22 .../client/api/impl/SharedCacheClientImpl.java | 36 +--- .../api/impl/TestSharedCacheClientImpl.java | 31 + 3 files changed, 23 insertions(+), 66 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hadoop/blob/c114da5e/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java index 60c1bd98..a9c1a07 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/SharedCacheClient.java @@ -27,6 +27,7 @@ import org.apache.hadoop.classification.InterfaceStability.Unstable; import org.apache.hadoop.fs.Path; import org.apache.hadoop.service.AbstractService; import org.apache.hadoop.yarn.api.records.ApplicationId; +import org.apache.hadoop.yarn.api.records.URL; import org.apache.hadoop.yarn.client.api.impl.SharedCacheClientImpl; import org.apache.hadoop.yarn.exceptions.YarnException; @@ -58,34 +59,25 @@ public abstract class SharedCacheClient extends AbstractService { * * * The SharedCacheManager responds with whether or not the - * resource exists in the cache. If the resource exists, a Path - * to the resource in the shared cache is returned. If the resource does not + * resource exists in the cache. If the resource exists, a URL to + * the resource in the shared cache is returned. If the resource does not * exist, null is returned instead. * * * - * Once a path has been returned for a resource, that path is safe to use for + * Once a URL has been returned for a resource, that URL is safe to use for * the lifetime of the application that corresponds to the provided * ApplicationId. * * - * - * Additionally, a name for the resource should be specified. A fragment will - * be added to the path with the desired name if the desired name is different - * than the name of the provided path from the shared cache. This ensures that - * if the returned path is used to create a LocalResource, then the symlink - * created during YARN localization will match the name specified. - * - * * @param applicationId ApplicationId of the application using the resource * @param resourceKey the key (i.e. checksum) that identifies the resource - * @param resourceName the desired name of the resource - * @return Path to the resource, or null if it does not exist + * @return URL to the resource, or null if it does not exist */ @Public @Unstable - public abstract Path use(ApplicationId applicationId, String resourceKey, - String resourceName) throws YarnException; + public abstract URL use(ApplicationId applicationId, String resourceKey) + throws YarnException; /** * http://git-wip-us.apache.org/repos/asf/hadoop/blob/c114da5e/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java -- diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java index b910c28..3191d36 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java/org/apache/hadoop/yarn/client/api/impl/SharedCacheClientImpl.java @@ -21,8 +21,6 @@ package