Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-29124

Redundant checkNotNull in cli Package

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Not A Problem
    • None
    • None
    • Command Line Client
    • None

    Description

      Redundant NotNull checks in function cli/CliFrontend.
      getEffectiveConfiguration():

      final ExecutionConfigAccessor executionParameters =                
      ExecutionConfigAccessor.fromProgramOptions(
      checkNotNull(programOptions), checkNotNull(jobJars));
       

      while ExecutionConfigAccessor.fromProgramOptions indeed does the notNull check

      public static <T> ExecutionConfigAccessor fromProgramOptions(
                  final ProgramOptions options, 
                        final List<T> jobJars) {        
      checkNotNull(options);       
      checkNotNull(jobJars);
      ...
      } 
      
      
      

      I have searched other ExecutionConfigAccessor.fromProgramOptions() usages, and all of them do not use checkNotNull in invokion

      Attachments

        Activity

          People

            Unassigned Unassigned
            floudk ivan Qing
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: