I agree that the error message could use some help here. I'll eventually build an assembly to set how 'help scr' is doing without shell-compat.
On Mon, Sep 5, 2016 at 3:29 PM, Guillaume Nodet <[email protected]> wrote: > The wording of the message is slightly wrong. > It should be "Feature named 'shell-compat/4.0.6' is not required" but it > would not be much more clear. > In short, the fact that a feature is installed does not mean you can > "uninstall" it. > You can only uninstall features you have explicitly installed. > And btw, this does not mean that it will be uninstalled, this will be the > case only if it's not required by another feature. > > If you want to get a better picture of what happens, you can use the > "requirement-list" command that will print all the input requirements for > the feature service (and resolver). All those requirements will be > fulfilled at any time after calling "feature:install" or "feature:uninstall" > (or "requirement-add", "requirement-remove"). You can also add requirements > on bundles, services, etc... > > So to get back to the initial problem, "feature:uninstall" does not go > through the list of bundles and uninstalling them anymore. It removes the > requirement from the list of input requirements and run the resolver again. > If the feature is not needed anymore, its bundles will be uninstalled. > > > > 2016-09-05 21:01 GMT+02:00 Benson Margulies <[email protected]>: >> >> I install shell-compat by including 'standard' in my assembly. >> >> If I try to uninstall it, I get the following complaint that it is not >> installed. >> >> karaf@root>feature:uninstall shell-compat/4.0.6 >> 2016-09-05 14:59:20,611 | ERROR | nsole user karaf | ShellUtil >> | 191 - org.apache.karaf.shell.core - 4.0.6 | Exception >> caught while executing command >> java.lang.IllegalArgumentException: Feature named 'shell-compat/4.0.6' >> is not installed >> at >> org.apache.karaf.features.internal.service.FeaturesServiceImpl.uninstallFeatures(FeaturesServiceImpl.java:997)[6:org.apache.karaf.features.core:4.0.6] >> at >> org.apache.karaf.features.command.UninstallFeatureCommand.doExecute(UninstallFeatureCommand.java:54)[178:org.apache.karaf.features.command:4.0.6] >> at >> org.apache.karaf.features.command.FeaturesCommandSupport.execute(FeaturesCommandSupport.java:37)[178:org.apache.karaf.features.command:4.0.6] >> at >> org.apache.karaf.shell.impl.action.command.ActionCommand.execute(ActionCommand.java:83)[191:org.apache.karaf.shell.core:4.0.6] >> at >> org.apache.karaf.shell.impl.console.osgi.secured.SecuredCommand.execute(SecuredCommand.java:67)[191:org.apache.karaf.shell.core:4.0.6] >> at >> org.apache.karaf.shell.impl.console.osgi.secured.SecuredCommand.execute(SecuredCommand.java:87)[191:org.apache.karaf.shell.core:4.0.6] >> at >> org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:480)[191:org.apache.karaf.shell.core:4.0.6] >> at >> org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:406)[191:org.apache.karaf.shell.core:4.0.6] >> at >> org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)[191:org.apache.karaf.shell.core:4.0.6] >> at >> org.apache.felix.gogo.runtime.Closure.execute(Closure.java:182)[191:org.apache.karaf.shell.core:4.0.6] >> at >> org.apache.felix.gogo.runtime.Closure.execute(Closure.java:119)[191:org.apache.karaf.shell.core:4.0.6] >> at >> org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:94)[191:org.apache.karaf.shell.core:4.0.6] >> at >> org.apache.karaf.shell.impl.console.ConsoleSessionImpl.run(ConsoleSessionImpl.java:274)[191:org.apache.karaf.shell.core:4.0.6] >> at java.lang.Thread.run(Thread.java:745)[:1.8.0_60] > > > > > -- > ------------------------ > Guillaume Nodet > ------------------------ > Red Hat, Open Source Integration > > Email: [email protected] > Web: http://fusesource.com > Blog: http://gnodet.blogspot.com/ >
