Uploaded image for project: 'Flume'
  1. Flume
  2. FLUME-1788

Flume Thrift source can fail intermittently because of a race condition in Thrift server implementation on some Linux systems

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.3.0
    • Fix Version/s: 1.4.0, 1.3.1
    • Component/s: Test
    • Labels:
      None
    • Environment:

      RHEL 5.x based systems, some SUSE versions

      Description

      While running the Flume unit tests, I observed that under some Linux environments (RHEL 5.x based etc), the Flume thrift source tests were timing out. This is because of a race condition in TThreadPoolServer used by Flume and speicifically in the testlifecycle. I have created a JIRA issue on Thrift regarding this[1]. I have creaed this issue, just so that we cross reference it here.

      [1] THRIFT-1795 - Race condition in TThreadedServerPool java implementation,

      1. Flume-1788.patch
        0.7 kB
        Venkat Ranganathan

        Issue Links

          Activity

          Hide
          brocknoland Brock Noland added a comment -

          Venkat, thank you for the report! Can you confirm, as a work around, if we put a sleep in the unit before using the TThreadPoolServer, does that resolve the issue?

          Show
          brocknoland Brock Noland added a comment - Venkat, thank you for the report! Can you confirm, as a work around, if we put a sleep in the unit before using the TThreadPoolServer, does that resolve the issue?
          Hide
          venkatnrangan Venkat Ranganathan added a comment -

          Yes, I tried with a sleep in the test and it helps Attached is the patch. BTW I discovered couple of other testing issues which made debugging this much harder than it needs to be I will create additional JIRAs for them

          Thanks

          Venkat

          Show
          venkatnrangan Venkat Ranganathan added a comment - Yes, I tried with a sleep in the test and it helps Attached is the patch. BTW I discovered couple of other testing issues which made debugging this much harder than it needs to be I will create additional JIRAs for them Thanks Venkat
          Hide
          brocknoland Brock Noland added a comment -

          I committed this patch to trunk and 1.4, then cloned the issue to track the upgrade of Thrift once that issue is fixed.

          Thank you for your contribution Vankat!

          Show
          brocknoland Brock Noland added a comment - I committed this patch to trunk and 1.4, then cloned the issue to track the upgrade of Thrift once that issue is fixed. Thank you for your contribution Vankat!
          Hide
          hudson Hudson added a comment -

          Integrated in flume-trunk #343 (See https://builds.apache.org/job/flume-trunk/343/)
          FLUME-1788: Flume Thrift source can fail intermittently because of a race condition in Thrift server implementation on some Linux systems (Revision bc5d2908fe64c9f1a7b7d10c34144badb9befe77)

          Result = SUCCESS
          brock : http://git-wip-us.apache.org/repos/asf/flume/repo?p=flume.git&a=commit&h=bc5d2908fe64c9f1a7b7d10c34144badb9befe77
          Files :

          • flume-ng-legacy-sources/flume-thrift-source/src/test/java/org/apache/flume/source/thriftLegacy/TestThriftLegacySource.java
          Show
          hudson Hudson added a comment - Integrated in flume-trunk #343 (See https://builds.apache.org/job/flume-trunk/343/ ) FLUME-1788 : Flume Thrift source can fail intermittently because of a race condition in Thrift server implementation on some Linux systems (Revision bc5d2908fe64c9f1a7b7d10c34144badb9befe77) Result = SUCCESS brock : http://git-wip-us.apache.org/repos/asf/flume/repo?p=flume.git&a=commit&h=bc5d2908fe64c9f1a7b7d10c34144badb9befe77 Files : flume-ng-legacy-sources/flume-thrift-source/src/test/java/org/apache/flume/source/thriftLegacy/TestThriftLegacySource.java

            People

            • Assignee:
              venkatnrangan Venkat Ranganathan
              Reporter:
              venkatnrangan Venkat Ranganathan
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development