Details
-
Bug
-
Resolution: Fixed
-
Low
-
2.1.0
-
None
Description
Stash 2.1 replaced the jTDS JDBC driver with Microsoft's own, for accessing SQL Server. Microsoft's JDBC URL allows for the following layout:
jdbc:sqlserver://hostname\instanceName:port;databaseName=database;
When using Stash's in-app screens for configuring a database, "hostname\instanceName" can be put into the hostname text box. Migration will complete successfully, and the system will connect to the desired instance.
However, when the JDBC URL is written into stash-config.properties, the \ between the hostname and instance name is not escaped (since the system does not actually support this usage). As a result, the first time the server is restarted the value becomes "hostnameinstanceName", because the \ is stripped as an invalid escape, and the database connection fails.