23.10 Admin features

来源:互联网 发布:关于linux 的书籍 编辑:程序博客网 时间:2024/06/10 00:38



通过指定 spring.application.admin.enabled 属性,可以使行政相关的特点 。这暴露了在 MBeanServer 平台上的 SpringApplicationAdminMXBean 。可以使用此功能来远程管理Spring Boot程序。这对任何服务包装器实现也是有用的 。

  • 如果你想知道,应用程序正在运行在哪个HTTP端口 ,可以通过local.server.port获取。
  • 启用此功能时,作为MBean暴露的关机方法应用要注意

原文:

23.10 Admin features

It is possible to enable admin-related features for the application by specifying thespring.application.admin.enabled property. This exposes theSpringApplicationAdminMXBeanon the platform MBeanServer. You could use this feature to administer your Spring Bootapplication remotely. This could also be useful for any service wrapper implementation.

[Tip]

If you want to know on which HTTP port the application is running, get the propertywith keylocal.server.port.

[Note]

Take care when enabling this feature as the MBean exposes a method to shutdown theapplication.



没太看懂到底是干啥的,貌似可以用这个接口去实现一些管理发布的功能。,等哪天弄明白在回来修改。