springboot version 2.3.12.RELEASE
code show as up,
and the idea' consol show could get response by resttemplate ,but always occur failed, but idon't know why?
i cloud get response by resttemplate but also occur failed,please help me,thanks
Comment From: wilkinsona
The error indicates that nothing is listening on localhost:8090 so a connection cannot be established. @Scheduled
should have no effect on this, unless its the application itself that should be listening onlocalhost:8090
. In this case, the @Scheduled
method may be called before the embedded web server has started accepting connections. You could listen for org.springframework.boot.context.event.ApplicationReadyEvent
and only make a request once the application is ready to accept them.
If you have any further questions, please follow up on Stack Overflow or Gitter. As mentioned in the guidelines for contributing, we prefer to use GitHub issues only for bugs and enhancements.