在FR中可以成功连接数据库,但是在独立部署的tomcat中添加数据连接时出现无法连接,该如何解决?

image.png

com.fr.third.springframework.web.util.NestedServletException: Handler dispatch failed; nested exception is java.lang.NoClassDefFoundError: com/fr/data/core/db/JDBCSecurityChecker at com.fr.third.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:982) at com.fr.third.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:901) at com.fr.third.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:970) at com.fr.third.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:872) at javax.servlet.http.HttpServlet.service(HttpServlet.java:681) at com.fr.third.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:846) at javax.servlet.http.HttpServlet.service(HttpServlet.java:764) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.fr.decision.webservice.BackupActivator$1.doFilter(Unknown Source) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.fr.decision.webservice.filter.TenantFilter.doFilter(Unknown Source) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.fr.decision.base.DecisionServletInitializer$6.doFilterInternal(Unknown Source) at com.fr.third.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.fr.decision.base.VirtualFilterChain.doFilter(Unknown Source) at com.fr.decision.base.DecisionServletInitializer$4.doFilter(Unknown Source) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.fr.decision.webservice.filter.CookieCheckFilter.doFilterInternal(Unknown Source) at com.fr.third.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.fr.third.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:197) at com.fr.third.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:196) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:97) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:542) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:135) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81) at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:698) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:78) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:366) at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:639) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:847) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1680) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) 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.lang.NoClassDefFoundError: com/fr/data/core/db/JDBCSecurityChecker at com.fr.data.auth.Authentication.authenticate(Unknown Source) at com.fr.data.impl.JDBCDatabaseConnection.createConnection(Unknown Source) at com.fr.data.impl.JDBCDatabaseConnection.testConnection(Unknown Source) at com.fr.decision.webservice.v10.datasource.connection.processor.impl.JDBCConnectionProcessor.testConnection(Unknown Source) at com.fr.decision.webservice.v10.datasource.connection.processor.impl.ConnectionProcessorFactory.testConnectionWithSchemaReturn(Unknown Source) at com.fr.decision.webservice.v10.datasource.connection.ConnectionService.testConnection(Unknown Source) at sun.reflect.GeneratedMethodAccessor393.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.fr.decision.config.ConfigInterceptor.intercept(Unknown Source) at com.fr.decision.webservice.v10.datasource.connection.ConnectionService$$EnhancerByCGLIB$$a4fd73f2.testConnection(

FineReport 墨竹 发布于 2022-5-21 21:51 (编辑于 2022-5-21 22:27)
1min目标场景问卷 立即参与
回答问题
悬赏:6 F币 + 添加悬赏
提示:增加悬赏、完善问题、追问等操作,可使您的问题被置顶,并向所有关注者发送通知
共5回答
最佳回答
0
墨竹Lv5初级互助
发布于2022-5-22 09:42

在首次注册登录决策系统时,选择内置数据库后不知道为什么后续都无法添加数据连接,重新装了多次都是这样,找不到原因。

解决方法:首次注册登录时选择外置数据库,然后就成功可以添加数据连接了

最佳回答
0
用户6NWif5139660Lv6资深互助
发布于2022-5-21 22:31
模式没写?
  • 墨竹 墨竹(提问者) 选不了,模式那里写的是要连接数据库获取,点击后就出现无法连接的问题了
    2022-05-21 22:36 
最佳回答
0
七夜Lv6初级互助
发布于2022-5-21 23:04(编辑于 2022-5-21 23:31)

TOMCAT下有jdbc驱动吗?是不是不匹配?

最佳回答
0
帆软用户EooHWUPLqGLv2见习互助
发布于2022-5-22 00:10

JDK版本和TOMCAT配置对嘛?环境变量的路径有没有写错之类的?TOMCAT的服务器有没有启动?这些检查过要是还不行,就先卸载重装一下

  • 墨竹 墨竹(提问者) 卸载重装也试过了,也不行。我用的方法是“windows下Tomcat自启动”文档中“https://help.fanruan.com/finereport/doc-view-982.html#3”里的方案二:将 Web 应用服务器启动程序注册为系统服务,系统开机后,服务器就会自动启动,并且在前台也不会有运行窗口。
    2022-05-22 09:40 
最佳回答
0
kita999999Lv4见习互助
发布于2022-5-22 08:57

试下把localhost修改为IP地址.

  • 3关注人数
  • 582浏览人数
  • 最后回答于:2022-5-22 09:42
    请选择关闭问题的原因
    确定 取消
    返回顶部