You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2018/03/09 15:28:00 UTC

[jira] [Commented] (FLINK-6206) Log task state transitions as warn/error for FAILURE scenarios

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

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

Github user StephanEwen commented on the issue:

    https://github.com/apache/flink/pull/5399
  
    I am unsure about this change, so let's discuss the pros and cons a bit.
    
    So far, this purposefully logs on *INFO* so far, because from the JobManager's perspective, a task failing and recovering if not an erroneous situation. It conveys the assumption that failures and recoveries are perfectly expected as part of the Job life cycle.
    
    The assumption Something that is logged on "ERROR" is something where a user may want to dig into and see whether they should do something about it.
    
    Flink does not follow this perspective perfectly in all parts, but that was the reasoning behind the fact to use *info* for these state changes.
    
    Happy to hear other thoughts on this.


> Log task state transitions as warn/error for FAILURE scenarios
> --------------------------------------------------------------
>
>                 Key: FLINK-6206
>                 URL: https://issues.apache.org/jira/browse/FLINK-6206
>             Project: Flink
>          Issue Type: Improvement
>          Components: Core
>    Affects Versions: 1.2.0
>            Reporter: Dan Bress
>            Priority: Critical
>
> If a task fails due to an exception, I would like that to be logged at a warn or an error level.  currently its info
> {code}
> private boolean transitionState(ExecutionState currentState, ExecutionState newState, Throwable cause) {
> 		if (STATE_UPDATER.compareAndSet(this, currentState, newState)) {
> 			if (cause == null) {
> 				LOG.info("{} ({}) switched from {} to {}.", taskNameWithSubtask, executionId, currentState, newState);
> 			} else {
> 				LOG.info("{} ({}) switched from {} to {}.", taskNameWithSubtask, executionId, currentState, newState, cause);
> 			}
> 			return true;
> 		} else {
> 			return false;
> 		}
> 	}
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)