Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-5342

Shaded concurrentlinkedhashmap-lru conflicts with existing jar

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.9.2
    • Fix Version/s: 2.9.3, 2.10.0
    • Component/s: camel-core
    • Labels:
      None
    • Estimated Complexity:
      Unknown

      Description

      Package com.googlecode.concurrentlinkedhashmap:concurrentlinkedhashmap-lru is included/shaded inside the camel-core jar.

      It is not very nice if concurrentlinkedhashmap-lru.jar is already on the path. It is a deal breaker, if their versions are different. For example cassandra-1.1.1 requires ConcurrentLinkedHashMap$Builder.maximumWeightedCapacity(), which is missing from the version included in camel.

      It would be nice if concurrentlinkedhashmap-lru was included as a normal dependency. Comment in the pom.xml says "Shade the googlecode stuff for OSGi". Well, if that is strictly required, maybe it could be better included in camel-core-osgi package.

      In any case, if it must be shaded at all, it would be safer to use relocation property of the maven-shade-plugin. In this case, camel could stay with the version it wants, without conflicting with explicit dependencies.

        Attachments

          Activity

            People

            • Assignee:
              njiang Willem Jiang
              Reporter:
              belamiru Mikhail Moussikhine
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: