Github user andrewor14 commented on a diff in the pull request:

    https://github.com/apache/spark/pull/718#discussion_r13630671
  
    --- Diff: 
core/src/main/scala/org/apache/spark/deploy/history/HistoryServerArguments.scala
 ---
    @@ -45,32 +42,34 @@ private[spark] class HistoryServerArguments(args: 
Array[String]) {
           case _ =>
             printUsageAndExit(1)
         }
    -    validateLogDir()
    -  }
    -
    -  private def validateLogDir() {
    -    if (logDir == "") {
    -      System.err.println("Logging directory must be specified.")
    -      printUsageAndExit(1)
    -    }
    -    val fileSystem = Utils.getHadoopFileSystem(new URI(logDir))
    -    val path = new Path(logDir)
    -    if (!fileSystem.exists(path)) {
    -      System.err.println("Logging directory specified does not exist: 
%s".format(logDir))
    -      printUsageAndExit(1)
    -    }
    -    if (!fileSystem.getFileStatus(path).isDir) {
    -      System.err.println("Logging directory specified is not a directory: 
%s".format(logDir))
    -      printUsageAndExit(1)
    +    if (logDir != null) {
    +      conf.set("spark.history.fs.logDirectory", logDir)
         }
       }
     
       private def printUsageAndExit(exitCode: Int) {
         System.err.println(
    -      "Usage: HistoryServer [options]\n" +
    -      "\n" +
    -      "Options:\n" +
    -      "  -d DIR,  --dir DIR     Location of event log files")
    +      """
    +      |Usage: HistoryServer
    +      |
    +      |Configuration options can be set by setting the corresponding JVM 
system property.
    +      |History Server options are always available; additional options 
depend on the provider.
    +      |
    +      |History Server options:
    +      |
    +      |  spark.history.ui.port      Port where server will listen for 
connections (default 18080)
    +      |  spark.history.acls.enable  Whether to enable view acls for all 
applications (default false)
    +      |  spark.history.provider     Name of history provider class 
(defaults to file system-based
    +      |                             provider)
    +      |  spark.history.retainedApplications Max number of application UIs 
to keep loaded in memory
    +      |                             (default 50)
    --- End diff --
    
    minor: indentation is off. Could you align the other config descriptions 
with that of `spark.history.retainedApplications`?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to