Details

      Description

      I did a little investigation and I think I found out why:
      The problem seems to be in the private method
      DefaultOsgiUtilsService.waitForServiceFromTracker(ServiceTracker, long)

      It does the following to the tracker:
      tracker.open()
      tracker.waitforService()
      tracker.close()

      Now two threads do this concurrently this might fail:
      T1: tracker.open()
      T2: tracker.open()
      T1: tracker.waitforService()
      T1: tracker.cose()
      T2: tracker.waitforService() -> returns null

      The question is, what do we do about it.
      I think this is an actual problem (not just in this test).

      I think making the function synchronized is a bad solution.
      I thought we could just skip closing the tracker (tried it, and did not encounter the bug since).

        Gliffy Diagrams

        Error rendering 'com.meetme.plugins.jira.gerrit-plugin:gerritreviewsmodule'. Please contact your JIRA administrators.

          Activity

          Christoph Gritschenberger created issue -
          Christoph Gritschenberger made changes -
          Field Original Value New Value
          Description I did a little investigation and I think I found out why:

          I did a little investigation and I think I found out why:
          The problem seems to be in the private method
          DefaultOsgiUtilsService.waitForServiceFromTracker(ServiceTracker, long)

          It does the following to the tracker:
          tracker.open()
          tracker.waitforService()
          tracker.close()

          Now two threads do this concurrently this might fail:
          T1: tracker.open()
          T2: tracker.open()
          T1: tracker.waitforService()
          T1: tracker.cose()
          T2: tracker.waitforService() -> returns null

          The question is, what do we do about it.
          I think this is an actual problem (not just in this test).

          I think making the function synchronized is a bad solution.
          I thought we could just skip closing the tracker (tried it, and did not encounter the bug since).

          Andreas Pieber made changes -
          Assignee Christoph Gritschenberger [ christophg ]
          Fix Version/s framework-2.4.3 [ 10660 ]
          Fix Version/s framework-2.5.0 [ 10596 ]
          Fix Version/s framework-3.0.0 [ 10488 ]
          Andreas Pieber made changes -
          Fix Version/s framework-2.4.4 [ 10761 ]
          Fix Version/s framework-2.4.3 [ 10660 ]
          Andreas Pieber made changes -
          Fix Version/s framework-2.4.5 [ 10764 ]
          Fix Version/s framework-2.4.4 [ 10761 ]
          Andreas Pieber made changes -
          Fix Version/s framework-2.5.1 [ 10771 ]
          Fix Version/s framework-2.6.0 [ 10763 ]
          Fix Version/s framework-2.4.5 [ 10764 ]
          Fix Version/s framework-2.5.0 [ 10596 ]
          Christoph Gritschenberger made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Christoph Gritschenberger made changes -
          Fix Version/s framework-2.4.5 [ 10764 ]
          Fix Version/s framework-2.5.0 [ 10596 ]
          Fix Version/s framework-2.6.0 [ 10763 ]
          Fix Version/s framework-2.5.1 [ 10771 ]
          Christoph Gritschenberger made changes -
          Status Resolved [ 5 ] Closed [ 6 ]
          Andreas Pieber made changes -
          Workflow jira [ 12514 ] OpenEngSB Workflow [ 16932 ]
          Andreas Pieber made changes -
          Labels archived
          Stefan Scheiber made changes -
          Workflow OpenEngSB Workflow [ 16932 ] OpenEngSB 2 Workflow [ 21702 ]
          Stefan Scheiber made changes -
          Fix Version/s openengsb-3.0.0 [ 10169 ]
          Fix Version/s framework-3.0.0 [ 10488 ]
          Fix Version/s framework-2.5.0 [ 10596 ]
          Fix Version/s framework-2.4.5 [ 10764 ]
          Stefan Scheiber made changes -
          Fix Version/s openengsb-3.0.0.M1 [ 11164 ]
          Fix Version/s openengsb-3.0.0 [ 10169 ]

            People

            • Assignee:
              Christoph Gritschenberger
              Reporter:
              Christoph Gritschenberger
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: