This week's book giveaway is in the Java in General forum.
We're giving away four copies of Think Java: How to Think Like a Computer Scientist and have Allen B. Downey & Chris Mayfield on-line!
See this thread for details.
Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

a database question on deploying jforum

 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I deployed jforum ver2.1.8 with MySQL.
Database connecting type is JDBC,It work normally on the page,but I saw Exceptions in the Tomcat console.
I wanna know why!!!
The Exception is following:
20:21:41,328 INFO [C3P0Registry ] jdk1.5 management interfaces unavailable... JMX support disabled.
java.lang.ClassNotFoundException: java.lang.management.ManagementFactory
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1340)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1189)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:141)
at com.mchange.v2.c3p0.C3P0Registry.<clinit>(C3P0Registry.java:98)
at com.mchange.v2.c3p0.impl.PoolBackedDataSourceBase.<init>(PoolBackedDataSourceBase.java:228)
at com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.<init>(AbstractPoolBackedDataSource.java:59)
at com.mchange.v2.c3p0.ComboPooledDataSource.<init>(ComboPooledDataSource.java:94)
at com.mchange.v2.c3p0.ComboPooledDataSource.<init>(ComboPooledDataSource.java:90)
at net.jforum.C3P0PooledConnection.init(C3P0PooledConnection.java:69)
at net.jforum.ForumStartup.startDatabase(ForumStartup.java:75)
at net.jforum.JForum.init(JForum.java:95)
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1029)
at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:687)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:144)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
at java.lang.Thread.run(Thread.java:534)
20:21:41,343 INFO [C3P0Registry ] Initializing c3p0-0.9.1-pre9 [built 23-September-2006 01:47:24; debug? true; trace: 10]
20:21:41,453 INFO [AbstractPoolBackedDataSource] Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttem
pts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 120000, conn
ectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 14c28db, debugUnreturnedConn
ectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false,
identityToken -> 14c28db, idleConnectionTestPeriod -> 3600, initialPoolSize ->3, jdbcUrl -> jdbc:mysql://localhost:3306/jforum?user=jforum&password=jforum&aut
oReconnect=true&useNewIO=false&zeroDateTimeBehavior=convertToNull&useServerPrepStmts=false&dumpQueriesOnException=true&jdbcCompliantTruncation=false, maxAdminis
trativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 0, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 10, maxStatements -> 0, maxStatementsPerConnect
ion -> 0, minPoolSize -> 5, numHelperThreads -> 3, preferredTestQuery -> null, properties -> {}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConne
ctionOnCheckout -> false, unreturnedConnectionTimeout -> 180, usesTraditionalReflectiveProxies -> false ]
20:21:42,078 INFO [ConfigLoader ] Loading clickstream config from C:\Tomcat 5.0\webapps\jforum/WEB-INF/config/clickstream-jforum.xml
20:21:58,656 WARN [beans ] Couldn't properly perform introspection
java.beans.IntrospectionException: type mismatch between indexed and non-indexed methods
at java.beans.IndexedPropertyDescriptor.findIndexedPropertyType(IndexedPropertyDescriptor.java:193)
at java.beans.IndexedPropertyDescriptor.<init>(IndexedPropertyDescriptor.java:102)
at freemarker.ext.beans.BeansWrapper.populateClassMapWithBeanInfo(BeansWrapper.java:1107)
at freemarker.ext.beans.BeansWrapper.populateClassMap(BeansWrapper.java:1017)
at freemarker.ext.beans.BeansWrapper.introspectClassInternal(BeansWrapper.java:955)
at freemarker.ext.beans.BeansWrapper.introspectClass(BeansWrapper.java:928)
at freemarker.ext.beans.BeanModel.<init>(BeanModel.java:139)
at freemarker.ext.beans.StringModel.<init>(StringModel.java:90)
at freemarker.ext.beans.StringModel$1.create(StringModel.java:75)
at freemarker.ext.util.ModelCache.getInstance(ModelCache.java:113)
at freemarker.ext.beans.BeansWrapper.wrap(BeansWrapper.java:459)
at freemarker.ext.beans.BeanModel.wrap(BeanModel.java:319)
at freemarker.ext.beans.IteratorModel.next(IteratorModel.java:134)
at freemarker.core.IteratorBlock$Context.runLoop(IteratorBlock.java:157)
at freemarker.core.Environment.visit(Environment.java:351)
at freemarker.core.IteratorBlock.accept(IteratorBlock.java:95)
at freemarker.core.Environment.visit(Environment.java:196)
at freemarker.core.MixedContent.accept(MixedContent.java:92)
at freemarker.core.Environment.visit(Environment.java:196)
at freemarker.core.Environment.process(Environment.java:176)
at freemarker.template.Template.process(Template.java:232)
at net.jforum.JForum.processCommand(JForum.java:233)
at net.jforum.JForum.service(JForum.java:200)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at net.jforum.util.legacy.clickstream.ClickstreamFilter.doFilter(ClickstreamFilter.java:59)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
at java.lang.Thread.run(Thread.java:534)
[originally posted on jforum.net by sunzx]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hm, your VM is complaining about the lack of JMX support. Which JVM version are you using? Have you tried an upgrade? (just a matter of testing)

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It could also be due to having JMX support jar files in more than one Tomcat application lib. E.g., a copy in the local web-app/lib directory and a copy in the shared/lib. Or that the lib is not at the correct "security level" that the calling code needs.

Tomcat's class loader security will produce errors like this if a "system level" object (e.g. in the shared/lib, common/lib, or system/lib) needs to do a dynamic creation of a class. This is because the creating class can only access objects at or above it's security level. This keeps applications from replacing system level code with "hacked" version.

There are also some conditions where application level code can't access objects loaded in a higher classloader.

You may need to play around with what jars are in what lib directory.
[originally posted on jforum.net by monroe]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Rafael Steil wrote:Hm, your VM is complaining about the lack of JMX support. Which JVM version are you using? Have you tried an upgrade? (just a matter of testing)

Rafael


My JVM version is 1.4.2 , Does it have a support with JMX?
if not, how I can fix it without upgrading my JVM.
BTY, my Tomcat version is 5.0.28 .

[originally posted on jforum.net by sunzx]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I seem to remember that "embedded" JMX support only started with TC 5.5 / JVM 1.5. If you wanted JMX support you had to download and install the java extention packages, a set of jar files that go in your classlib path or in the JVM extensions area.

This is available on Sun's site.
[originally posted on jforum.net by monroe]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thx,Rafael Steil and monroe.
I will try after upgrading my JVM and Tomcat.
[originally posted on jforum.net by sunzx]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic