logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Asma Zinneera Jabir <azinne...@gmail.com>
Subject Plugins.dat file not packing with jar for OSGi bundle
Date Thu, 07 Sep 2017 18:11:15 GMT
I want to create an osgi bundle with custom appenders in it and tried with
creating a simple maven project. The Plugins.dat file gets packed in the
jar with the simple maven pom. When I add the apache felix plugin and
change packaging to bundle  to make it an OSGI bundle the Plugins.dat does
not get packed. The pom elements I used to convert it to an OSGI
 bundle is as below.

 <packaging>bundle</packaging>  and

<plugin>
    <groupId>org.apache.felix</groupId>
    <artifactId>maven-bundle-plugin</artifactId>
    <version>3.0.1</version>
    <extensions>true</extensions>
    <configuration>
        <instructions>
            <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
            <Bundle-Name>${project.artifactId}</Bundle-Name>
            <Bundle-Version>1.0.0</Bundle-Version>
            <Fragment-Host>com.example.host.bundle</Fragment-Host>
            <Export-Package>
                com.example.log4j2.plugins.*
            </Export-Package>
            <DynamicImport-Package>
                *;resolution:=optional
            </DynamicImport-Package>
            <Import-Package>
                !com.example.log4j2.plugins.*
            </Import-Package>
        </instructions>
    </configuration>
</plugin>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message