Uploaded image for project: 'Apache NiFi'
  1. Apache NiFi
  2. NIFI-716

Framework allows you to define two properties with the same name

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 0.1.0
    • None
    • Core Framework

    Description

      If you are lazy and copy and paste a PropertyDescriptor and forget to change the value assigned to name(), the framework(test or regular) does not detect this and proceeds happily.

      It would be great if this situation was detected as soon as possible, and either mark the processor as invalid, or fail to consider it as a possible processor.

      This applies to Processors, ControllerServices and ReportingTasks

      Example

      public static final PropertyDescriptor MIN_SIZE = new PropertyDescriptor.Builder()
      .name("Minimum Group Size")
      .description("The minimum size of for the bundle")
      .required(true)
      .defaultValue("0 B")
      .addValidator(StandardValidators.DATA_SIZE_VALIDATOR)
      .build();
      
      public static final PropertyDescriptor MAX_SIZE = new PropertyDescriptor.Builder()
      .name("Minimum Group Size")
      .description("The maximum size for the bundle. If not specified, there is no maximum.")
      .required(false)
      .addValidator(StandardValidators.DATA_SIZE_VALIDATOR)
      .build();
      

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              danbress Dan Bress
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated: