有 Java 编程相关的问题?

你可以在下面搜索框中键入要查询的问题!

java Spring执行器未映射到localhost:xxxx/activator

我有一个Spring Boot应用程序,我在^{中包含了Spring Actuator

<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-actuator</artifactId>
</dependency>

我的配置如下

management:
  server:
    port: 8200
  endpoints:
    web:
      exposure:
        include: "*"
  endpoint:
    health:
      show-details: always
    metrics:
      enabled: false
  metrics:
    tags:
      application: ${my.application.name}
  health:
    jms:
      enabled: false

然而,当我试图使用localhost:8200/actuator检查端点时,我的浏览器显示

This site can’t be reached
localhost refused to connect.

在我的IntelliJ想法中,我可以看到“执行器”选项卡,它似乎在那里工作,但没有URL映射。有人能帮忙吗


共 (1) 个答案