Migrate from the jTDS driver to the supported Microsoft SQL Server driver in Confluence 6.4 or later
プラットフォームについて: Server および Data Center のみ。この記事は、Server および Data Center プラットフォームのアトラシアン製品にのみ適用されます。
Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Fisheye および Crucible は除く
目的
The open source jTDS driver for Microsoft SQL Server will not be supported for use with Confluence beyond Confluence 6.5. This means you will need to switch to using the official Microsoft JDBC Driver for SQL Server, which is bundled with Confluence 6.4 and later.
When you start Confluence 6.6, Confluence will attempt to switch to the Microsoft JDBC Driver for SQL Server. If this process can't be completed, or if you want to switch to the new driver before upgrading to 6.6, you'll need to follow the steps in this guide to manually migrate to the supported driver.
ソリューション
基本
The new driver class name is com.microsoft.sqlserver.jdbc.SQLServerDriver
The basic connection URL format is:jdbc:sqlserver://<server>:<port>;databaseName=<databasename>
.
See https://docs.microsoft.com/en-us/sql/connect/jdbc/building-the-connection-url in the Microsoft documentation for help constructing your connection URL.
If you use a JDBC connection
- Confluence を停止します。
- Back up your home directory.
<home-directory>/confluence.cfg.xml
を編集します。Update the driver class name as follows:
<property name="hibernate.connection.driver_class">com.microsoft.sqlserver.jdbc.SQLServerDriver</property>
Update your connection URL to use the SQL format. Here's an example:
<property name="hibernate.connection.url">jdbc:sqlserver://yourserver:1433;databaseName=confluence</property>
- ファイルを保存して Confluence を再起動します。
データソース接続を使用する場合
- Confluence を停止します。
- Back up your installation and home directories.
<install-directory>/conf/server.xml
を編集します。Update the driver class name as follows:
driverClassName="com.microsoft.sqlserver.jdbc.SQLServerDriver"
Update your connection URL to use the SQL format. Here's an example:
url="jdbc:sqlserver://yourserver:1433;databaseName=confluence"
- ファイルを保存して Confluence を再起動します。
Additional steps for Confluence Data Center
If you're running Confluence Data Center, with a Synchrony standalone cluster (e.g. Synchrony is not managed by Confluence) you will also need to tell Synchrony to use the new driver.
For Confluence 6.5 or later, if you're using the start and stop scripts, follow these steps:
- Confluence を停止します。
- Stop Synchrony
- Back up your Synchrony home directory
- Edit
start-synchrony.bat
orstart-synchrony.sh
Update your database URL to use the SQL format. Here's an example:
set DATABASE_URL="jdbc:sqlserver://yourserver:1433;databaseName=confluence"
Update the path to the Microsoft JDBC driver (if you run Synchrony on a seperate server, you may need to copy the driver over from
<install-directory>/confluence/WEB-INF/lib
)set DATABASE_DRIVER_PATH=\path\to\mssql-jdbc-x.x.x.jar
- Save your script and restart Synchrony.
- Start Confluence and check that Confluence can connect to Synchrony and that you can edit pages.
For Confluence 6.4 the steps are much the same, except you will be updating your start Synchrony command to include the new format database URL and path to the Microsoft JDBC driver. See Configuring Synchrony for Data Center.