数据库本地服务器为空,本地搭建的服务器访问不到数据库数据
請問下按照老師的文檔把本地服務器運行起來了,網頁能出現Hello world,IDEA也鏈接上數據庫了,但是為什么用接口訪問不到數據庫的數據
訪問本地 http://192.168.1.102:8080/Kotlin_war_exploded/category/getCategory
postman返回的錯誤信息:
HTTP Status 500 – Internal Server Error
Type 異常報告
消息 Request processing failed; nested exception is org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.exceptions.PersistenceException:
描述 服務器遇到一個意外的情況,阻止它完成請求。
Exception
org.springframework.web.util.NestedServletException: Request processing failed; nested exception is org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.exceptions.PersistenceException:
### Error querying database. Cause: org.springframework.jdbc.CannotGetJdbcConnectionException: Could not get JDBC Connection; nested exception is com.alibaba.druid.pool.GetConnectionTimeoutException: wait millis 60000, active 0, maxActive 20
### The error may exist in file [E:\KotlinMall_coding\Kotlin_Server\Kotlin\target\Kotlin_Server\WEB-INF\classes\mybatis\CategoryMapper.xml]
### The error may involve com.module.user.dao.CategoryMapper.selectCategory
### The error occurred while executing a query
### Cause: org.springframework.jdbc.CannotGetJdbcConnectionException: Could not get JDBC Connection; nested exception is com.alibaba.druid.pool.GetConnectionTimeoutException: wait millis 60000, active 0, maxActive 20
org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:980)
org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:870)
javax.servlet.http.HttpServlet.service(HttpServlet.java:660)
org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:844)
javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:121)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
我的配置:
想同時學下服務器這塊內容,麻煩老師幫忙解決下了,謝謝
總結
以上是生活随笔為你收集整理的数据库本地服务器为空,本地搭建的服务器访问不到数据库数据的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 我的世界正版moba服务器,hello_
- 下一篇: 和平精英清明节服务器维修时间,和平精英体