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

John Ross resolved ARIES-1404.
------------------------------
    Resolution: Fixed
      Assignee: John Ross

http://svn.apache.org/viewvc?rev=1704412&view=rev

This issue can occur with an unresolved optional dependency as well as with an 
unresolved mandatory dependency in conjunction with the 
Application-ImportService header.

I added the filtering of synthetic resources to the 
computeDependencies(SubsystemManifest) method of SubsystemResource rather than 
the suggested location in synthesized.patch because it will prevent issues with 
other current or future headers.

The patch modifications to setImportIsolationPolicy are not appropriate because 
service dependencies are already included in the wiring if the implementation 
has been made aware of them through one of the supported means which are (1) 
Require-Capability bundle headers in the osgi.service namespace, and (2) 
Blueprint XML.

I also added a dedicated test for this defect rather than including it in the 
already existing ResolutionTest as in the test-cases-1.patch of ARIES-1357.

> Restart of the osgi container does not restart subsystem core because of an 
> error related to missing resource 
> org.apache.aries.subsystem.resource.synthesized
> -------------------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: ARIES-1404
>                 URL: https://issues.apache.org/jira/browse/ARIES-1404
>             Project: Aries
>          Issue Type: Bug
>          Components: Subsystem
>    Affects Versions: subsystem-2.0.3
>         Environment: On karaf 4 with subsystem-2.0.3-SNAPSHOT revision 1702099
>            Reporter: Bas
>            Assignee: John Ross
>              Labels: patch
>         Attachments: ProvisionResourceSynthesized.patch, 
> provision-resource-synth.zip, synthesized.patch
>
>
> Restart of the osgi container does not restart subsystem core because of an 
> error related to missing resource 
> org.apache.aries.subsystem.resource.synthesized
> The deployment manifest contains the entry below in the provision-resource 
> header:
> org.apache.aries.subsystem.resource.synthesized;resourceId=-1;deployed-version=0.0.0;type=org.apache.aries.subsystem.resource.synthesized
> On restart it tries to load the resource because it is in the deployment 
> manifest and can't find the resource in the osgi framework. 
> It seems the 'synthesized' type is related to something which looks like a 
> missing capability/service capability placeholder while installing/resolving. 
> It is not installed because the ResourceInstaller has an if statement 
> returning an installer which does nothing. So I guess it should also not be 
> added to the manifest.
> I therefore patched the ProvisionResourceHeader to check for this 
> 'synthesized' type and ignore it for the Provision-resource header. I'm not 
> sure if this is the best solution but it does solve the issue we are having.
> The reason for patching it there is because it would be least affecting the 
> entire process. Just like ignoring it before it is installed in the osgi 
> framework it will not also be ignored before adding it to the manifest.



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

Reply via email to