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

GenerateTableFetch can't fetch column type by state after instance reboot

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.6.0
    • None
    • None

    Description

      The problem can easily be reproduce.
      Once GenerateTableFetch store state and encounter NiFi instance reboot.
      (Dynamic naming table by expression language)
      The exception will occur.

      The error in source code is list below.

      ```
      if (type == null)

      { // This shouldn't happen as we are populating columnTypeMap when the processor is scheduled or when the first maximum is observed throw new IllegalArgumentException("No column type found for: " + colName); }

      ```

      When this situation happened. The FlowFile will also be grab and can't release or observed.
      Processor can't grab existing column type from columnTypeMap through instance reboot.
      Hence will inevidible get this exception, rollback FlowFile and never success.

      QueryDatabaseTable processor will not encounter this exception due to it setup(context) every time,
      While GenerateTableFetch will not pass the condition and thus try to fetch column type from 0 length columnTypeMap.


      if (!isDynamicTableName && !isDynamicMaxValues)

      { super.setup(context); }

      I can take the issue if it is recognize as bug.

      Attachments

        Activity

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

          People

            deonashh Deon Huang
            deonashh Deon Huang
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment