karaf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF subversion and git services (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (KARAF-6160) NPE when setting configCfgStore=false in the org.apache.karaf.features.cfg
Date Fri, 08 Mar 2019 05:12:00 GMT

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

ASF subversion and git services commented on KARAF-6160:
--------------------------------------------------------

Commit db71f9af5cba35fba21b083bb7675d866e87aaa5 in karaf's branch refs/heads/master from Jean-Baptiste
Onofré
[ https://gitbox.apache.org/repos/asf?p=karaf.git;h=db71f9a ]

[KARAF-6160] This closes #774


> NPE when setting configCfgStore=false in the org.apache.karaf.features.cfg
> --------------------------------------------------------------------------
>
>                 Key: KARAF-6160
>                 URL: https://issues.apache.org/jira/browse/KARAF-6160
>             Project: Karaf
>          Issue Type: Bug
>          Components: karaf
>    Affects Versions: 4.2.3
>         Environment: Java 8
>            Reporter: Xilai Dai
>            Assignee: Jean-Baptiste Onofré
>            Priority: Major
>             Fix For: 4.3.0, 4.2.4
>
>
> When setting configCfgStore=false in the org.apache.karaf.features.cfg, and adding a
feature (with config element defined) into boot feature list, then
> {code}
> org.apache.karaf.features.core[org.apache.karaf.features.internal.service.BootFeaturesInstaller]
: Error installing boot features
> java.lang.NullPointerException
>         at org.apache.karaf.features.internal.service.FeatureConfigInstaller.installFeatureConfigs(FeatureConfigInstaller.java:118)
>         at org.apache.karaf.features.internal.service.BundleInstallSupportImpl.installConfigs(BundleInstallSupportImpl.java:297)
>         at org.apache.karaf.features.internal.service.FeaturesServiceImpl.installConfigs(FeaturesServiceImpl.java:1174)
>         at org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:926)
>         at org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1058)
>         at org.apache.karaf.features.internal.service.FeaturesServiceImpl.lambda$doProvisionInThread$13(FeaturesServiceImpl.java:994)
>         at java.util.concurrent.FutureTask.run(FutureTask.java:266)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
>         at java.lang.Thread.run(Thread.java:748)
> {code}
> NPE is thrown from L118 of FeatureConfigInstaller.java, the cfgFile is not initialized
in case of configCfgStore is false!
> {code}
>             	File cfgFile = null;
>             	 if (storage != null && configCfgStore) {
>             		 cfgFile = new File(storage, cid.fullPid + ".cfg");
>             	 }
>             	 if (!cfgFile.exists()) {   ......
> {code}
> (No this problem on Karaf 4.1.x)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message