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

Intermittent failure of SearchElasticsearchTest in GitHub Actions

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

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 1.16.0
    • 1.16.0
    • None
    • None

    Description

      The SearchElasticsearchTest has been seen to occasionally fail when running in GitHub Actions against unrelated PRs.

      On investigation, this appears likely to be an issue with timing between waiting for processor runs to complete, reaching the configured expiration of a paged query that is stored in processor LOCAL state and the subsequent further execution of the same processor.

      See https://github.com/apache/nifi/runs/5382550163?check_suite_focus=true as an example.

      Error:  Tests run: 21, Failures: 2, Errors: 0, Skipped: 0, Time elapsed: 3.256 s <<< FAILURE! - in org.apache.nifi.processors.elasticsearch.SearchElasticsearchTest
      Error:  org.apache.nifi.processors.elasticsearch.SearchElasticsearchTest.testSearchAfterExpiration  Time elapsed: 1 s  <<< FAILURE!
      org.opentest4j.AssertionFailedError: Expected attribute page.number to be 1 but instead it was 2 ==> expected: <1> but was: <2>
      	at org.apache.nifi.processors.elasticsearch.SearchElasticsearchTest.testPaginationExpiration(SearchElasticsearchTest.groovy:117)
      	at org.apache.nifi.processors.elasticsearch.SearchElasticsearchTest.testSearchAfterExpiration(SearchElasticsearchTest.groovy:86)
      
      Error:  org.apache.nifi.processors.elasticsearch.SearchElasticsearchTest.testScrollExpiration  Time elapsed: 1.016 s  <<< FAILURE!
      org.opentest4j.AssertionFailedError: Expected attribute page.number to be 1 but instead it was 2 ==> expected: <1> but was: <2>
      	at org.apache.nifi.processors.elasticsearch.SearchElasticsearchTest.testPaginationExpiration(SearchElasticsearchTest.groovy:117)
      	at org.apache.nifi.processors.elasticsearch.SearchElasticsearchTest.testScrollExpiration(SearchElasticsearchTest.groovy:76)
      

      Notably, this tests works most of the time and even in the linked run above the, one of the three tests that use the same code worked without issue.

      Attachments

        Activity

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

          People

            Chris S Chris Sampson
            Chris S Chris Sampson
            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 - 20m
              20m

              Slack

                Issue deployment