Uploaded image for project: 'Qpid'
  1. Qpid
  2. QPID-6014

[Java] Declare variables as ConcurrentMap not ConcurrentHashMap to avoid issues afetr compiling on Java 8

    XMLWordPrintableJSON

    Details

      Description

      Java 8 redefines the method keySet() on ConcurrentHashMap to return a narrower type than the standard return type given in the Map interface. If the code is compiled in Java 8 and then run under Java 7 this causes linking issues.

      Avoid these issues by always declaring variables in terms of the interface ConcurrentMap

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                macbean Andrew MacBean
                Reporter:
                rgodfrey Robert Godfrey
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: