首页 > 数据库 >com.microsoft.sqlserver.jdbc.SQLServerException: Software caused connection abort: recv failed

com.microsoft.sqlserver.jdbc.SQLServerException: Software caused connection abort: recv failed

时间:2024-10-18 14:50:25浏览次数:7  
标签:web jdbc java caused springframework doFilter org recv ApplicationFilterChain

报错原因

今天新安装的SQL SERVER 2012,于是ruoyi框架就测试多数据源,结果发现无法连接。奇怪的是navicat可以连接,SQL Server Management Studio也可以正常连接。

我们都知道SQLSERVER默认的端口是1433,结果我用1433连接不上。于是查询了端口,发现只有1434端口开着,这个端口一看就是SSL的连接端口。于是修改代码1434,发现代码报错,但是可以连接上。一直很无语。但是至少找到原因了,就是1433端口没有打开。

报错内容

10:01:14.003 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 170a5548-f12f-40e6-920a-a85953262ac0 Prelogin error: host localhost port 1434 Error reading prelogin response: Connection reset ClientConnectionId:170a5548-f12f-40e6-920a-a85953262ac0
10:01:14.122 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 6a59001a-9cbc-4ab7-908e-96256ce93bf7 Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:6a59001a-9cbc-4ab7-908e-96256ce93bf7
10:01:14.338 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 8c081455-7734-482e-8aa4-f4914506b591 Prelogin error: host localhost port 1434 Error reading prelogin response: Connection reset ClientConnectionId:8c081455-7734-482e-8aa4-f4914506b591
10:01:14.754 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: a27012a1-5007-4f07-bb01-1945e17df7cb Prelogin error: host localhost port 1434 Error reading prelogin response: Connection reset ClientConnectionId:a27012a1-5007-4f07-bb01-1945e17df7cb
10:01:15.565 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 29b8edbd-dde8-4601-bae5-49f2b132be55 Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:29b8edbd-dde8-4601-bae5-49f2b132be55
10:01:16.578 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 02c70a93-4c00-4810-958e-415279b2e48b Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:02c70a93-4c00-4810-958e-415279b2e48b
10:01:17.582 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: cb0730d2-08c5-4399-b120-b628d3d3a9be Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:cb0730d2-08c5-4399-b120-b628d3d3a9be
10:01:18.589 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 7ea5f5af-efd9-4abb-a7c2-1b69610b6a1b Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:7ea5f5af-efd9-4abb-a7c2-1b69610b6a1b
10:01:19.605 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: ad45c5a2-0df3-43f1-80ec-2b869224e360 Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:ad45c5a2-0df3-43f1-80ec-2b869224e360
10:01:20.611 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: ed93912a-b27d-4ecb-840b-d321b3011a04 Prelogin error: host localhost port 1434 Error reading prelogin response: Connection reset ClientConnectionId:ed93912a-b27d-4ecb-840b-d321b3011a04
10:01:21.626 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 8c63902a-301d-483c-8d3f-5899a2767139 Prelogin error: host localhost port 1434 Error reading prelogin response: Connection reset ClientConnectionId:8c63902a-301d-483c-8d3f-5899a2767139
10:01:22.639 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 42786c5d-22bf-4c95-b736-d71176055c39 Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:42786c5d-22bf-4c95-b736-d71176055c39
10:01:23.643 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 83439621-454c-400b-b27d-ea22e96fafa8 Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:83439621-454c-400b-b27d-ea22e96fafa8
10:01:24.646 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: be5401eb-8256-46e0-8eab-3c2c08ecea4e Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:be5401eb-8256-46e0-8eab-3c2c08ecea4e
10:01:25.651 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: d1d7d593-a172-46bd-b683-d70be08e9dae Prelogin error: host localhost port 1434 Error reading prelogin response: Connection reset ClientConnectionId:d1d7d593-a172-46bd-b683-d70be08e9dae
10:01:26.667 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 4f8194c4-55b4-47c9-99a4-017ac9148d68 Prelogin error: host localhost port 1434 Error reading prelogin response: Connection reset ClientConnectionId:4f8194c4-55b4-47c9-99a4-017ac9148d68
10:01:27.682 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: d3a82303-a1ff-48b5-8444-2e848f40ea01 Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:d3a82303-a1ff-48b5-8444-2e848f40ea01
10:01:28.699 [http-nio-8181-exec-2] WARN  c.m.s.j.i.SQLServerConnection - [Prelogin,2919] - ConnectionID:2 ClientConnectionId: 9da64004-59b4-4eed-b84b-32411515a228 Prelogin error: host localhost port 1434 Error reading prelogin response: Software caused connection abort: recv failed ClientConnectionId:9da64004-59b4-4eed-b84b-32411515a228
10:01:28.702 [http-nio-8181-exec-2] ERROR c.a.d.p.DruidDataSource - [init,929] - init datasource error, url: jdbc:sqlserver://localhost:1434;databaseName=fos
com.microsoft.sqlserver.jdbc.SQLServerException: Software caused connection abort: recv failed ClientConnectionId:9da64004-59b4-4eed-b84b-32411515a228
	at com.microsoft.sqlserver.jdbc.SQLServerConnection.terminate(SQLServerConnection.java:3206)
	at com.microsoft.sqlserver.jdbc.TDSChannel.read(IOBuffer.java:2066)
	at com.microsoft.sqlserver.jdbc.SQLServerConnection.Prelogin(SQLServerConnection.java:2917)
	at com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:2756)
	at com.microsoft.sqlserver.jdbc.SQLServerConnection.login(SQLServerConnection.java:2418)
	at com.microsoft.sqlserver.jdbc.SQLServerConnection.connectInternal(SQLServerConnection.java:2265)
	at com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:1291)
	at com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(SQLServerDriver.java:881)
	at com.alibaba.druid.filter.FilterChainImpl.connection_connect(FilterChainImpl.java:118)
	at com.alibaba.druid.filter.stat.StatFilter.connection_connect(StatFilter.java:232)
	at com.alibaba.druid.filter.FilterChainImpl.connection_connect(FilterChainImpl.java:112)
	at com.alibaba.druid.pool.DruidAbstractDataSource.createPhysicalConnection(DruidAbstractDataSource.java:1703)
	at com.alibaba.druid.pool.DruidAbstractDataSource.createPhysicalConnection(DruidAbstractDataSource.java:1786)
	at com.alibaba.druid.pool.DruidDataSource.init(DruidDataSource.java:925)
	at com.alibaba.druid.pool.DruidDataSource.getConnection(DruidDataSource.java:1444)
	at com.alibaba.druid.pool.DruidDataSource.getConnection(DruidDataSource.java:1440)
	at com.alibaba.druid.pool.DruidDataSource.getConnection(DruidDataSource.java:83)
	at org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource.getConnection(AbstractRoutingDataSource.java:194)
	at org.springframework.jdbc.datasource.DataSourceTransactionManager.doBegin(DataSourceTransactionManager.java:265)
	at org.springframework.transaction.support.AbstractPlatformTransactionManager.startTransaction(AbstractPlatformTransactionManager.java:400)
	at org.springframework.transaction.support.AbstractPlatformTransactionManager.getTransaction(AbstractPlatformTransactionManager.java:373)
	at org.springframework.transaction.interceptor.TransactionAspectSupport.createTransactionIfNecessary(TransactionAspectSupport.java:595)
	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:382)
	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:763)
	at org.springframework.aop.aspectj.MethodInvocationProceedingJoinPoint.proceed(MethodInvocationProceedingJoinPoint.java:89)
	at com.ruoyi.framework.aspectj.DataSourceAspect.around(DataSourceAspect.java:49)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:634)
	at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:624)
	at org.springframework.aop.aspectj.AspectJAroundAdvice.invoke(AspectJAroundAdvice.java:72)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:175)
	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:763)
	at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:97)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:763)
	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708)
	at com.ruoyi.flowinn.service.FosUserV3Service$$EnhancerBySpringCGLIB$$7f9fd83d.list(<generated>)
	at com.ruoyi.flowinn.testController.BladeUserTest.sqlserver(BladeUserTest.java:37)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:205)
	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:150)
	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:117)
	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:895)
	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:808)
	at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87)
	at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1072)
	at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:965)
	at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006)
	at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:898)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:529)
	at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:623)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:209)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
	at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:111)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:111)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
	at com.alibaba.druid.support.http.WebStatFilter.doFilter(WebStatFilter.java:114)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
	at com.ruoyi.common.filter.RepeatableFilter.doFilter(RepeatableFilter.java:39)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:327)
	at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:115)
	at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:81)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:121)
	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:115)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:126)
	at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:81)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:105)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:149)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at com.ruoyi.framework.security.filter.JwtAuthenticationTokenFilter.doFilterInternal(JwtAuthenticationTokenFilter.java:47)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:111)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:103)
	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:89)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.web.filter.CorsFilter.doFilterInternal(CorsFilter.java:91)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.security.web.header.HeaderWriterFilter.doHeadersAfter(HeaderWriterFilter.java:90)
	at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:75)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:110)
	at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:80)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:55)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:336)
	at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:211)
	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:183)
	at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:354)
	at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:267)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
	at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
	at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:178)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:153)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:167)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:90)
	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:481)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:130)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:93)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
	at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:390)
	at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:63)
	at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:926)
	at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1791)
	at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52)
	at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191)
	at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659)
	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
	at java.lang.Thread.run(Thread.java:748)
