Package org.apache.spark.util
Class DependencyUtils
Object
org.apache.spark.util.DependencyUtils
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionstatic voidaddJarsToClassPath(String jars, MutableURLClassLoader loader) static voidaddJarToClasspath(String localJar, MutableURLClassLoader loader) static StringdownloadFile(String path, File targetDir, SparkConf sparkConf, org.apache.hadoop.conf.Configuration hadoopConf) Download a file from the remote to a local temporary directory.static StringdownloadFileList(String fileList, File targetDir, SparkConf sparkConf, org.apache.hadoop.conf.Configuration hadoopConf) Download a list of remote files to temp local files.static org.apache.spark.util.IvyPropertiesstatic org.apache.spark.internal.Logging.LogStringContextLogStringContext(scala.StringContext sc) static StringmergeFileLists(scala.collection.immutable.Seq<String> lists) Merge a sequence of comma-separated file lists, some of which may be null to indicate no files, into a single comma-separated string.static org.slf4j.Loggerstatic voidorg$apache$spark$internal$Logging$$log__$eq(org.slf4j.Logger x$1) static StringresolveAndDownloadJars(String jars, String userJar, SparkConf sparkConf, org.apache.hadoop.conf.Configuration hadoopConf) static StringresolveGlobPaths(String paths, org.apache.hadoop.conf.Configuration hadoopConf) static scala.collection.immutable.Seq<String>resolveMavenDependencies(boolean packagesTransitive, String packagesExclusions, String packages, String repositories, String ivyRepoPath, scala.Option<String> ivySettingsPath) static scala.collection.immutable.Seq<String>Download Ivy URI's dependency jars.
- 
Constructor Details- 
DependencyUtilspublic DependencyUtils()
 
- 
- 
Method Details- 
getIvyPropertiespublic static org.apache.spark.util.IvyProperties getIvyProperties()
- 
resolveMavenDependenciesDownload Ivy URI's dependency jars.- Parameters:
- uri- Ivy URI need to be downloaded. The URI format should be:- ivy://group:module:version[?query]Ivy URI query part format should be:- parameter=value¶meter=value...Note that currently Ivy URI query part support two parameters: 1. transitive: whether to download dependent jars related to your Ivy URI. transitive=false or- transitive=true, if not set, the default value is true. 2. exclude: exclusion list when download Ivy URI jar and dependency jars. The- excludeparameter content is a ',' separated- group:modulepair string :- exclude=group:module,group:module...
- Returns:
- List of jars downloaded.
 
- 
resolveMavenDependencies
- 
resolveAndDownloadJars
- 
addJarsToClassPath
- 
downloadFileListpublic static String downloadFileList(String fileList, File targetDir, SparkConf sparkConf, org.apache.hadoop.conf.Configuration hadoopConf) Download a list of remote files to temp local files. If the file is local, the original file will be returned.- Parameters:
- fileList- A comma separated file list.
- targetDir- A temporary directory for which downloaded files.
- sparkConf- Spark configuration.
- hadoopConf- Hadoop configuration.
- Returns:
- A comma separated local files list.
 
- 
downloadFilepublic static String downloadFile(String path, File targetDir, SparkConf sparkConf, org.apache.hadoop.conf.Configuration hadoopConf) Download a file from the remote to a local temporary directory. If the input path points to a local path, returns it with no operation.- Parameters:
- path- A file path from where the files will be downloaded.
- targetDir- A temporary directory for which downloaded files.
- sparkConf- Spark configuration.
- hadoopConf- Hadoop configuration.
- Returns:
- Path to the local file.
 
- 
resolveGlobPaths
- 
addJarToClasspath
- 
mergeFileListsMerge a sequence of comma-separated file lists, some of which may be null to indicate no files, into a single comma-separated string.- Parameters:
- lists- (undocumented)
- Returns:
- (undocumented)
 
- 
org$apache$spark$internal$Logging$$log_public static org.slf4j.Logger org$apache$spark$internal$Logging$$log_()
- 
org$apache$spark$internal$Logging$$log__$eqpublic static void org$apache$spark$internal$Logging$$log__$eq(org.slf4j.Logger x$1) 
- 
LogStringContextpublic static org.apache.spark.internal.Logging.LogStringContext LogStringContext(scala.StringContext sc) 
 
-