You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

嵌入式ActiveMQ Artemis Web控制台加载异常问题排查

嵌入式ActiveMQ Artemis Web控制台导航栏缺失问题解决

问题现象

  • 完成嵌入式ActiveMQ Artemis配置后,Web控制台可通过login.config设置的账号密码正常登录,但顶部队列、会话、生产者等核心导航栏完全缺失
  • 直接访问consoleHost:8161显示异常页面,仅consoleHost:8161/console能正常跳转至登录页
  • 日志对比发现关键差异:

    独立Artemis实例日志:[hawtio-jmx-rbac] Using mbean hawtio:type=security,area=jmx,name=ArtemisJMXSecurity for client-side role based access control
    嵌入式实例日志:[hawtio-jmx-rbac] Using mbean hawtio:type=security,area=jmx,rank=0,name=HawtioDummyJMXSecurity for client-side role based access control

  • 查看artemis-plugin.war内的webapp/plugin/js/components/navigation.js文件,确认导航栏显示依赖Artemis专属MBean服务器,推测问题根源是嵌入式实例未正确关联该服务器

解决方法

在原配置步骤的webServerDTO.addBinding(bindingDTO);之后、webServerComponent.configure(webServerDTO, pathToArtemis, pathToArtemis);之前,添加以下代码:

ActiveMQSecurityManager securityManager = server.getActiveMQServer().getSecurityManager();
ManagementContextDTO managementDTO = new ManagementContextDTO();
ManagementContext managementContext = ManagementFactory.create(managementDTO, securityManager);
server.getActiveMQServer().getManagementService().registerHawtioSecurity(managementContext.getArtemisMBeanServerGuard());

注:无需自定义management.xml文件,上述代码会启用默认安全配置

内容的提问来源于stack exchange,提问作者Cooper Jones

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.29 03:17:46