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

Unable to set indefinite max wait time on DBCPConnectionPool

Agile BoardAttach filesAttach ScreenshotVotersStop watchingWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.7.1
    • 1.8.0
    • Extensions
    • None
    • macOS, Java 8

    Description

      The DBCPConnectionPool controller service accepts a "Max Wait Time" that configures 

      The maximum amount of time that the pool will wait (when there are no available connections) for a connection to be returned before failing, or -1 to wait indefinitely.

      This value must validate as a time period. There is no valid way to set -1 with the current validator.

      The validator in use is StandardValidators.TIME_PERIOD_VALIDATOR. The TIME_PERIOD_VALIDATOR uses a regex built in FormatUtils that must have a time unit:

      public static final String TIME_DURATION_REGEX = "(\\d+)\\s*(" + VALID_TIME_UNITS + ")";
      

      The regex does not allow for an value such as -1 or -1 secs, etc.

      The obvious workaround is to set that very high.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            pvillard Pierre Villard
            colindean Colin Dean
            Votes:
            0 Vote for this issue
            Watchers:
            3 Stop watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment