-
Notifications
You must be signed in to change notification settings - Fork 219
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fails for SQL Server (new JDBC driver from Atlassian) #72
Comments
PR submitted for review; adjusts the driver class and JDBC URL scheme |
Thank you! Looks good! |
New JDBC URL and driver class per Atlassian, #72
Still troubleshooting this some. The duplicate handling of the host/port/database (having them be in the required |
Another crux of the issue is that the (new) JDBC driver URLs don't append the database name but rather use the |
To concretely document what's (not) working currently, when I launch the JIRA container using this: docker run \
-d \
--name jira \
--network *** \
-v jiravolume:/var/atlassian/jira \
-e "JIRA_PROXY_NAME=***" \
-e "JIRA_PROXY_PORT=443" \
-e "JIRA_PROXY_SCHEME=https" \
-e "JIRA_CONTEXT_PATH=jira" \
-e "JIRA_DATABASE_URL=sqlserver://MYSERVER:1433;databaseName=JIRA_Dev" \
-e "JIRA_DB_USER=jira-app" \
-e "JIRA_DB_PASSWORD=***" \
-e "DOCKER_WAIT_HOST=MYSERVER" \
-e "DOCKER_WAIT_PORT=1433" \
-e "JVM_MINIMUM_MEMORY=512m" \
-e "JVM_MAXIMUM_MEMORY=1g" \
-v /etc/timezone:/etc/timezone:ro \
-p 8080:8080 \
jira-esk When the container starts, I find this in the Atlassian log (
Which makes sense given that the container scripting generated a malformed URL for my <?xml version="1.0" encoding="UTF-8"?>
<jira-database-config>
<name>defaultDS</name>
<delegator-name>default</delegator-name>
<database-type>mssql</database-type>
<schema-name>dbo</schema-name>
<jdbc-datasource>
<url>jdbc:sqlserver://MYSERVER:1433;databaseName=JIRA_Dev/</url>
<driver-class>com.microsoft.sqlserver.jdbc.SQLServerDriver</driver-class>
<username>jira-app</username>
<password>***</password>
<pool-min-size>20</pool-min-size>
<pool-max-size>20</pool-max-size>
<pool-max-wait>30000</pool-max-wait>
<pool-max-idle>20</pool-max-idle>
<pool-remove-abandoned>true</pool-remove-abandoned>
<pool-remove-abandoned-timeout>300</pool-remove-abandoned-timeout>
<validation-query>select version();</validation-query>
<validation-query-timeout>3</validation-query-timeout>
<min-evictable-idle-time-millis>60000</min-evictable-idle-time-millis>
<time-between-eviction-runs-millis>300000</time-between-eviction-runs-millis>
<pool-test-on-borrow>false</pool-test-on-borrow>
<pool-test-while-idle>true</pool-test-while-idle>
</jdbc-datasource>
</jira-database-config> |
Again, being non-standard, Microsoft didn't even follow the URL convention that the query portion of the URL starts with a |
This failing on Microsoft's part is devastating to the assumed simplicity of the scripting for this container. I'm inclined to leave most of the code "as is" (which basically makes all of the connection properties part of the |
Ok, when I use the given
Which makes sense because the validation query shown is for PostgreSQL! This Atlassian document describes the validation queries to be used by database: https://confluence.atlassian.com/adminjiraserver071/surviving-connection-closures-802592191.html Looks like we should dynamically rewrite this, too (another GitHub issue, perhaps) but for now I believe |
Hello, I accepted the last pull request in best hope that you committed tested code. My build pipeline immediately pushes to Dockerhub, every pull-request will be published and pulled by other users. Does this resolve this issue? Otherwise I can offer a development branch where we can resolve this issue. |
Revert "New JDBC URL and driver class per Atlassian, #72"
SQL driver reverted to old one. Any changes please on the new dev branch. |
Yes, @blacklabelops I believe the PR that I submitted resolved this issue. Did you revert it out? |
I don't see any build error in the CI failure, just that the build step was canceled during download of JIRA Core:
|
I changed the default branch from master to dev. You can now safely recommit the last two pull requests. |
Sounds good. Thanks for the clarification! |
Atlassian introduced use of a new JDBC driver (the one created by Microsoft) and version 7.8.0 no longer includes the prior jTDS JDBC driver. The current docker definition needs to be revised to adjust for this.
New JDBC Driver Classname:
com.microsoft.sqlserver.jdbc.SQLServerDriver
New URL Scheme:
jdbc:sqlserver://[serverName[\instanceName][:portNumber]][;property=value[;property=value]]
See also:
The text was updated successfully, but these errors were encountered: