C3P0连接池异常

解决方案:

将c3p0.jar包换成c3p0-0.9.0.2.jar,c3p0这个包应该有bug

引用如下:

com.mchange.v2.log.MLog

Determines which library c3p0 will output log messages to. By default, if
log4j is available, it will use that library, ...

引用网址:https://bugzilla.redhat.com/show_bug.cgi?id=735460

?





1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

57

58

59

60

61

62

63

64

65

66

67

68

69

70

71

72

73

74

75

76

77

78

79

80

81

82

83

84

85

86

87

88

89

90

91

92

93

94

95

96

97

98

99

100

101

102

103

104

105

106

107

108

109

110

111

112

113

114

115

116

117

118

119

120

121

122

123

124

125

126

127

128

129

130

131

132

133

134

135

136

137

138

139

140

141

142

143

144

145

146

147

148

149

150

151

152

153

154

155

156

157

158

159

160

161

162

163

164

165

166

167

168

169

170

171

172

173

174

175

176

177

178

179

180

181

182

183

184

185

186

187

188

189

190

191

192

193

194

195

196

197

198

199

200

201

202

203

204

205

206

207

208

209

210

211

212

213

214

215

216

217

218

219

220

221

222

223

224

225

226

227

228

229

230

231

232

233

234

235

236

237

238

239

240

241

242

243

244

245

246

247

248

249

250

251

252

253

254

255

256

257

258

259

260

261

262

263

264

265

266

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jstl/core_rt is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jstl/core is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/core is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jstl/fmt_rt is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jstl/fmt is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/fmt is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/functions is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://jakarta.apache.org/taglibs/standard/permittedTaglibs is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://jakarta.apache.org/taglibs/standard/scriptfree is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jstl/sql_rt is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jstl/sql is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/sql is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jstl/xml_rt is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jstl/xml is already defined

2014-6-2
15:48:54
org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/xml is already defined

2014-6-2
15:48:54
com.sun.faces.config.ConfigureListener contextInitialized

信息: 初始化上下文 ‘/Parameters‘
的 Mojarra 2.0.3
(FCS b03)

2014-6-2
15:48:55
com.sun.faces.spi.InjectionProviderFactory createInstance

信息: JSF1048:有 PostConstruct/PreDestroy 注释。标有这些注释的 ManagedBeans 方法将表示注释已处理。

2014-6-2
15:48:55
com.opensymphony.xwork2.util.logging.commons.CommonsLogger info

信息: Parsing configuration file [struts-default.xml]

2014-6-2
15:48:56
com.opensymphony.xwork2.util.logging.commons.CommonsLogger info

信息: Parsing configuration file [struts-plugin.xml]

2014-6-2
15:48:56
com.opensymphony.xwork2.util.logging.commons.CommonsLogger info

信息: Parsing configuration file [struts.xml]

2014-6-2
15:48:56
com.opensymphony.xwork2.util.logging.commons.CommonsLogger info

信息: Overriding property struts.i18n.reload - old value: false
new value: true

2014-6-2
15:48:56
com.opensymphony.xwork2.util.logging.commons.CommonsLogger info

信息: Overriding property struts.configuration.xml.reload - old value: false
new value: true

2014-6-2
15:48:56
org.apache.catalina.startup.HostConfig deployDirectory

信息: Deploying web application directory D:\SoftwareDeveloping\tomcat7.0.35\webapps\ROOT

2014-6-2
15:48:56
org.apache.catalina.startup.HostConfig deployDirectory

信息: Deploying web application directory D:\SoftwareDeveloping\tomcat7.0.35\webapps\StudentLifeSupportPlatformSystem

2014-06-02
15:48:56
Test: Directory ‘F:\Workplace\Myeclipse\StudentLifeSupportPlatformSystem\WebRoot\WEB-INF\classes‘
will be monitored for
changes.

2014-06-02
15:48:56
Test: Directory ‘F:\Workplace\Myeclipse\StudentLifeSupportPlatformSystem\WebRoot‘
will be monitored for
changes.

2014-06-02
15:48:59
Test: Monitoring Log4j configuration in ‘file:/F:/Workplace/Myeclipse/StudentLifeSupportPlatformSystem/WebRoot/WEB-INF/classes/log4j.properties‘.

2014-6-2
15:48:59
org.apache.catalina.core.ApplicationContext log

信息: Initializing Spring root WebApplicationContext

INFO  org.springframework.web.context.ContextLoader

Root WebApplicationContext: initialization started

INFO  org.springframework.web.context.support.XmlWebApplicationContext

Refreshing org.springframework.web.context.support.XmlWebApplicationContext@5c816a7d: display name [Root WebApplicationContext]; startup date [Mon Jun 02
15:49:00
CST 2014]; root of context hierarchy

2014-06-02
15:49:00
Test: Monitoring Spring bean definitions in ‘F:\Workplace\Myeclipse\StudentLifeSupportPlatformSystem\WebRoot\WEB-INF\classes\beans.xml‘.

INFO  org.springframework.beans.factory.xml.XmlBeanDefinitionReader

Loading XML bean definitions from class
path resource [beans.xml]

INFO  org.springframework.web.context.support.XmlWebApplicationContext

Bean factory for
application context [org.springframework.web.context.support.XmlWebApplicationContext@5c816a7d]: org.springframework.beans.factory.support.DefaultListableBeanFactory@263608aa

INFO  org.springframework.beans.factory.support.DefaultListableBeanFactory

Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@263608aa: defining beans [sessionFactory,hibernateTemplate,org.springframework.context.annotation.internalPersistenceAnnotationProcessor,org.springframework.context.annotation.internalCommonAnnotationProcessor,org.springframework.context.annotation.internalAutowiredAnnotationProcessor,org.springframework.context.annotation.internalRequiredAnnotationProcessor,org.springframework.aop.config.internalAutoProxyCreator,org.springframework.transaction.annotation.AnnotationTransactionAttributeSource#0,org.springframework.transaction.interceptor.TransactionInterceptor#0,org.springframework.transaction.config.internalTransactionAdvisor,transactionManager,transactionAdvice,org.springframework.aop.support.DefaultBeanFactoryPointcutAdvisor#0]; root of factory hierarchy

INFO  org.hibernate.cfg.annotations.Version

Hibernate Annotations 3.4.0.GA

INFO  org.hibernate.cfg.Environment

Hibernate 3.3.2.GA

INFO  org.hibernate.cfg.Environment

hibernate.properties not found

INFO  org.hibernate.cfg.Environment

Bytecode provider name : javassist

INFO  org.hibernate.cfg.Environment

using JDK 1.4
java.sql.Timestamp handling

INFO  org.hibernate.annotations.common.Version

Hibernate Commons Annotations 3.1.0.GA

INFO  org.hibernate.cfg.Configuration

configuring from url: file:/F:/Workplace/Myeclipse/StudentLifeSupportPlatformSystem/WebRoot/WEB-INF/classes/hibernate.cfg.xml

INFO  org.hibernate.cfg.Configuration

Configured SessionFactory: null

INFO  org.hibernate.cfg.AnnotationBinder

Binding entity from annotated class: student.life.support.platform.model.Credit

INFO  org.hibernate.cfg.annotations.EntityBinder

Bind entity student.life.support.platform.model.Credit on table credit

INFO  org.hibernate.cfg.AnnotationBinder

Binding entity from annotated class: student.life.support.platform.model.HelpInfo

INFO  org.hibernate.cfg.annotations.EntityBinder

Bind entity student.life.support.platform.model.HelpInfo on table help_info

INFO  org.hibernate.cfg.AnnotationBinder

Binding entity from annotated class: student.life.support.platform.model.HelpInfoBoard

INFO  org.hibernate.cfg.annotations.EntityBinder

Bind entity student.life.support.platform.model.HelpInfoBoard on table help_info_board

INFO  org.hibernate.cfg.AnnotationBinder

Binding entity from annotated class: student.life.support.platform.model.OperatingHistory

INFO  org.hibernate.cfg.annotations.EntityBinder

Bind entity student.life.support.platform.model.OperatingHistory on table operating_history

INFO  org.hibernate.cfg.AnnotationBinder

Binding entity from annotated class: student.life.support.platform.model.ReplyInfo

INFO  org.hibernate.cfg.annotations.EntityBinder

Bind entity student.life.support.platform.model.ReplyInfo on table reply_info

INFO  org.hibernate.cfg.AnnotationBinder

Binding entity from annotated class: student.life.support.platform.model.Role

INFO  org.hibernate.cfg.annotations.EntityBinder

Bind entity student.life.support.platform.model.Role on table role

INFO  org.hibernate.cfg.AnnotationBinder

Binding entity from annotated class: student.life.support.platform.model.User

INFO  org.hibernate.cfg.annotations.EntityBinder

Bind entity student.life.support.platform.model.User on table user

INFO  org.hibernate.cfg.annotations.CollectionBinder

Mapping collection: student.life.support.platform.model.HelpInfoBoard.helpInfos -> help_info

INFO  org.hibernate.cfg.annotations.CollectionBinder

Mapping collection: student.life.support.platform.model.Role.users -> user

INFO  org.hibernate.cfg.annotations.CollectionBinder

Mapping collection: student.life.support.platform.model.User.credits -> credit

INFO  org.hibernate.cfg.annotations.CollectionBinder

Mapping collection: student.life.support.platform.model.User.helpInfoBoards -> help_info_board

INFO  org.hibernate.cfg.annotations.CollectionBinder

Mapping collection: student.life.support.platform.model.User.helpInfos -> help_info

INFO  org.hibernate.cfg.annotations.CollectionBinder

Mapping collection: student.life.support.platform.model.User.operatingHistories -> operating_history

INFO  org.hibernate.cfg.annotations.CollectionBinder

Mapping collection: student.life.support.platform.model.User.replyInfos -> reply_info

INFO  org.hibernate.validator.Version

Hibernate Validator 3.1.0.GA

INFO  org.springframework.orm.hibernate3.annotation.AnnotationSessionFactoryBean

Building new
Hibernate SessionFactory

INFO  org.hibernate.cfg.search.HibernateSearchEventListenerRegister

Unable to find org.hibernate.search.event.FullTextIndexEventListener on the classpath. Hibernate Search is not enabled.

INFO  org.hibernate.connection.ConnectionProviderFactory

Initializing connection provider: org.hibernate.connection.C3P0ConnectionProvider

INFO  org.hibernate.connection.C3P0ConnectionProvider

C3P0 using driver: com.mysql.jdbc.Driver at URL: jdbc:hsqldb:hsql://localhost:3306/studentlifesupportplatform

INFO  org.hibernate.connection.C3P0ConnectionProvider

Connection properties: {user=root, password=****}

INFO  org.hibernate.connection.C3P0ConnectionProvider

autocommit mode: false

INFO  org.springframework.beans.factory.support.DefaultListableBeanFactory

Destroying singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@263608aa: defining beans [sessionFactory,hibernateTemplate,org.springframework.context.annotation.internalPersistenceAnnotationProcessor,org.springframework.context.annotation.internalCommonAnnotationProcessor,org.springframework.context.annotation.internalAutowiredAnnotationProcessor,org.springframework.context.annotation.internalRequiredAnnotationProcessor,org.springframework.aop.config.internalAutoProxyCreator,org.springframework.transaction.annotation.AnnotationTransactionAttributeSource#0,org.springframework.transaction.interceptor.TransactionInterceptor#0,org.springframework.transaction.config.internalTransactionAdvisor,transactionManager,transactionAdvice,org.springframework.aop.support.DefaultBeanFactoryPointcutAdvisor#0]; root of factory hierarchy

2014-6-2
15:49:02
org.apache.catalina.core.StandardContext listenerStart

严重: Exception sending context initialized event to listener instance of class
org.springframework.web.context.ContextLoaderListener

org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘sessionFactory‘
defined in class
path resource [beans.xml]: Invocation of init method failed; nested exception is java.lang.NoClassDefFoundError: com/mchange/v2/log/MLog

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1338)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:473)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409)

    at java.security.AccessController.doPrivileged(Native Method)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380)

    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:264)

    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)

    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261)

    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185)

    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164)

    at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:423)

    at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:728)

    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:380)

    at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:255)

    at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)

    at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)

    at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4797)

    at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5291)

    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)

    at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)

    at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)

    at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:633)

    at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1114)

    at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1673)

    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)

    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)

    at java.util.concurrent.FutureTask.run(FutureTask.java:138)

    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)

    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)

    at java.lang.Thread.run(Thread.java:662)

Caused by: java.lang.NoClassDefFoundError: com/mchange/v2/log/MLog

    at com.mchange.v2.c3p0.DataSources.<clinit>(DataSources.java:72)

    at org.hibernate.connection.C3P0ConnectionProvider.configure(C3P0ConnectionProvider.java:176)

    at org.hibernate.connection.ConnectionProviderFactory.newConnectionProvider(ConnectionProviderFactory.java:137)

    at org.hibernate.connection.ConnectionProviderFactory.newConnectionProvider(ConnectionProviderFactory.java:79)

    at org.hibernate.cfg.SettingsFactory.createConnectionProvider(SettingsFactory.java:425)

    at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:89)

    at org.hibernate.cfg.Configuration.buildSettingsInternal(Configuration.java:2119)

    at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:2115)

    at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1339)

    at org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:867)

    at org.springframework.orm.hibernate3.LocalSessionFactoryBean.newSessionFactory(LocalSessionFactoryBean.java:814)

    at org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(LocalSessionFactoryBean.java:732)

    at org.springframework.orm.hibernate3.AbstractSessionFactoryBean.afterPropertiesSet(AbstractSessionFactoryBean.java:211)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1369)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1335)

    ... 29
more

Caused by: java.lang.ClassNotFoundException: com.mchange.v2.log.MLog

    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1714)

    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1559)

    ... 44
