@Nullable
    private static Integer obtainManagementServerPort(ServerBuilder serverBuilder,
                                                      BeanFactory beanFactory,
                                                      ManagementServerProperties properties) {
        Object internalServices = null;
        if (MANAGEMENT_SERVER_PORT_METHOD != null) {
            assert INTERNAL_SERVICES_CLASS != null;
            internalServices = findBean(beanFactory, INTERNAL_SERVICES_CLASS);
        }

        if (internalServices == null) {
            // The management port was not configured by ArmeriaAutoConfiguration
            final Port managementPort =
                    maybeNewPort(properties.getPort(), properties.getAddress(),
                                 properties.getSsl() != null && properties.getSsl().isEnabled());
            if (managementPort == null) {
                return null;
            }
            configurePorts(serverBuilder, ImmutableList.of(managementPort));
            return managementPort.getPort();
        }

        assert MANAGEMENT_SERVER_PORT_METHOD != null;
        try {
            final Port port = (Port) MANAGEMENT_SERVER_PORT_METHOD.invoke(internalServices);
            if (port == null) {
                return null;
            }
            return port.getPort();
        } catch (IllegalAccessException | InvocationTargetException e) {
            return null;
        }
    }
Returns a {@link HttpCodeStatusMapper}.
See <a href="https://github.com/spring-projects/spring-boot/blob/9643dbeed26268f37d37c22385704de8911b8f21/spring-boot-project/spring-boot-docs/src/docs/asciidoc/actuator/endpoints.adoc#writing-custom-healthindicators">writing-custom-healthindicators</a>.
spring/boot3-actuator-autoconfigure/src/main/java/com/linecorp/armeria/spring/actuate/ArmeriaSpringActuatorAutoConfiguration.java