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

Cleanup nifi-mock dependencies

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 2.0.0-M3
    • Core Framework, Extensions
    • None

    Description

      We have allowed quite a few dependencies to creep into the nifi-mock module. It has dependencies now on nifi-utils, nifi-framework-api, nifi-parameter. These are not modules that the mock framework should depend on. We should ensure that we keep this module lean and clean.

      I suspect removing these dependencies from the mock framework will have a trickle-down effect, as most modules depend on this module, and removing these dependencies will likely require updates to modules who use these things as transitive dependencies.

      It appears that nifi-parameter is not even used, even though it's a dependency. There are two classes in nifi-utils that are in use: CoreAttributes and StandardValidators. But I argue these really should move to nifi-api, as they are APIs that are widely used and we will guarantee backward compatibility.

      Additionally, StandardValidators depends on FormatUtils. While we don't want to bring FormatUtils into nifi-api, we should introduce a new TimeFormat class in nifi-api that is responsible for parsing things like durations that our extensions use ("5 mins", etc.) This makes it simpler to build "framework-level extensions" and allows for a cleaner implementation of NiFiProperties in the future. FormatUtils should then make use of this class.

      Attachments

        Issue Links

          Activity

            People

              markap14 Mark Payne
              markap14 Mark Payne
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1.5h
                  1.5h