spark-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrew Or (JIRA)" <>
Subject [jira] [Resolved] (SPARK-12887) Do not expose var's in TaskMetrics
Date Tue, 19 Jan 2016 18:58:39 GMT


Andrew Or resolved SPARK-12887.
       Resolution: Fixed
    Fix Version/s: 2.0.0

> Do not expose var's in TaskMetrics
> ----------------------------------
>                 Key: SPARK-12887
>                 URL:
>             Project: Spark
>          Issue Type: Sub-task
>          Components: Spark Core
>            Reporter: Andrew Or
>            Assignee: Andrew Or
>             Fix For: 2.0.0
> TaskMetrics has a bunch of var's, some are fully public, some are private[spark]. This
is bad coding style that makes it easy to accidentally overwrite previously set metrics. This
has happened a few times in the past and caused bugs that were difficult to debug.
> Instead, we should have get-or-create semantics, which are more readily understandable.
This makes sense in the case of TaskMetrics because these are just aggregated metrics that
we want to collect throughout the task, so it doesn't matter *who*'s incrementing them.

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message