felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Felix Meschberger (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (FELIX-3670) PackageAdmin.isBundleType throws NPE for uninstalled bundle
Date Wed, 19 Sep 2012 15:45:07 GMT

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

Felix Meschberger resolved FELIX-3670.
--------------------------------------

    Resolution: Fixed

Fixed as proposed in Rev. 1387646
                
> PackageAdmin.isBundleType throws NPE for uninstalled bundle
> -----------------------------------------------------------
>
>                 Key: FELIX-3670
>                 URL: https://issues.apache.org/jira/browse/FELIX-3670
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: framework-4.0.3
>            Reporter: Felix Meschberger
>            Assignee: Felix Meschberger
>             Fix For: framework-4.2.0
>
>
> From FELIX-3666:
> The PackageAdmin.isBundleType is defined to throw an IllegalArgumentException "If the
specified Bundle was not created by the same framework instance that registered this PackageAdmin
service". I would assume calling this method on an uninstalled bundle should just return the
information because it basically just accesses the bundle headers which must remain available
after the bundle has been uninstalled.
> In fact the PackageAdminImpl.isBundleType does
>    bundle.adapt(BundleRevision.class))
> which will return null if the bundle is uninstalled. Instead it should do
>    bundle.adapt(BundleRevisionImpl.class))
> which never returns null and thus still provides access to the headers. 

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message