Uploaded image for project: 'Felix'
  1. Felix
  2. FELIX-4487

On Goal MANIFEST the Dependency Version Range been not adopt to MANIFEST.MF

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • maven-bundle-plugin-2.3.7, maven-bundle-plugin-2.4.0
    • None
    • Maven Bundle Plugin
    • None

    Description

      If I define inside my pom.xml a Artifact Dependeny Version Range from 2.10.x until open end, the Manfest.mf contains a wrong range.

      mvn compile org.apache.felix:maven-bundle-plugin:manifest
      

      I expect a transformation from
      pom.xml: ...<version>[2.10,)</version>...
      to
      MANIFEST.MF: ...Import-Package: org.apache.camel;version="[2.10,3)...

      But the Plugin generat from:
      pom.xml: ...<version>[2.10,)</version>...
      to
      MANIFEST.MF: ...Import-Package: org.apache.camel;version="[2.13,3)...

      Is it a Bug? Or is it bad usage?

      oops-blueprint-example/pom.xml
      <?xml version="1.0" encoding="UTF-8"?>
      <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
      
        <modelVersion>4.0.0</modelVersion>
      
        <groupId>org.example.oops</groupId>
        <artifactId>oops-blueprint-example</artifactId>
        <packaging>bundle</packaging>
        <version>1.0-SNAPSHOT</version>
      
        <name>A Camel Blueprint Route</name>
        <url>http://www.myorganization.org</url>
      
        <properties>
          <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
          <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        </properties>
      
        <dependencies>
          <dependency>
            <groupId>org.apache.camel</groupId>
            <artifactId>camel-core</artifactId>
            <version>[2.10,)</version>
          </dependency>
          <dependency>
            <groupId>org.apache.camel</groupId>
            <artifactId>camel-blueprint</artifactId>
            <version>[2.10,)</version>
          </dependency>
                  
          <!-- logging -->
          <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>1.6.6</version>
          </dependency>
          <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-log4j12</artifactId>
            <version>1.6.6</version>
          </dependency>
          <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>jcl-over-slf4j</artifactId>
            <version>1.6.6</version>
          </dependency>
          <dependency>
            <groupId>log4j</groupId>
            <artifactId>log4j</artifactId>
            <version>1.2.17</version>
          </dependency>
      
          <!-- testing -->
          <dependency>
            <groupId>org.apache.camel</groupId>
            <artifactId>camel-test-blueprint</artifactId>
            <version>2.10.2</version>
            <scope>test</scope>
          </dependency>
        </dependencies>
      
        <build>
          <defaultGoal>install</defaultGoal>
      
          <plugins>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-compiler-plugin</artifactId>
              <version>2.5.1</version>
              <configuration>
                <source>1.6</source>
                <target>1.6</target>
              </configuration>
            </plugin>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-resources-plugin</artifactId>
              <version>2.6</version>
              <configuration>
                <encoding>UTF-8</encoding>
              </configuration>
            </plugin>
      
            <!-- to generate the MANIFEST-FILE of the bundle -->
            <plugin>
              <groupId>org.apache.felix</groupId>
              <artifactId>maven-bundle-plugin</artifactId>
              <version>2.3.7</version>
              <extensions>true</extensions>
              <configuration>
                <instructions>
                  <Bundle-SymbolicName>oops-blueprint-example</Bundle-SymbolicName>
                  <Private-Package>org.example.oops.*</Private-Package>
                  <Import-Package>*</Import-Package>
                </instructions>
              </configuration>
            </plugin>
      
             <!-- to run the example using mvn camel:run -->
            <plugin>
              <groupId>org.apache.camel</groupId>
              <artifactId>camel-maven-plugin</artifactId>
              <version>2.10.2</version>
              <configuration>
                <useBlueprint>true</useBlueprint>
              </configuration>
            </plugin>
      
          </plugins>
        </build>
      
      </project>
      
      oops-blueprint-example/target/classes/META-INF/MANIFEST:MF
      Manifest-Version: 1.0
      Bnd-LastModified: 1397570378727
      Build-Jdk: 1.7.0_45
      Built-By: Wentzlaff
      Bundle-ManifestVersion: 2
      Bundle-Name: A Camel Blueprint Route
      Bundle-SymbolicName: oops-blueprint-example
      Bundle-Version: 1.0.0.SNAPSHOT
      Created-By: Apache Maven Bundle Plugin
      Export-Package: org.example.oops;uses:="org.apache.camel";version="1.0.0
       .SNAPSHOT"
      Import-Package: org.apache.camel;version="[2.13,3)",org.osgi.service.blu
       eprint;version="[1.0.0,2.0.0)"
      Tool: Bnd-1.50.0
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            eddi888 Edgar Wentzlaff
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: