Re: [jboss-dev-forums] [JBoss AS7 Development] - Data Source Configuration in AS 7
by Karsten Wutzke
Karsten Wutzke [http://community.jboss.org/people/kwutzke] commented on the document
"Data Source Configuration in AS 7"
To view all comments on this document, visit: http://community.jboss.org/docs/DOC-16657#comment-7160
--------------------------------------------------
Sorry for interrupting.
As for the *standalone* setup, the driver name *is* the file name of the JAR dropped into /standalone/deployments according to http://docs.jboss.org/ironjacamar/userguide/1.0/en-US/html/deployment.htm... http://docs.jboss.org/ironjacamar/userguide/1.0/en-US/html/deployment.htm... (Table 5.13, driver description).
However, I'm still facing two problems. For whatever reason, at server startup the datasource is never configured on the first try:
04:00:55,224 INFO [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-3) Bound data source [java:jboss/datasources/ExampleDS]
04:00:55,238 INFO [org.jboss.as.deployment] (MSC service thread 1-2) Started FileSystemDeploymentService for directory C:\dev\jboss7\standalone\deployments
04:00:55,244 INFO [org.jboss.as.deployment] (DeploymentScanner-threads - 1) Found bbstats.war in deployment directory. To trigger deployment create a file called bbstats.war.dodeploy
04:00:55,456 INFO [org.jboss.as.controller] (Controller Boot Thread) Service status report
New missing/unsatisfied dependencies:
service jboss.jdbc-driver.mysql-connector-java-5_1_13-bin_jar (missing)
04:00:55,496 INFO [org.jboss.as.server.deployment] (MSC service thread 1-1) Starting deployment of "mysql-connector-java-5.1.13-bin.jar"
04:00:55,716 INFO [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-1) Deploying non-JDBC-compliant driver class com.mysql.jdbc.Driver (version 5.1)
04:00:55,727 INFO [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-4) Bound data source [java:jboss/datasources/BBStatsDS]
04:00:55,728 INFO [org.jboss.as] (MSC service thread 1-4) JBoss AS 7.0.0.Final "Lightning" started in 3213ms - Started 112 of 169 services (57 services are passive or on-demand)
04:00:55,783 INFO [org.jboss.as.server.controller] (DeploymentScanner-threads - 2) Deployed "mysql-connector-java-5.1.13-bin.jar"
04:00:55,783 INFO [org.jboss.as.controller] (DeploymentScanner-threads - 2) Service status report
Newly corrected services:
service jboss.jdbc-driver.mysql-connector-java-5_1_13-bin_jar (now available)
Then, as you can see from the "
Deploying non-JDBC-compliant driver class com.mysql.jdbc.Driver (version 5.1)" my driver is also flagged to be non-JDBC, but it clearly is JDBC 4-compliant.
--------------------------------------------------
13 years, 5 months
Re: [jboss-dev-forums] [JBoss AS7 Development] - Data Source Configuration in AS 7
by Gerry Matte
Gerry Matte [http://community.jboss.org/people/gerry.matte] commented on the document
"Data Source Configuration in AS 7"
To view all comments on this document, visit: http://community.jboss.org/docs/DOC-16657#comment-7157
--------------------------------------------------
It's a small thing but I noticed that when the mysql datasource is created by jboss 7, the console log states it is deploying a non-JDBC-compliant driver class com.mysql.jdbc.Driver (the driver name included in the META-INF/services/java.sql.Driver file).
This notation appears with both mysql-connector-java-5.1.15-bin.jar and mysql-connector-java-5.1.17-bin.jar
Mysql claims that it's driver is compliant with jdbc 4.0
What is causing JBoss to claim the driver isn't jdbc compliant ?
--------------------------------------------------
13 years, 5 months
[IronJacamar Development] - Cannot configure valid-connection-checker, causes ClassNotFoundException
by Takayoshi Kimura
Takayoshi Kimura [http://community.jboss.org/people/tkimura] created the discussion
"Cannot configure valid-connection-checker, causes ClassNotFoundException"
To view the discussion, visit: http://community.jboss.org/message/616895#616895
--------------------------------------------------------------
I'm trying to implement JBJCA-634 and hit an issue.
Support query timeout for check-valid-connection-sql
https://issues.jboss.org/browse/JBJCA-634 https://issues.jboss.org/browse/JBJCA-634
When I configured valid-connection-checker with NullValidConnectionChecker for testing purpose, I got this exception:
12:01:35,859 WARN [org.jboss.jca.adapters.jdbc.local.LocalManagedConnectionFactory] (JBossConnectionValidator) Exception trying to create connection checker (disabling):: java.lang.ClassNotFoundException: org.jboss.jca.adapters.jdbc.extensions.novendor.NullValidConnectionChecker from [Module "org.jboss.ironjacamar.impl:main" from local module loader @12b7eea (roots: /home/nekop/usr/src/as7/build/target/jboss-as-7.1.0.Alpha1-SNAPSHOT/modules)]
at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:191)
at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:358)
at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:307)
at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:101)
at org.jboss.jca.adapters.jdbc.BaseWrapperManagedConnectionFactory.isValidConnection(BaseWrapperManagedConnectionFactory.java:1034)
at org.jboss.jca.adapters.jdbc.BaseWrapperManagedConnection.checkValid(BaseWrapperManagedConnection.java:449)
at org.jboss.jca.adapters.jdbc.BaseWrapperManagedConnectionFactory.getInvalidConnections(BaseWrapperManagedConnectionFactory.java:918)
at org.jboss.jca.core.connectionmanager.pool.mcp.SemaphoreArrayListManagedConnectionPool.validateConnections(SemaphoreArrayListManagedConnectionPool.java:800) [ironjacamar-core-impl-1.0.0.Final.jar:1.0.0.Final]
at org.jboss.jca.core.connectionmanager.pool.validator.ConnectionValidator$JBossConnectionValidator.run(ConnectionValidator.java:269) [ironjacamar-core-impl-1.0.0.Final.jar:1.0.0.Final]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [:1.6.0_22]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [:1.6.0_22]
at java.lang.Thread.run(Thread.java:679) [:1.6.0_22]
And here is my datasource config:
<datasource jndi-name="java:jboss/datasources/ExampleDS" enabled="true" use-java-context="true" pool-name="H2DS" spy="true">
<connection-url>jdbc:h2:mem:test;DB_CLOSE_DELAY=-1</connection-url>
<driver>h2</driver>
<pool>
<min-pool-size>2</min-pool-size>
<max-pool-size>10</max-pool-size>
<prefill>true</prefill>
</pool>
<security>
<user-name>sa</user-name>
<password>sa</password>
</security>
<validation>
<valid-connection-checker class-name="org.jboss.jca.adapters.jdbc.extensions.novendor.NullValidConnectionChecker"/>
<!--
<valid-connection-checker class-name="org.jboss.jca.adapters.jdbc.CheckValidConnectionSQL">
<config-property name="sql">SELECT 1</config-property>
<config-property name="queryTimeout">20</config-property>
</valid-connection-checker>
-->
<validate-on-match>true</validate-on-match>
<background-validation>true</background-validation>
<background-validation-minutes>1</background-validation-minutes>
</validation>
<timeout></timeout>
<statement></statement>
</datasource>
I've tested this with both AS7 Final and AS7 upstream and got same result.
Is this a config issue or a known bug?
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/616895#616895]
Start a new discussion in IronJacamar Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 5 months