Github user dongjoon-hyun commented on a diff in the pull request:

    https://github.com/apache/spark/pull/11994#discussion_r126277662
  
    --- Diff: core/src/main/scala/org/apache/spark/metrics/sink/Slf4jSink.scala 
---
    @@ -26,29 +26,29 @@ import org.apache.spark.SecurityManager
     import org.apache.spark.metrics.MetricsSystem
     
     private[spark] class Slf4jSink(
    -    val property: Properties,
    -    val registry: MetricRegistry,
    +    property: Properties,
    +    registry: MetricRegistry,
         securityMgr: SecurityManager)
    -  extends Sink {
    +  extends Sink(property, registry) {
       val SLF4J_DEFAULT_PERIOD = 10
       val SLF4J_DEFAULT_UNIT = "SECONDS"
     
       val SLF4J_KEY_PERIOD = "period"
       val SLF4J_KEY_UNIT = "unit"
     
    -  val pollPeriod = Option(property.getProperty(SLF4J_KEY_PERIOD)) match {
    +  private val pollPeriod = Option(property.getProperty(SLF4J_KEY_PERIOD)) 
match {
         case Some(s) => s.toInt
         case None => SLF4J_DEFAULT_PERIOD
       }
     
    -  val pollUnit: TimeUnit = Option(property.getProperty(SLF4J_KEY_UNIT)) 
match {
    -    case Some(s) => TimeUnit.valueOf(s.toUpperCase(Locale.ROOT))
    +  private val pollUnit: TimeUnit = 
Option(property.getProperty(SLF4J_KEY_UNIT)) match {
    +    case Some(s) => TimeUnit.valueOf(s.toUpperCase())
    --- End diff --
    
    Here, too.


---
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.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to