[jboss-jira] [JBoss JIRA] (AS7-6565) single jdbc driver deployed inside ear takes name of ear

Stefano Maestri (JIRA) jira-events at lists.jboss.org
Wed Feb 27 05:34:56 EST 2013


    [ https://issues.jboss.org/browse/AS7-6565?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12757121#comment-12757121 ] 

Stefano Maestri commented on AS7-6565:
--------------------------------------

Last PR changes implement this driver-name this way:
1) in case the archive is a jar and contains only one driver driver-name==jarName (as was before)
2) in case the archive is not a jar and/or it cointains more than one driver driver-name==deploymentUnit.getName() + "_" + driverClassName + "_" + majorVersion +"_" + minorVersion
3) added info level logs saying "JBAS010417: Started Driver service with driver-name = postgresql-9.0-801.jdbc4.jar" or "JBAS010417: Started Driver service with driver-name = test.ear_org.postgresql.Driver_9_0" and logging also stop of those services for example: "JBAS010418: Stopped Driver service with driver-name = postgresql-9.0-801.jdbc4.jar" or "JBAS010418: Stopped Driver service with driver-name = h2"

it should guarantee backward compatibility for single driver jar deployment (the most used case), while is fixing the obscure naming in case of single driver deployed as part of an ear. 
                
> single jdbc driver deployed inside ear takes name of ear
> --------------------------------------------------------
>
>                 Key: AS7-6565
>                 URL: https://issues.jboss.org/browse/AS7-6565
>             Project: Application Server 7
>          Issue Type: Feature Request
>          Components: JCA
>    Affects Versions: 7.1.1.Final, 8.0.0.Alpha1
>            Reporter: Tom Eicher
>            Assignee: Stefano Maestri
>
> We need to always give service name for jdbdriver as 
> {code}
> deploymentUnit.getName() + "_" + driverClassName + "_" + majorVersion +"_" + minorVersion
> {code}
> even if thre is only one driver in the deployment unit. Current behavior is to give just deploymentUnit name in case of only one driver in. The changes makes more clear/readable driver names.
> Original description was:
> Including a JDBC driver, in this case PostgreSQL, in an ear like
> {code}
> myapp.ear:
> lib/postgresql-9.1-901.jdbc4.jar
> {code}
> does deploy the driver:
> {code}
> 23:37:28,118 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-1) JBAS010404: Deploying non-JDBC-compliant driver class org.postgresql.Driver (version 9.1)
> {code}
> however the service name is not {{postgresql_9_1_901_jdbc4_jar}} as expected,
> but it's {{myapp_ear}}.
> (Seen in admin console, and this is the only value accepted in my -ds.xml file.)
> 1. JDBC driver service should pick name of innermost jar, not of containing ear
> 2. driver name (as to be used in datasource definition) should be logged with the log message above.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jboss-jira mailing list