karaf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Laszlo Papp (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (KARAF-4700) Overrides and blacklist do not work by default and produce an exception
Date Fri, 03 Nov 2017 14:43:00 GMT

    [ https://issues.apache.org/jira/browse/KARAF-4700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16237680#comment-16237680

Laszlo Papp commented on KARAF-4700:

Thank you for the workaround and fix.

> Overrides and blacklist do not work by default and produce an exception
> -----------------------------------------------------------------------
>                 Key: KARAF-4700
>                 URL: https://issues.apache.org/jira/browse/KARAF-4700
>             Project: Karaf
>          Issue Type: Bug
>            Reporter: Fabian Lange
>            Assignee: Guillaume Nodet
>            Priority: Major
>             Fix For: 4.1.0
> The FeaturesServiceImpl supports overrides and blacklist.
> They are configured in the Activator:
> https://github.com/apache/karaf/blob/791ebb5f908e27fa389616c8bba456cf85807f4d/features/core/src/main/java/org/apache/karaf/features/internal/osgi/Activator.java#L175
> If not configured they will default to a file which is not existing in the distribution
by default:
>         String overrides = getString("overrides", new File(System.getProperty("karaf.etc"),
>         String blacklisted = getString("blacklisted", new File(System.getProperty("karaf.etc"),
> This causes Exceptions later down the line, e.g. here: 
> https://github.com/apache/karaf/blob/b8c2617c278bb899c0af2ea1a8d2dc987f22f1cb/features/core/src/main/java/org/apache/karaf/features/internal/service/Overrides.java#L116
> The code is guarded with a null check, so there has been a possibility not to use the
blacklist or override feature at all by providing them as "null".
> but the way these properties are read, they never can be null, they either refer to a
file the user configured or to the default file.
> It would be great if it would be possible to turn the feature off some how.
> the best workaround right now is to add empty files, which will at least prevent the
file not found exception, but it is still unnecessary file io (which admittedly is a minor

This message was sent by Atlassian JIRA

View raw message