more

ERROR  org.springframework.web.context.ContextLoader

Context initialization failed

org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘sessionFactory‘
defined in class
path resource [beans.xml]: Invocation of init method failed; nested exception is java.lang.NoClassDefFoundError: com/mchange/v2/log/MLog

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1338)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:473)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409)

    at java.security.AccessController.doPrivileged(Native Method)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380)

    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:264)

    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)

    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261)

    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185)

    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164)

    at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:423)

    at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:728)

    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:380)

    at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:255)

    at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)

    at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)

    at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4797)

    at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5291)

    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)

    at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)

    at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)

    at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:633)

    at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1114)

    at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1673)

    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)

    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)

    at java.util.concurrent.FutureTask.run(FutureTask.java:138)

    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)

    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)

    at java.lang.Thread.run(Thread.java:662)

Caused by: java.lang.NoClassDefFoundError: com/mchange/v2/log/MLog

    at com.mchange.v2.c3p0.DataSources.<clinit>(DataSources.java:72)

    at org.hibernate.connection.C3P0ConnectionProvider.configure(C3P0ConnectionProvider.java:176)

    at org.hibernate.connection.ConnectionProviderFactory.newConnectionProvider(ConnectionProviderFactory.java:137)

    at org.hibernate.connection.ConnectionProviderFactory.newConnectionProvider(ConnectionProviderFactory.java:79)

    at org.hibernate.cfg.SettingsFactory.createConnectionProvider(SettingsFactory.java:425)

    at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:89)

    at org.hibernate.cfg.Configuration.buildSettingsInternal(Configuration.java:2119)

    at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:2115)

    at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1339)

    at org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:867)

    at org.springframework.orm.hibernate3.LocalSessionFactoryBean.newSessionFactory(LocalSessionFactoryBean.java:814)

    at org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(LocalSessionFactoryBean.java:732)

    at org.springframework.orm.hibernate3.AbstractSessionFactoryBean.afterPropertiesSet(AbstractSessionFactoryBean.java:211)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1369)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1335)

    ... 29
more

Caused by: java.lang.ClassNotFoundException: com.mchange.v2.log.MLog

    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1714)

    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1559)

    ... 44
more

2014-6-2
15:49:02
com.sun.faces.config.ConfigureListener contextInitialized

信息: 初始化上下文 ‘/StudentLifeSupportPlatformSystem‘
的 Mojarra 2.0.3
(FCS b03)

2014-6-2
15:49:03
com.sun.faces.spi.InjectionProviderFactory createInstance

信息: JSF1048:有 PostConstruct/PreDestroy 注释。标有这些注释的 ManagedBeans 方法将表示注释已处理。

2014-6-2
15:49:03
org.apache.catalina.core.StandardContext startInternal

严重: Error listenerStart

2014-6-2
15:49:03
org.apache.catalina.core.StandardContext startInternal

严重: Context [/StudentLifeSupportPlatformSystem] startup failed due to previous errors

2014-6-2
15:49:03
org.apache.catalina.core.ApplicationContext log

信息: Closing Spring root WebApplicationContext

2014-6-2
15:49:03
org.apache.catalina.loader.WebappClassLoader clearReferencesJdbc

严重: The web application [/StudentLifeSupportPlatformSystem] registered the JDBC driver [com.mysql.jdbc.Driver] but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDBC Driver has been forcibly unregistered.

2014-6-2
15:49:03
org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks

