NutzCN Logo
问答 新手求帮助!!
发布于 3046天前 作者 qq_9a5db80b 1735 次浏览 复制 上一个帖子 下一个帖子
标签:

按照http://nutzbook.wendal.net/setup30mins/add_usermodule.html 做的联系,卡在了数据库建表上
代码都是照这个网址输入的,一点儿不差!那么问题来了,到底怎么回事!!!

七月 21, 2016 4:37:33 下午 org.apache.catalina.core.AprLifecycleListener init
信息: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jdk1.7.0_79\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:/Program Files/Java/jdk1.7.0_79/bin/../jre/bin/server;C:/Program Files/Java/jdk1.7.0_79/bin/../jre/bin;C:/Program Files/Java/jdk1.7.0_79/bin/../jre/lib/amd64;G:\app\sony\product\11.1.0\db_1\bin;F:\软件\oracle1\bin;C:\Program Files\Java\jdk1.7.0_79\bin;C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Intel\iCLS Client\;C:\Program Files\Intel\iCLS Client\;c:\Program Files (x86)\AMD APP\bin\x86_64;c:\Program Files (x86)\AMD APP\bin\x86;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;c:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Sony\VAIO Improvement\;C:\Program Files (x86)\Sony\VAIO Startup Setting Tool;C:\Program Files (x86)\Windows Live\Shared;F:\软件\sv\bin;C:\Program Files\Java\jdk1.7.0_79\bin;F:\软件\Tomcat\apache-tomcat-6.0.44\bin;C:\Program Files (x86)\MySQL\MySQL Server 5.5\bin;F:\软件\Rational Rose 2007\Common;E:\java\apache-maven-3.2.2\bin;C:\Program Files (x86)\MySQL\MySQL Server 5.6\bin;F:\软件\Eclipse\exlipse 32\eclipse;;.
七月 21, 2016 4:37:33 下午 org.apache.tomcat.util.digester.SetPropertiesRule begin
警告: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:nutzbook' did not find a matching property.
七月 21, 2016 4:37:33 下午 org.apache.coyote.http11.Http11Protocol init
信息: Initializing Coyote HTTP/1.1 on http-8080
七月 21, 2016 4:37:33 下午 org.apache.catalina.startup.Catalina load
信息: Initialization processed in 1258 ms
七月 21, 2016 4:37:33 下午 org.apache.catalina.core.StandardService start
信息: Starting service Catalina
七月 21, 2016 4:37:33 下午 org.apache.catalina.core.StandardEngine start
信息: Starting Servlet Engine: Apache Tomcat/6.0.44
七月 21, 2016 4:37:34 下午 org.apache.catalina.loader.WebappClassLoader validateJarFile
信息: validateJarFile(F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\servlet-api-2.5.jar) - jar not loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: javax/servlet/Servlet.class
2016-7-21 16:37:34.659 WARN [main] !!You are using default SystemLog! Don't use it in Production environment!!
2016-7-21 16:37:34.673 INFO [main] NutFilter[nutz] starting ...
2016-7-21 16:37:35.52 DEBUG [main] Locations for Scans:
[JarResourceLocation [jarPath=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\nutz-last.jar], JarResourceLocation [jarPath=C:\Program Files\Java\jdk1.7.0_79\lib\tools.jar], JarResourceLocation [jarPath=F:\软件\Tomcat\apache-tomcat-6.0.44\bin\bootstrap.jar], FileSystemResourceLocation [root=F:\软件\Eclipse\exlipse 32\eclipse]]
2016-7-21 16:37:35.422 DEBUG [main] Locations for Scans:
[JarResourceLocation [jarPath=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\nutz-last.jar], JarResourceLocation [jarPath=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\standard.jar], JarResourceLocation [jarPath=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\mysql-connector-java-5.0.0-beta-bin.jar], JarResourceLocation [jarPath=C:\Program Files\Java\jdk1.7.0_79\lib\tools.jar], JarResourceLocation [jarPath=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\druid-1.0.16.jar], JarResourceLocation [jarPath=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\commons-pool.jar], JarResourceLocation [jarPath=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\h2-1.2.131.jar], JarResourceLocation [jarPath=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\commons-dbcp.jar], JarResourceLocation [jarPath=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\servlet-api-2.5.jar], JarResourceLocation [jarPath=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\lib\jstl.jar], FileSystemResourceLocation [root=F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\nutzbook\WEB-INF\classes], JarResourceLocation [jarPath=F:\软件\Tomcat\apache-tomcat-6.0.44\bin\bootstrap.jar], FileSystemResourceLocation [root=F:\软件\Eclipse\exlipse 32\eclipse]]
2016-7-21 16:37:35.432 DEBUG [main] MainModule: <net.wendal.nutzbook.MainModule>
2016-7-21 16:37:35.477 DEBUG [main] Loading by class org.nutz.mvc.impl.NutLoading
2016-7-21 16:37:35.487 INFO [main] Nutz Version : 1.r.56
2016-7-21 16:37:35.488 INFO [main] Nutz.Mvc[nutz] is initializing ...
2016-7-21 16:37:35.489 DEBUG [main] Web Container Information:
2016-7-21 16:37:35.494 DEBUG [main] - Default Charset : UTF-8
2016-7-21 16:37:35.495 DEBUG [main] - Current . path : F:\软件\Eclipse\exlipse 32\eclipse.
2016-7-21 16:37:35.496 DEBUG [main] - Java Version : 1.7.0_79
2016-7-21 16:37:35.497 DEBUG [main] - File separator : \
2016-7-21 16:37:35.498 DEBUG [main] - Timezone : Asia/Shanghai
2016-7-21 16:37:35.500 DEBUG [main] - OS : Windows 7 amd64
2016-7-21 16:37:35.501 DEBUG [main] - ServerInfo : Apache Tomcat/6.0.44
2016-7-21 16:37:35.503 DEBUG [main] - Servlet API : 2.5
2016-7-21 16:37:35.504 DEBUG [main] - ContextPath : /nutzbook
2016-7-21 16:37:35.505 DEBUG [main] - context.tempdir : F:\Eclise存储.metadata.plugins\org.eclipse.wst.server.core\tmp0\work\Catalina\localhost\nutzbook
2016-7-21 16:37:35.509 DEBUG [main] MainModule: <net.wendal.nutzbook.MainModule>
2016-7-21 16:37:35.510 DEBUG [main] >> app.root = F:/Eclise存储/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/nutzbook
2016-7-21 16:37:35.741 DEBUG [main] Using 94 castor for Castors
2016-7-21 16:37:35.745 DEBUG [main] @IocBy(type=org.nutz.mvc.ioc.provider.ComboIocProvider, args=["*js", "ioc/", "*anno", "net.wendal.nutzbook", "*tx"],init=[])
2016-7-21 16:37:35.827 DEBUG [main] Found 1 resource by src( ioc/ ) , regex( ^(.+[.])(js|json)$ )
2016-7-21 16:37:35.828 DEBUG [main] loading ioc js config from [dao.js]
2016-7-21 16:37:35.846 DEBUG [main] Loaded 2 bean define from path=[ioc/] --> [dataSource, dao]
2016-7-21 16:37:35.864 DEBUG [main] Found 4 resource by src( net/wendal/nutzbook/ ) , regex( ^.+[.]class$ )
2016-7-21 16:37:35.950 DEBUG [main] Found : class net.wendal.nutzbook.module.UserModule
2016-7-21 16:37:35.969 INFO [main] Found 1 classes in 1 base-packages!
beans = ["userModule"]
2016-7-21 16:37:35.972 DEBUG [main] Loaded 5 bean define from reader --
[txREPEATABLE_READ, txREAD_COMMITTED, txNONE, txSERIALIZABLE, txREAD_UNCOMMITTED]
2016-7-21 16:37:35.979 INFO [main] NutIoc init begin ...
2016-7-21 16:37:35.989 INFO [main] ... NutIoc init complete
2016-7-21 16:37:35.992 DEBUG [main] MainModule: <net.wendal.nutzbook.MainModule>
2016-7-21 16:37:35.999 INFO [main] Build URL mapping by org.nutz.mvc.impl.UrlMappingImpl ...
2016-7-21 16:37:36.10 DEBUG [main] @Views(DefaultViewMaker.class)
2016-7-21 16:37:36.26 DEBUG [main] @ChainBy(org.nutz.mvc.impl.NutActionChainMaker)
2016-7-21 16:37:36.43 DEBUG [main] module class location 'file:/F:/Eclise存储/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/nutzbook/WEB-INF/classes/net/wendal/nutzbook/MainModule.class'
2016-7-21 16:37:36.44 DEBUG [main] > scan 'net.wendal.nutzbook'
2016-7-21 16:37:36.49 DEBUG [main] Found 4 resource by src( net/wendal/nutzbook/ ) , regex( ^.+[.]class$ )
2016-7-21 16:37:36.51 DEBUG [main] >> add 'net.wendal.nutzbook.module.UserModule'
2016-7-21 16:37:36.69 INFO [main] Optional processor class not found, disabled : org.nutz.integration.shiro.NutShiroProcessor
2016-7-21 16:37:36.82 INFO [main] Optional processor class not found, disabled : org.nutz.plugins.validation.ValidationProcessor
2016-7-21 16:37:36.114 DEBUG [main] '/user/count' >> UserModule.count(...) : int | @Ok(json ) @Fail(http:500) | by 0 Filters | (I:UTF-8/O:UTF-8)
2016-7-21 16:37:36.115 INFO [main] Found 1 module methods
2016-7-21 16:37:36.118 DEBUG [main] @Localization not define
2016-7-21 16:37:36.120 INFO [main] Setup application...
2016-7-21 16:37:36.122 DEBUG [main] Get 'dao'<interface org.nutz.dao.Dao>
2016-7-21 16:37:36.129 DEBUG [main] Load AopConfigure for anno=org.nutz.ioc.aop.Aop by type=org.nutz.ioc.aop.config.impl.AnnotationAopConfigration
2016-7-21 16:37:36.132 DEBUG [main] >> Load definition name=dao
2016-7-21 16:37:36.135 DEBUG [main] Loading define for name=dao
2016-7-21 16:37:36.180 DEBUG [main] Found IocObject(dao) in JsonLoader(paths=[ioc/])
2016-7-21 16:37:36.181 DEBUG [main] >> Make...'dao'<interface org.nutz.dao.Dao>
2016-7-21 16:37:36.227 DEBUG [main] Load class org.nutz.dao.impl.NutDao without AOP
2016-7-21 16:37:36.230 DEBUG [main] Save object 'dao' to [app]
2016-7-21 16:37:36.238 DEBUG [main] Get 'dataSource'<>
2016-7-21 16:37:36.239 DEBUG [main] >> Load definition name=dataSource
2016-7-21 16:37:36.240 DEBUG [main] Loading define for name=dataSource
2016-7-21 16:37:36.269 DEBUG [main] Found IocObject(dataSource) in JsonLoader(paths=[ioc/])
2016-7-21 16:37:36.270 DEBUG [main] >> Make...'dataSource'<>
2016-7-21 16:37:36.339 DEBUG [main] Load class com.alibaba.druid.pool.DruidDataSource without AOP
2016-7-21 16:37:36.341 DEBUG [main] Save object 'dataSource' to [app]
七月 21, 2016 4:37:36 下午 com.alibaba.druid.pool.vendor.MySqlValidConnectionChecker warn
警告: Cannot resolve com.mysq.jdbc.Connection.ping method. Will use 'SELECT 1' instead.
java.lang.NullPointerException
at com.alibaba.druid.pool.vendor.MySqlValidConnectionChecker.(MySqlValidConnectionChecker.java:50)
at com.alibaba.druid.pool.DruidDataSource.initValidConnectionChecker(DruidDataSource.java:892)
at com.alibaba.druid.pool.DruidDataSource.init(DruidDataSource.java:608)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.nutz.ioc.trigger.MethodEventTrigger.trigger(MethodEventTrigger.java:18)
at org.nutz.ioc.weaver.DefaultWeaver.onCreate(DefaultWeaver.java:72)
at org.nutz.ioc.impl.ObjectMakerImpl.make(ObjectMakerImpl.java:138)
at org.nutz.ioc.impl.NutIoc.get(NutIoc.java:209)
at org.nutz.ioc.val.ReferValue.get(ReferValue.java:24)
at org.nutz.ioc.impl.ObjectMakerImpl.make(ObjectMakerImpl.java:75)
at org.nutz.ioc.impl.NutIoc.get(NutIoc.java:209)
at org.nutz.ioc.impl.NutIoc.get(NutIoc.java:235)
at org.nutz.ioc.impl.NutIoc.get(NutIoc.java:146)
at net.wendal.nutzbook.MainSetup.init(MainSetup.java:17)
at org.nutz.mvc.impl.NutLoading.evalSetup(NutLoading.java:276)
at org.nutz.mvc.impl.NutLoading.load(NutLoading.java:120)
at org.nutz.mvc.ActionHandler.(ActionHandler.java:19)
at org.nutz.mvc.NutFilter._init(NutFilter.java:87)
at org.nutz.mvc.NutFilter.init(NutFilter.java:65)
at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:298)
at org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:119)
at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4076)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4730)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1060)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:822)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1060)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:463)
at org.apache.catalina.core.StandardService.start(StandardService.java:525)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:759)
at org.apache.catalina.startup.Catalina.start(Catalina.java:595)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414)

七月 21, 2016 4:37:36 下午 com.alibaba.druid.pool.DruidDataSource info
信息: {dataSource-1} inited
2016-7-21 16:37:36.491 DEBUG [main] Get 'dataSource'<>
2016-7-21 16:37:36.509 DEBUG [main] NutDao[_selfId=0] init ...
2016-7-21 16:37:36.570 INFO [main] Init file-pool by: C:\Users\sony/.nutz/tmp/dao/ [200000]
2016-7-21 16:37:36.573 DEBUG [main] file-pool.home: 'C:\Users\sony.nutz\tmp\dao'
2016-7-21 16:37:36.575 INFO [main] file-pool.cursor: 0
2016-7-21 16:37:36.596 DEBUG [main] Jdbcs init complete
2016-7-21 16:37:36.596 INFO [main] Get Connection from DataSource for JdbcExpert, if I lock at here, check your database server and configure
2016-7-21 16:37:36.917 DEBUG [main] JDBC Driver --> mysql-connector-java-5.0.0-beta ( $Date: 2005-11-17 16:14:47 +0100 (Thu, 17 Nov 2005) $, $Revision$ )
2016-7-21 16:37:36.918 DEBUG [main] JDBC Name --> MySQL-AB JDBC Driver
2016-7-21 16:37:36.918 DEBUG [main] JDBC URL --> jdbc:mysql://127.0.0.1:3306/nutzbook
2016-7-21 16:37:36.931 DEBUG [main] Mysql : character_set_client=utf8
2016-7-21 16:37:36.931 DEBUG [main] Mysql : character_set_connection=utf8
2016-7-21 16:37:36.932 DEBUG [main] Mysql : character_set_database=utf8
2016-7-21 16:37:36.932 DEBUG [main] Mysql : character_set_filesystem=binary
2016-7-21 16:37:36.933 DEBUG [main] Mysql : character_set_results=
2016-7-21 16:37:36.933 DEBUG [main] Mysql : character_set_server=utf8
2016-7-21 16:37:36.934 DEBUG [main] Mysql : character_set_system=utf8
2016-7-21 16:37:36.934 DEBUG [main] Mysql : character_sets_dir=C:\Program Files (x86)\MySQL\MySQL Server 5.6\share\charsets\
2016-7-21 16:37:36.936 DEBUG [main] Mysql : database=nutzbook
2016-7-21 16:37:36.937 DEBUG [main] Mysql : user=root@localhost
2016-7-21 16:37:36.961 DEBUG [main] Database info --> MYSQL:[MySQL - 5.6.5-m8]
2016-7-21 16:37:36.979 DEBUG [main] Found 4 resource by src( net/wendal/nutzbook/ ) , regex( ^.+[.]class$ )
2016-7-21 16:37:37.90 INFO [main] Can not find @Column(password) in table/view (t_user)
2016-7-21 16:37:37.110 DEBUG [main] SELECT COUNT(*) FROM t_user
2016-7-21 16:37:37.112 INFO [main] Nutz.Mvc[nutz] is up in 1604ms
七月 21, 2016 4:37:37 下午 org.apache.coyote.http11.Http11Protocol start
信息: Starting Coyote HTTP/1.1 on http-8080
七月 21, 2016 4:37:37 下午 org.apache.jk.common.ChannelSocket init
信息: JK: ajp13 listening on /0.0.0.0:8009
七月 21, 2016 4:37:37 下午 org.apache.jk.server.JkMain start
信息: Jk running ID=0 time=0/41 config=null
七月 21, 2016 4:37:37 下午 org.apache.catalina.startup.Catalina start
信息: Server startup in 3653 ms

7 回复

jdk找到呀 C:\Program Files\Java\jdk1.7.0_79路径存在没?!

用的tomcat是啥版本的?servlet-api-2.5.jar删除试试,你配置项目的servlet-api.jar为tomcat的servlet-api.jar

jdk 7的环境用tomcat 7跑吧 或是把jdk环境改成1.6 你用的是tomcat 6

那是mysql最新驱动与druid的兼容性问题,只是个提醒,不是报错

来自炫酷的 NutzCN

添加回复
请先登陆
回到顶部