You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Piotr Nowojski (Jira)" <ji...@apache.org> on 2022/11/22 16:59:00 UTC

[jira] [Created] (FLINK-30155) Pretty print MutatedConfigurationException

Piotr Nowojski created FLINK-30155:
--------------------------------------

             Summary: Pretty print MutatedConfigurationException
                 Key: FLINK-30155
                 URL: https://issues.apache.org/jira/browse/FLINK-30155
             Project: Flink
          Issue Type: New Feature
          Components: API / DataStream
    Affects Versions: 1.17.0
            Reporter: Piotr Nowojski
            Assignee: Piotr Nowojski
             Fix For: 1.17.0


Currently MutatedConfigurationException is printed as:

{noformat}
    org.apache.flink.client.program.MutatedConfigurationException: Configuration execution.sorted-inputs.enabled:true not allowed.
    Configuration execution.runtime-mode was changed from STREAMING to BATCH.
    Configuration execution.checkpointing.interval:500 ms not allowed in the configuration object CheckpointConfig.
    Configuration execution.checkpointing.mode:EXACTLY_ONCE not allowed in the configuration object CheckpointConfig.
    Configuration pipeline.max-parallelism:1024 not allowed in the configuration object ExecutionConfig.
    Configuration parallelism.default:25 not allowed in the configuration object ExecutionConfig.
            at org.apache.flink.client.program.StreamContextEnvironment.checkNotAllowedConfigurations(StreamContextEnvironment.java:235)
            at org.apache.flink.client.program.StreamContextEnvironment.executeAsync(StreamContextEnvironment.java:175)
            at org.apache.flink.client.program.StreamContextEnvironment.execute(StreamContextEnvironment.java:115)
            at org.apache.flink.streaming.api.environment.StreamExecutionEnvironment.execute(StreamExecutionEnvironment.java:2049)
            at org.apache.flink.streaming.api.environment.StreamExecutionEnvironment.execute(StreamExecutionEnvironment.java:2027)
{noformat}
Which is slightly confusing. First not allowed configuration is listed in the same line as the exception name, which (especially if wrapped) can make it more difficult than necessary for user to understand that this is a list of violations. I'm proposing to change it to:
{noformat}
    org.apache.flink.client.program.MutatedConfigurationException: Not allowed configuration change(s) were detected:
     - Configuration execution.sorted-inputs.enabled:true not allowed.
     - Configuration execution.runtime-mode was changed from STREAMING to BATCH.
     - Configuration execution.checkpointing.interval:500 ms not allowed in the configuration object CheckpointConfig.
     - Configuration execution.checkpointing.mode:EXACTLY_ONCE not allowed in the configuration object CheckpointConfig.
     - Configuration pipeline.max-parallelism:1024 not allowed in the configuration object ExecutionConfig.
     - Configuration parallelism.default:25 not allowed in the configuration object ExecutionConfig.
            at org.apache.flink.client.program.StreamContextEnvironment.checkNotAllowedConfigurations(StreamContextEnvironment.java:235)
            at org.apache.flink.client.program.StreamContextEnvironment.executeAsync(StreamContextEnvironment.java:175)
            at org.apache.flink.client.program.StreamContextEnvironment.execute(StreamContextEnvironment.java:115)
            at org.apache.flink.streaming.api.environment.StreamExecutionEnvironment.execute(StreamExecutionEnvironment.java:2049)
            at org.apache.flink.streaming.api.environment.StreamExecutionEnvironment.execute(StreamExecutionEnvironment.java:2027)
{noformat} 
To make it more clear.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)