Caused by: java.net.SocketException: Software caused connection abort: recv failed
	at java.net.SocketInputStream.socketRead0(Native Method)
	at java.net.SocketInputStream.socketRead(SocketInputStream.java:116)
	at java.net.SocketInputStream.read(SocketInputStream.java:171)
	at java.net.SocketInputStream.read(SocketInputStream.java:141)
	at com.microsoft.sqlserver.jdbc.TDSChannel.read(IOBuffer.java:2058)
	... 146 common frames omitted
10:01:28.704 [http-nio-8181-exec-2] INFO  c.a.d.p.DruidDataSource - [init,996] - {dataSource-2} inited

解决方法

1、查看数据库端口

-- 需要sa登录
-- 执行下面的代码,返回数据库端口
-- 
exec sys.sp_readerrorlog 0, 1, 'listening'

2、启动1433服务

3、重启服务

4、结束

这时候代码中用1433端口去连接就可以了。

标签:web,jdbc,java,caused,springframework,doFilter,org,recv,ApplicationFilterChain
From: https://blog.csdn.net/renkai721/article/details/143051977

相关文章

  • Sharding-JDBC标准模式详解
    Sharding-JDBC标准模式详解一.为什么要使用标准模式?Sharding-JDBC的标准模式就配置而言比inline模式繁琐多了,那为什么要使用标准模式呢Sharding-JDBC作为ApacheShardingSphere生态中的一款轻量级Java框架,提供了数据分片、读写分离、分布式事务和数据库治理等核心功......
  • Loading class `com.mysql.jdbc.Driver’. This is deprecated. The new driver class
    原文链接:Loadingclass`com.mysql.jdbc.Driver’.Thisisdeprecated.Thenewdriverclassis`com.mysql.cj.jdbc.Driver’.–每天进步一点点(longkui.site)某日构建springboot项目时,报的错:Loadingclass`com.mysql.jdbc.Driver'.Thisisdeprecated.Thenewdriver......
  • c3p0数据库连接池出现Could not get JDBC Connection An attempt by a client to chec
    c3p0有些年头了,也曾红极一时。但你是否遇到过,明明并发并不高,连接池最大连接数也设的挺大了,还是报无法获取新连接。CouldnotgetJDBCConnectionAnattemptbyaclienttocheckoutaConnectionhastimedout.参考文章:https://cloud.tencent.com/developer/article/2319703......
  • 第04章 SpringBoot集成JDBC
    首先,我们新创建一个“SpringBootJdbcDemo”的Maven工程。然后我们修改编码格式以及Maven仓库地址,我们省略这个过程了。接着我们再添加spring-boot-starter-parent,spring-boot-starter-web,spring-boot-starter-thymeleaf依赖库,然后我们还需要添加本章节要学习的spring-bo......
  • MySQL 的 JDBC 编程
    MySQL的JDBC编程使用java代码操作数据库jdbc统一了各种数据库的api准备阶段首先要准备编辑语言的安装:javajdk1.8数据库数据库驱动包:在中央仓库下载搜索MySQL第一个就是MySQLConnector/j下载完成后在IDEA中导入这个包打开IDEA新建一个java项目新建......
  • Java日总结 --- JDBC
    JDBCAPI---StatementDDL为对数据库和表的增删改查操作,DML是对数据的增删改操作,DQL是对数据的查询操作Statement对象中的executeUpdate(sql)方法为执行sql语句的操作,同时该方法会返回一个值,为受影响的行数,也就是执行语句的条数当执行的是DML语句时,可以通过返回值是否大于......
  • JDBC
    目录简述JDBC操作数据库的步骤?PreparedStatement比Statement有什么优势?简述数据库连接池的机制原理?你知道有哪些数据库连接池?机制原理常见的数据库连接池简述JDBC操作数据库的步骤?JDBC(JavaDatabaseConnectivity)是一个JavaAPI,用于连接和执行查询在数据库中。以下是使......
  • ERROR [org.hibernate.transaction.JDBCTransaction] - Could not toggle autocommit
    错误描述: DEBUG[org.hibernate.SQL]-SELECTorp.ATTR6FROMDISTRIBUT_VIEWd WHEREd.state='1'ANDd.oper_logLIKE'%下单%' GROUPBYorp.ATTR6 ERROR[org.hibernate.transaction.JDBCTransaction]-Couldnottoggleautocommitjava.sql.SQLE......
  • Java日总结---JDBC
    JDBC就是使用java语言操作关系型数据库的一种API1.JDBAAPI---DriverManager(两个作用)注册驱动:在mysql8.0后是ClassforName("com.mysql.cj.jdbc.Driver");来实现的查看源码后发现是由Driver类中静态代码块,底层是由DriverManager中的registerDriver方法来做的提示:在mysql5......
  • idea数据库图形化窗口连接数据库报错:Driver class ‘com.mysql.cj.jdbc.Driver‘ not
    报错信息在idea中数据库图形化窗口中,创建下图数据库连接点击测试连接后,发生报错:Driverclass'com.mysql.cj.jdbc.Driver'notfoundNodriverfilesprovided.报错界面:原因出现此错误的原因通常是数据库驱动程序尚未下载或未正确配置到IDEA中。解决方案......