[ 
https://issues.apache.org/jira/browse/FLINK-1819?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14649269#comment-14649269
 ] 

ASF GitHub Bot commented on FLINK-1819:
---------------------------------------

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

    https://github.com/apache/flink/pull/966#discussion_r35977130
  
    --- Diff: 
flink-runtime/src/main/java/org/apache/flink/runtime/operators/DataSourceTask.java
 ---
    @@ -75,6 +78,13 @@
        // cancel flag
        private volatile boolean taskCanceled = false;
     
    +   /**
    +    * The accumulator map used in the RuntimeContext.
    +    */
    +   protected Map<String, Accumulator<?,?>> accumulatorMap;
    --- End diff --
    
    This field should be final. Or you get rid of the field and just access the 
accumulators via `getEnvironment().getAccumulatorRegistry().getUserMap()`.


> Allow access to RuntimeContext from Input and OutputFormats
> -----------------------------------------------------------
>
>                 Key: FLINK-1819
>                 URL: https://issues.apache.org/jira/browse/FLINK-1819
>             Project: Flink
>          Issue Type: Improvement
>          Components: Local Runtime
>    Affects Versions: 0.9, 0.8.1
>            Reporter: Fabian Hueske
>            Priority: Minor
>             Fix For: 0.9
>
>
> User function that extend a RichFunction can access a {{RuntimeContext}} 
> which gives the parallel id of the task and access to Accumulators and 
> BroadcastVariables. 
> Right now, Input and OutputFormats cannot access their {{RuntimeContext}}.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to