Uploaded image for project: 'Byteman'
  1. Byteman
  2. BYTEMAN-364

LinkMap API synchronizatoin windows are over-wide

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Done
    • Major
    • 3.0.12, 4.0.2
    • 3.0.11, 4.0.1
    • Rule Helpers
    • None

    Description

      The LinkMap API methods (createLinkMap, deleteLinkMap, link, linked, unlink, linkNames, linkValues, clearLinks) all perform their relevant operations synchronized on the top level HashMap that associates map names with their underlying link map. That makes the exclusion window for these operations unnecessarily wide. Worse, it causes an unnecessary exclusion bottleneck between threads operating on independent link maps.

      The outer HashMap would be better replaced with a ConncurrentHashMap, allowing linkmap create, lookup and delete operations to operate with no risk of inappropriate exclusion. The LinkMap API methods will need ot be modified to synchronize on the HashMap used to model the link map being operated on. This will ensure that API methods only exclude competing threads when they operate on the same map and do so with as minimal an exclusion window as possible.

      Attachments

        Activity

          People

            rhn-engineering-adinn Andrew Dinn
            rhn-engineering-adinn Andrew Dinn
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: