我有一个对我没有任何意义的堆栈跟踪。我认为它的本质是“找不到数据源名称并且没有指定默认驱动程序”部分,但是我已经注册了一个驱动程序并且我没有使用数据源。如果有帮助,我正在使用 SQL Anywhere 10 驱动程序 (ianywhere)。有没有人有任何想法?
2013-02-15 13:16:58,076 [http-apr-80-exec-1] ERROR errors.GrailsExceptionResolver - SQLException occurred when processing request: [GET] /Booklist/booklist/show
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified. Stacktrace follows:
java.sql.SQLException: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
at ianywhere.ml.jdbcodbc.jdbc3.IDriver.connect(IDriver.java:490)
at java.sql.DriverManager.getConnection(DriverManager.java:579)
at java.sql.DriverManager.getConnection(DriverManager.java:243)
at booklist.Book.getClassesWithBooks(Book.groovy:22)
at booklist.BooklistController.show(BooklistController.groovy:11)
at grails.plugin.cache.web.filter.PageFragmentCachingFilter.doFilter(PageFragmentCachingFilter.java:195)
at grails.plugin.cache.web.filter.AbstractFilter.doFilter(AbstractFilter.java:63)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
编辑:问题是,这在我的本地开发机器上工作得很好,但是一旦我们构建一个 War 并将它放在 tomcat 服务器上,这个可爱的错误就会弹出