dubbo SpringMVC MyBatis 整合環境 開發中遇到的一些錯誤提示及解決辦法
阿新 • • 發佈:2019-02-04
1.
Handler processing failed; nested exception is java.lang.NoSuchMethodError
找不到這個方法,後面給出相應方法路徑
解決辦法:
1.檢查呼叫的路徑是否正確
2.是不是存在同名檔案,有可能查詢到另一個檔案裡,而這個檔案裡沒有對應的方法
3.上面都沒問題的話,重啟環境吧(我的就是這麼解決的)
2.修改XML檔案不生效
解決辦法:emmmm修改之後記得重啟環境
3.org.springframework.beans.factory.BeanCreationException: Could not autowire field
沒有在註冊中心暴露和使用服務
解決辦法:在註冊中心暴露和使用服務,重啟環境
4.Failed to invoke the method [......] in the service
5.org.apache.ibatis.binding.BindingException: Invalid bound statement (not found)
先檢查Mapper.xml中是否有與報錯方法對應的查詢語句
6.JDBC requires that the JdbcType must be specified for all nullable parameters.
1.SQL語句有問題,檢查一下判斷部分
2.有可能是在dao層的方法沒有正確對映到相關的Mapper.xml裡的 sql 塊