spring boot-raspberry pi-restemplate连接超时

0pizxfdo  于 2021-07-03  发布在  Java
关注(0)|答案(0)|浏览(265)

怎么了伙计们
我在raspberry pi上有一个返回字符串的简单api(我们称之为api-a)

@RestController
@CrossOrigin("*")
public class SimpleController{

    @GetMapping("/text")
    public String getText(){
        return "text";
    }
}

我还有一个api,我试图从上一个api获取文本(我们称之为api-b)

@RestController
@CrossOrigin(origins = "*")
public class SecondController{
...
@GetMapping("/gettext")
    public String getTextFromRaspberry(){
        RestTemplate rest = new RestTemplate();
        ResponseEntity<String> response = rest.exchange(
                "http://192.168.55.109/text",
                HttpMethod.GET,
                HttpEntity.EMPTY,
                String.class);
        return response.getBody();
    }
...

这是我的安全配置

@Configuration
public class WebSecurityConfig extends WebSecurityConfigurerAdapter {

    @Override
    protected void configure(HttpSecurity http) throws Exception {
        http.authorizeRequests()
                .anyRequest().permitAll()
                .and()
                .sessionManagement()
                    .sessionCreationPolicy(SessionCreationPolicy.STATELESS)
                .and()
                .csrf().disable()
                .cors();
    }
}

和cors配置

@Configuration
public class CorsConfigurer implements WebMvcConfigurer {
    @Override
    public void addCorsMappings(CorsRegistry registry) {
        registry
                .addMapping("/**")
                .allowedMethods("GET", "POST", "PUT", "PATCH", "DELETE", "OPTIONS")
                .allowCredentials(true)
                .allowedOrigins("*")
                .allowedHeaders("*");
    }
}

当我在raspberry pi上运行api-a,在localhost上运行api-b时,一切都正常。
但是当我在heroku上部署api-b时,它会得到一个异常

2020-12-16T12:21:59.757117+00:00 heroku[router]: at=error code=H12 desc="Request timeout" method=GET path="/gettext" host=terrasi-api.herokuapp.com request_id=07e9a8aa-8d00-44a8-bc8b-101f54a72ed6 fwd="188.117.177.14" dyno=web.1 connect=2ms service=30001ms status=503 bytes=0 protocol=https
2020-12-16T12:22:16.530677+00:00 app[web.1]: 2020-12-16 12:22:16.529 ERROR 4 --- [io-46642-exec-4] o.a.c.c.C.[.[.[/].[dispatcherServlet]    : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is org.springframework.web.client.ResourceAccessException: I/O error on GET request for "http://192.168.55.109/text": Connection timed out (Connection timed out); nested exception is java.net.ConnectException: Connection timed out (Connection timed out)] with root cause
2020-12-16T12:22:16.530703+00:00 app[web.1]: 
2020-12-16T12:22:16.530704+00:00 app[web.1]: java.net.ConnectException: Connection timed out (Connection timed out)
2020-12-16T12:22:16.530705+00:00 app[web.1]:    at java.base/java.net.PlainSocketImpl.socketConnect(Native Method) ~[na:na]
2020-12-16T12:22:16.530709+00:00 app[web.1]:    at java.base/java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:399) ~[na:na]
2020-12-16T12:22:16.530709+00:00 app[web.1]:    at java.base/java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:242) ~[na:na]
2020-12-16T12:22:16.530709+00:00 app[web.1]:    at java.base/java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:224) ~[na:na]
2020-12-16T12:22:16.530710+00:00 app[web.1]:    at java.base/java.net.Socket.connect(Socket.java:609) ~[na:na]
2020-12-16T12:22:16.530711+00:00 app[web.1]:    at java.base/java.net.Socket.connect(Socket.java:558) ~[na:na]
2020-12-16T12:22:16.530711+00:00 app[web.1]:    at java.base/sun.net.NetworkClient.doConnect(NetworkClient.java:182) ~[na:na]
2020-12-16T12:22:16.530714+00:00 app[web.1]:    at java.base/sun.net.www.http.HttpClient.openServer(HttpClient.java:474) ~[na:na]
2020-12-16T12:22:16.530714+00:00 app[web.1]:    at java.base/sun.net.www.http.HttpClient.openServer(HttpClient.java:569) ~[na:na]
2020-12-16T12:22:16.530714+00:00 app[web.1]:    at java.base/sun.net.www.http.HttpClient.<init>(HttpClient.java:242) ~[na:na]
2020-12-16T12:22:16.530715+00:00 app[web.1]:    at java.base/sun.net.www.http.HttpClient.New(HttpClient.java:341) ~[na:na]
2020-12-16T12:22:16.530715+00:00 app[web.1]:    at java.base/sun.net.www.http.HttpClient.New(HttpClient.java:362) ~[na:na]
2020-12-16T12:22:16.530716+00:00 app[web.1]:    at java.base/sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1253) ~[na:na]
2020-12-16T12:22:16.530717+00:00 app[web.1]:    at java.base/sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1187) ~[na:na]
2020-12-16T12:22:16.530717+00:00 app[web.1]:    at java.base/sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1081) ~[na:na]
2020-12-16T12:22:16.530717+00:00 app[web.1]:    at java.base/sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:1015) ~[na:na]
2020-12-16T12:22:16.530720+00:00 app[web.1]:    at org.springframework.http.client.SimpleBufferingClientHttpRequest.executeInternal(SimpleBufferingClientHttpRequest.java:76) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530723+00:00 app[web.1]:    at org.springframework.http.client.AbstractBufferingClientHttpRequest.executeInternal(AbstractBufferingClientHttpRequest.java:48) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530725+00:00 app[web.1]:    at org.springframework.http.client.AbstractClientHttpRequest.execute(AbstractClientHttpRequest.java:53) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530726+00:00 app[web.1]:    at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:739) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530727+00:00 app[web.1]:    at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:674) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530727+00:00 app[web.1]:    at org.springframework.web.client.RestTemplate.exchange(RestTemplate.java:583) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530728+00:00 app[web.1]:    at com.terrasi.terrasiapi.controller.SecondController.getTextFromRaspberry(SecondController.java:74) ~[classes!/:0.0.1-SNAPSHOT]
2020-12-16T12:22:16.530728+00:00 app[web.1]:    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:na]
2020-12-16T12:22:16.530728+00:00 app[web.1]:    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:na]
2020-12-16T12:22:16.530729+00:00 app[web.1]:    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:na]
2020-12-16T12:22:16.530729+00:00 app[web.1]:    at java.base/java.lang.reflect.Method.invoke(Method.java:566) ~[na:na]
2020-12-16T12:22:16.530730+00:00 app[web.1]:    at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:190) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530730+00:00 app[web.1]:    at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:138) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530733+00:00 app[web.1]:    at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:105) ~[spring-webmvc-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530740+00:00 app[web.1]:    at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:878) ~[spring-webmvc-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530740+00:00 app[web.1]:    at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:792) ~[spring-webmvc-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530740+00:00 app[web.1]:    at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) ~[spring-webmvc-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530741+00:00 app[web.1]:    at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1040) ~[spring-webmvc-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530741+00:00 app[web.1]:    at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:943) ~[spring-webmvc-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530742+00:00 app[web.1]:    at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006) ~[spring-webmvc-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530742+00:00 app[web.1]:    at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:898) ~[spring-webmvc-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530742+00:00 app[web.1]:    at javax.servlet.http.HttpServlet.service(HttpServlet.java:626) ~[tomcat-embed-core-9.0.37.jar!/:4.0.FR]
2020-12-16T12:22:16.530743+00:00 app[web.1]:    at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883) ~[spring-webmvc-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530743+00:00 app[web.1]:    at javax.servlet.http.HttpServlet.service(HttpServlet.java:733) ~[tomcat-embed-core-9.0.37.jar!/:4.0.FR]
2020-12-16T12:22:16.530744+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530744+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530744+00:00 app[web.1]:    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) ~[tomcat-embed-websocket-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530745+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530745+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530745+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:320) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530746+00:00 app[web.1]:    at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:126) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530746+00:00 app[web.1]:    at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:90) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530746+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530747+00:00 app[web.1]:    at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:118) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530747+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530747+00:00 app[web.1]:    at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:137) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530748+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530748+00:00 app[web.1]:    at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:111) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530748+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530749+00:00 app[web.1]:    at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:158) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530753+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530753+00:00 app[web.1]:    at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530753+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530753+00:00 app[web.1]:    at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:116) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530754+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530754+00:00 app[web.1]:    at org.springframework.web.filter.CorsFilter.doFilterInternal(CorsFilter.java:92) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530754+00:00 app[web.1]:    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530755+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530755+00:00 app[web.1]:    at org.springframework.security.web.header.HeaderWriterFilter.doHeadersAfter(HeaderWriterFilter.java:92) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530755+00:00 app[web.1]:    at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:77) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530756+00:00 app[web.1]:    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530756+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530756+00:00 app[web.1]:    at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530756+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530757+00:00 app[web.1]:    at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:56) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530757+00:00 app[web.1]:    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530757+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530758+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:215) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530758+00:00 app[web.1]:    at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:178) ~[spring-security-web-5.3.4.RELEASE.jar!/:5.3.4.RELEASE]
2020-12-16T12:22:16.530758+00:00 app[web.1]:    at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:358) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530759+00:00 app[web.1]:    at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:271) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530759+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530760+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530760+00:00 app[web.1]:    at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530760+00:00 app[web.1]:    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530764+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530764+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530765+00:00 app[web.1]:    at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530765+00:00 app[web.1]:    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530766+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530771+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530772+00:00 app[web.1]:    at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530772+00:00 app[web.1]:    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) ~[spring-web-5.2.8.RELEASE.jar!/:5.2.8.RELEASE]
2020-12-16T12:22:16.530772+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530773+00:00 app[web.1]:    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530773+00:00 app[web.1]:    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:202) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530774+00:00 app[web.1]:    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530774+00:00 app[web.1]:    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530774+00:00 app[web.1]:    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530775+00:00 app[web.1]:    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530775+00:00 app[web.1]:    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530776+00:00 app[web.1]:    at org.apache.catalina.valves.RemoteIpValve.invoke(RemoteIpValve.java:747) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530776+00:00 app[web.1]:    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530776+00:00 app[web.1]:    at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:373) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530776+00:00 app[web.1]:    at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530777+00:00 app[web.1]:    at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530777+00:00 app[web.1]:    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1589) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530777+00:00 app[web.1]:    at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530778+00:00 app[web.1]:    at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) ~[na:na]
2020-12-16T12:22:16.530778+00:00 app[web.1]:    at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) ~[na:na]
2020-12-16T12:22:16.530778+00:00 app[web.1]:    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) ~[tomcat-embed-core-9.0.37.jar!/:9.0.37]
2020-12-16T12:22:16.530779+00:00 app[web.1]:    at java.base/java.lang.Thread.run(Thread.java:834) ~[na:na]

有人知道怎么修吗?

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题