Details
-
Bug
-
Resolution: Fixed
-
Highest
-
6.0.0-rc2
-
Severity 1 - Critical
-
Description
Synchrony generates wrong credentials when connecting to database, if Confluence is configured using a JNDI datasource.
We use a Tomcat JDBC datasource to connect Confluence to our MySQL server. With Confluence 6.0 rc 2 Synchrony uses this datasource (Previous bug) but generated the wrong user name to connect to the MySQL server.
atlassian-synchrony.log displays:
java.sql.SQLException: Access denied for user 'root@sbdevcon1.schb.local'@'sbdevcon1.schb.local' (using password: YES)
The datasource used by Confluence & configured in server.xml is:
<Resource name="jdbc/confluence" auth="Container" type="javax.sql.DataSource" username="root" password="XXXXXXXXXXXXXXXXXX" driverClassName="com.mysql.jdbc.Driver" url="jdbc:mysql://mydbserver.mydomain/confluence?sessionVariables=storage_engine%3DInnoDB&useUnicode=true&characterEncoding=utf8" defaultTransactionIsolation="READ_COMMITTED" validationQuery="SELECT 1" initialSize="10" maxTotal="30" maxIdle="10" minIdle="0" maxWaitMillis="-1" timeBetweenEvictionRunsMillis="30000" minEvictableIdleTimeMillis="60000" testOnBorrow="true" removeAbandonedOnBorrow="false" removeAbandonedOnMaintenance="false" removeAbandonedTimeout="120" logAbandoned="true" />
As you can see, the user name "root" is appended with the Confluence server name. This user is not configured AND cannot be created in MySQL because the username exceeds 16 chars. No workaround is known by now.
Best regards,
Jan-Peter Rusch