无法访问Web控制台界面

时间:2013-01-25 12:35:06

标签: osgi apache-felix osgi-bundle

几天以来,我正在玩apache felix。一切正常,因为在推出lb命令时可以看到:

START LEVEL 2
   ID|State      |Level|Name
    0|Active     |    0|System Bundle (4.0.3)
    1|Active     |    2|Apache Felix Bundle Repository (1.6.6)
    2|Active     |    2|Apache Felix Configuration Admin Service (1.6.0)
    3|Active     |    2|Apache Felix Gogo Command (0.12.0)
    4|Active     |    2|Apache Felix Gogo Runtime (0.10.0)
    5|Active     |    2|Apache Felix Gogo Shell (0.10.0)
    6|Active     |    2|Apache Felix Http Bundle (2.2.0)
    7|Active     |    2|Apache Felix iPOJO (1.8.6)
    8|Active     |    2|Apache Felix iPOJO OSGi Junit Runner (1.0.0)
    9|Active     |    2|Apache Felix Shell Service (1.4.3)
   10|Active     |    2|Apache Felix Web Management Console (3.1.8)
   11|Installed  |    3|[Optimacs/OSGi] DataService - Hello World (1.1.0)
   12|Active     |    2|[Optimacs/OSGi] DataService Model (0.4.1.SNAPSHOT)
   13|Active     |    2|[Optimacs/OSGi] DataService Network API (0.4.1.SNAPSHOT)
   14|Active     |    2|[Optimacs/OSGi] DataService Container (0.4.1.SNAPSHOT)

根据此列表,我可以使用Web管理控制台。为此,我将org.osgi.service.http.port选项设置为8080。 我打开浏览器(Chrome,最新版本)并尝试访问Web控制台(url = http://localhost:8080/system/console)时出现问题。我收到错误102(连接被拒绝)。 我错过了任何特定的配置步骤吗?

修改

通过gogo shell运行inspect cap service会报告以下有关HttpService的信息:

org.apache.felix.http.bundle [6] provides:
------------------------------------------
service; javax.servlet.http.HttpServlet with properties:
   http.felix.dispatcher = org.apache.felix.http.base.internal.DispatcherServlet
   service.description = Dispatcher for bridged request handling
   service.id = 20
   service.vendor = The Apache Software Foundation
service; java.util.EventListener with properties:
   http.felix.dispatcher = org.apache.felix.http.base.internal.EventDispatcher
   service.description = Dispatcher for bridged HttpSession events
   service.id = 21
   service.vendor = The Apache Software Foundation

遗憾的是没有关于使用过的端口的迹象。

1 个答案:

答案 0 :(得分:0)

由于Neil的评论,问题已得到解决:

  

我想知道HttpService是否存在,您是否可以从shell检查上限服务并扫描HttpService?如果它在那里它还应该报告它正在使用的端口号。