karaf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jean-Baptiste Onofré (JIRA) <j...@apache.org>
Subject [jira] [Commented] (KARAF-3494) client should not fail if it can't read etc/org.apache.karaf.shell.cfg file
Date Thu, 05 Feb 2015 14:01:35 GMT

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

Jean-Baptiste Onofré commented on KARAF-3494:
---------------------------------------------

Fixed on karaf-3.0.x: https://git-wip-us.apache.org/repos/asf?p=karaf.git;a=commitdiff;h=27cca2d124e4620de3993036bf969570fecd24fc

> client should not fail if it can't read etc/org.apache.karaf.shell.cfg file
> ---------------------------------------------------------------------------
>
>                 Key: KARAF-3494
>                 URL: https://issues.apache.org/jira/browse/KARAF-3494
>             Project: Karaf
>          Issue Type: Bug
>          Components: karaf-shell
>    Affects Versions: 3.0.1, 3.0.2, 3.0.3, 2.4.1
>            Reporter: Jean-Baptiste Onofré
>            Assignee: Jean-Baptiste Onofré
>             Fix For: 4.0.0, 2.4.2, 3.0.4
>
>
> The bin/client tries to read etc/org.apache.karaf.shell.cfg file to automatically get
the SSH port number:
> {code}
>         Properties shellCfg = loadProps(new File(System.getProperty("karaf.etc"), "org.apache.karaf.shell.cfg"));
>         String host = shellCfg.getProperty("sshHost", "localhost");
>         int port = Integer.parseInt(shellCfg.getProperty("sshPort", "8101"));
> {code}
> Unfortunately, if etc/org.apache.karaf.shell.cfg file is not present or not readable,
the client fails to start. We should add a try/catch statement and fallback to the default
8101 port number.



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

Mime
View raw message