[ 
https://issues.apache.org/jira/browse/ARIES-1650?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Wouter Bancken updated ARIES-1650:
----------------------------------
    Description: 
The ESA Maven plugin currently includes artifacts in the ESA Archive regardless 
of whether these artifacts are OSGi bundles. Non-bundle artifacts included in 
the ESA Archive cause issues while installing the subsystem. 

The ESA Maven Plugin should be adapted to either log warnings or fail when 
trying to include a non-bundle artifact in the archive. Detecting whether an 
artifact is a bundle can be done by checking if the Bundle-SymbolicName header 
is present in the manifest.

Example error when trying to install an archive containing a non-bundle 
artifact:
Caused by: java.lang.NullPointerException
        at 
org.apache.aries.subsystem.core.archive.FragmentHostCapability.initializeAttributes(FragmentHostCapability.java:38)
        at 
org.apache.aries.subsystem.core.archive.FragmentHostCapability.<init>(FragmentHostCapability.java:67)
        at 
org.apache.aries.subsystem.core.internal.BundleResource.computeOsgiWiringHostCapability(BundleResource.java:191)
        at 
org.apache.aries.subsystem.core.internal.BundleResource.computeRequirementsOtherThanService(BundleResource.java:245)
        at 
org.apache.aries.subsystem.core.internal.BundleResource.computeRequirementsAndCapabilities(BundleResource.java:216)
        at 
org.apache.aries.subsystem.core.internal.BundleResource.<init>(BundleResource.java:74)
        at 
org.apache.aries.subsystem.core.internal.RawSubsystemResource.addResource(RawSubsystemResource.java:444)
        at 
org.apache.aries.subsystem.core.internal.RawSubsystemResource.computeResources(RawSubsystemResource.java:429)
        at 
org.apache.aries.subsystem.core.internal.RawSubsystemResource.<init>(RawSubsystemResource.java:131)
        at 
org.apache.aries.subsystem.core.internal.SubsystemResource.<init>(SubsystemResource.java:90)
        at 
org.apache.aries.subsystem.core.internal.InstallAction.run(InstallAction.java:54)
        ... 37 more

  was:
The ESA Maven plugin currently includes artifacts in the ESA Archive regardless 
of whether these artifacts are OSGi bundles. Non-bundles included in the ESA 
Archive cause issues while installing the subsystem when the manifest is 
parsed. 

The ESA Maven Plugin should be adapted to either log warnings or fail when 
trying to include a non-bundle artifact in the archive. Detecting whether an 
artifact is a bundle can be done by checking if the Bundle-SymbolicName header 
is present in the manifest.

Example error when trying to install an archive containing a non-bundle 
artifact:
Caused by: java.lang.NullPointerException
        at 
org.apache.aries.subsystem.core.archive.FragmentHostCapability.initializeAttributes(FragmentHostCapability.java:38)
        at 
org.apache.aries.subsystem.core.archive.FragmentHostCapability.<init>(FragmentHostCapability.java:67)
        at 
org.apache.aries.subsystem.core.internal.BundleResource.computeOsgiWiringHostCapability(BundleResource.java:191)
        at 
org.apache.aries.subsystem.core.internal.BundleResource.computeRequirementsOtherThanService(BundleResource.java:245)
        at 
org.apache.aries.subsystem.core.internal.BundleResource.computeRequirementsAndCapabilities(BundleResource.java:216)
        at 
org.apache.aries.subsystem.core.internal.BundleResource.<init>(BundleResource.java:74)
        at 
org.apache.aries.subsystem.core.internal.RawSubsystemResource.addResource(RawSubsystemResource.java:444)
        at 
org.apache.aries.subsystem.core.internal.RawSubsystemResource.computeResources(RawSubsystemResource.java:429)
        at 
org.apache.aries.subsystem.core.internal.RawSubsystemResource.<init>(RawSubsystemResource.java:131)
        at 
org.apache.aries.subsystem.core.internal.SubsystemResource.<init>(SubsystemResource.java:90)
        at 
org.apache.aries.subsystem.core.internal.InstallAction.run(InstallAction.java:54)
        ... 37 more


> Maven plugin no longer includes non-bundle artifacts
> ----------------------------------------------------
>
>                 Key: ARIES-1650
>                 URL: https://issues.apache.org/jira/browse/ARIES-1650
>             Project: Aries
>          Issue Type: Improvement
>          Components: ESA Maven Plugin
>    Affects Versions: esa-maven-plugin-1.0.0
>            Reporter: Wouter Bancken
>
> The ESA Maven plugin currently includes artifacts in the ESA Archive 
> regardless of whether these artifacts are OSGi bundles. Non-bundle artifacts 
> included in the ESA Archive cause issues while installing the subsystem. 
> The ESA Maven Plugin should be adapted to either log warnings or fail when 
> trying to include a non-bundle artifact in the archive. Detecting whether an 
> artifact is a bundle can be done by checking if the Bundle-SymbolicName 
> header is present in the manifest.
> Example error when trying to install an archive containing a non-bundle 
> artifact:
> Caused by: java.lang.NullPointerException
>       at 
> org.apache.aries.subsystem.core.archive.FragmentHostCapability.initializeAttributes(FragmentHostCapability.java:38)
>       at 
> org.apache.aries.subsystem.core.archive.FragmentHostCapability.<init>(FragmentHostCapability.java:67)
>       at 
> org.apache.aries.subsystem.core.internal.BundleResource.computeOsgiWiringHostCapability(BundleResource.java:191)
>       at 
> org.apache.aries.subsystem.core.internal.BundleResource.computeRequirementsOtherThanService(BundleResource.java:245)
>       at 
> org.apache.aries.subsystem.core.internal.BundleResource.computeRequirementsAndCapabilities(BundleResource.java:216)
>       at 
> org.apache.aries.subsystem.core.internal.BundleResource.<init>(BundleResource.java:74)
>       at 
> org.apache.aries.subsystem.core.internal.RawSubsystemResource.addResource(RawSubsystemResource.java:444)
>       at 
> org.apache.aries.subsystem.core.internal.RawSubsystemResource.computeResources(RawSubsystemResource.java:429)
>       at 
> org.apache.aries.subsystem.core.internal.RawSubsystemResource.<init>(RawSubsystemResource.java:131)
>       at 
> org.apache.aries.subsystem.core.internal.SubsystemResource.<init>(SubsystemResource.java:90)
>       at 
> org.apache.aries.subsystem.core.internal.InstallAction.run(InstallAction.java:54)
>       ... 37 more



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to