严重: The web application [/StudentLifeSupportPlatformSystem] created a ThreadLocal with key of type [com.sun.faces.util.Util$1] (value [com.sun.faces.util.Util$1@45f3666b]) and a value of type [java.util.HashMap] (value [{com.sun.faces.patternCache={ = }}]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try
and avoid a probable memory leak.

2014-6-2
15:49:03
org.apache.coyote.AbstractProtocol start

信息: Starting ProtocolHandler ["http-bio-8080"]

2014-6-2
15:49:03
org.apache.coyote.AbstractProtocol start

信息: Starting ProtocolHandler ["ajp-bio-8009"]

2014-6-2
15:49:03
org.apache.catalina.startup.Catalina start

信息: Server startup in 13326
ms

  

欢迎讨论交流, 我的主页:http://www.cnblogs.com/GDUT/

我的邮箱:[email protected]

时间: 2024-10-03 22:47:22

C3P0连接池异常的相关文章

一次c3p0连接池连接异常错误的排查

最近写了一个数据库采集程序,大概过程是将SQLSERVER数据库的数据定时采集到Oracle数据库.1小时出一次数据,每次数据量在2W左右.环境采用Sping3+hibernate4,数据库连接池采用C3p0 奇怪的时候每隔一段时间都会报:"c3p0 connection is already closed" 我开始的数据库连接池配置如下:oracle数据库开启事务,而采集的sqlserver数据库没有开启事务 jdbc.driverClass=oracle.jdbc.OracleDr

Maven 工程下 Spring MVC 站点配置 (三) C3P0连接池与@Autowired的应用

Maven 工程下 Spring MVC 站点配置 (一) Maven 工程下 Spring MVC 站点配置 (二) Mybatis数据操作 前两篇文章主要是对站点和数据库操作配置进行了演示,如果单单实现这两个需求的话,那么基本足够,但是很多时候一个网站除了仅仅能够访问数据库是不够的,它还需要对性能以及更简化的步骤有着更多的要求,这一篇重点就是帮助我们如何去实现数据连接池管理与更简化便利的开发步骤. 如果你觉得自己能写出更高效率的连接池,那你可以不需要这篇文章了,我更建议你可以去开源组织毛遂自

c3p0连接池 &amp; JdbcUtils

一.引入jar包 二.java代码 1 @Test 2 public void testXML() throws Exception { 3 // 创建c3p0连接池核心工具类 4 // 自动加载src下c3p0的配置文件[c3p0-config.xml] 5 ComboPooledDataSource dataSource = new ComboPooledDataSource();// 使用默认的配置 6 PreparedStatement pstmt = null; 7 8 // 获取连接

c3p0连接池的学习

c3p0的学习 学习 学习 ! 首先c3p0的基本了解,在之前的web项目学习中都是直接使用jdbc的 DriverManager进行oracle数据库的连接,每次执行操作都会建立一个新的连接,在操作完成后,通过判断释放连接,但是如果处于高并发的情况下,就可能会造成服务器崩溃的后果,因为大量的资源同一时间得不到释放:以上是我自己对普通连接的学习和看法,采用c3p0连接池后,连接池会控制连接池内的连接对象数,以下是c3p0的xml配置文件: 1 <?xml version="1.0"

网络协议 finally{ return问题 注入问题 jdbc注册驱动问题 PreparedStatement 连接池目的 1.2.1DBCP连接池 C3P0连接池 MYSQL两种方式进行实物管理 JDBC事务 DBUtils事务 ThreadLocal 事务特性 并发访问 隔离级别

1.1.1 API详解:注册驱动 DriverManager.registerDriver(new com.mysql.jdbc.Driver());不建议使用 原因有2个: >导致驱动被注册2次. >强烈依赖数据库的驱动jar 解决办法: Class.forName("com.mysql.jdbc.Driver"); 1.1.2 API详解:java.sql.Statement接口: 操作sql语句,并返回相应结果 String sql = "某SQL语句&qu

DBCP连接池与c3p0连接池

1.   DBCP连接池 2.  c3p0连接池(参见上一篇的使用步骤http://www.cnblogs.com/qlqwjy/p/7545012.html)

14、Hibernate对c3p0连接池的配置

1.Hibernate3的c3p0连接池的配置 在hibernate.cfg.xml中配置如下信息: <!-- 1. 数据库连接配置 --> <property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property> <property name="hibernate.connection.url">jdbc:mysql:///

c3p0连接池的使用

C3P0:(★) hibernate和spring使用 有自动回收空闲连接的功能. 使用步骤: 1.导入jar包(c3p0-0.9.1.2.jar) 2.使用api a.硬编码(不推荐) new ComboPooledDataSource() b.配置文件 配置文件的名称:c3p0.properties 或者 c3p0-config.xml 配置文件的路径:src下 配置文件中的名字要少用:c3p0.user()格式 编码只需要一句话 new ComboPooledDataSource()//使

C3P0连接池一些基本配置

1 C3P0连接池配置 2 数据库连接是一个耗费大量资源且相当慢的操作,所以为了提高性能和连接速度,诞生了连接池这样的概念. 3 在多用户并发操作过程中,连接池尤为重要. 4 它是将那些已连接的数据库连接存放在一个容器里(连接池),这样以后别人要连接数据库的时候,将不会重新建立数据库连接,会直接从连接池里取出可用的连接,用户使用完毕后,连接又重新还回到连接池中. 5 注意:连接池里的连接将会一直保存在内存里,即使你没用也是一样.所以这个时候你得权衡一下连接池的连接数量了. 6 7 <c3p0-c