Uploaded image for project: 'UIMA'
  1. UIMA
  2. UIMA-3992

test case for JCasHashMap multi-threaded not reliable

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.6.0SDK
    • 2.7.0SDK
    • Core Java Framework
    • None

    Description

      There is a test in the JCasHashMapTest which runs multiple threads, and depends on sub threads running ahead of the main thread, but it uses sleep delays to attempt to achieve that. This is not reliable, in case the whole Java process is pre-empted for longer than the longer sleep. Change this to use, in addition, thread priorities - making the main thread have a lower priority than the sub-threads, so if the wait times are both expired, still the sub-thread runs before the main test thread.

      Attachments

        Activity

          People

            schor Marshall Schor
            schor Marshall Schor
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: