Skip to content

Remove sqljdbc_xa.dll: drop legacy XA extended-procedure DLL - #3017

Open
Ananya Garg (Ananya2) wants to merge 4 commits into
mainfrom
user/anagarg/remove-xa-dll
Open

Remove sqljdbc_xa.dll: drop legacy XA extended-procedure DLL#3017
Ananya Garg (Ananya2) wants to merge 4 commits into
mainfrom
user/anagarg/remove-xa-dll

Conversation

@Ananya2

@Ananya2 Ananya Garg (Ananya2) commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Summary

Removes all references to the legacy server-side sqljdbc_xa.dll from the driver's documentation and diagnostics. XA distributed transactions now rely solely on the xp_sqljdbc_xa_* extended stored procedures that are built into SQL Server 2017 CU16 and later (enabled via EXEC sp_sqljdbc_xa_install). The DLL is no longer shipped.

Motivation

sqljdbc_xa.dll was only required for SQL Server 2016 and earlier — the sp_xa procedures have been built into the SQL Server engine since SQL Server 2017 CU16. The server-side sp_xa sprocs originally derived from the code in this JDBC DLL, so a recently reported MSRC vulnerability in the server procedures is likely to exist in the DLL as well. With SQL Server 2016 leaving the 5+5 support lifecycle this year, the DLL can be safely dropped rather than serviced.

Changes

  • README.md — "Download the DLLs" no longer lists sqljdbc_xa; documents that XA procedures are built into SQL Server 2017 CU16+ (enable via sp_sqljdbc_xa_install) and that the standalone DLL is no longer shipped.
  • DLLException.java — Class comment now references only the mssql-jdbc_auth DLL.
  • XAStateTest.java — Diagnostic hints updated to point to EXEC sp_sqljdbc_xa_install on SQL Server 2017 CU16+.

Not changed (intentionally)

  • SQLServerXAResource.java and the xp_sqljdbc_xa_* calls — the XA feature remains fully functional against SQL Server 2017 CU16+.
  • R_failedToInitializeXA resource string and its localized translations.

Testing

No runtime code changed — only docs, one comment, and test diagnostic strings. XA tests continue to run against SQL Server 2017 CU16+ using the built-in stored procedures.

Related

Companion PR in the internal build repo removes the DLL source, build, and packaging.

@codecov

codecov Bot commented Aug 14, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 60.52%. Comparing base (a45b6cb) to head (ceb5972).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #3017      +/-   ##
============================================
+ Coverage     60.18%   60.52%   +0.33%     
- Complexity     5138     5251     +113     
============================================
  Files           153      153              
  Lines         36673    36679       +6     
  Branches       6733     6733              
============================================
+ Hits          22073    22201     +128     
+ Misses        10751    10742       -9     
+ Partials       3849     3736     -113     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the driver’s documentation and diagnostic messaging to remove outdated guidance about installing sqljdbc_xa.dll, aligning XA setup guidance with SQL Server 2017+ built-in XA stored procedures enabled via sp_sqljdbc_xa_install.

Changes:

  • Updates README XA guidance to remove sqljdbc_xa DLL installation instructions and point users to EXEC sp_sqljdbc_xa_install on SQL Server 2017+.
  • Updates DLLException class comment to reference only the mssql-jdbc_auth DLL.
  • Updates XA state machine test diagnostic strings to reference enabling XA via sp_sqljdbc_xa_install.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
README.md Removes outdated sqljdbc_xa DLL instructions and adds SQL Server 2017+ XA enablement guidance.
src/main/java/com/microsoft/sqlserver/jdbc/DLLException.java Updates comment to remove sqljdbc_xa DLL mention.
src/test/java/com/microsoft/sqlserver/jdbc/statemachinetest/xa/XAStateTest.java Updates diagnostic output/hints to reference sp_sqljdbc_xa_install instead of DLL/script installation.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread README.md Outdated
@Ananya2 Ananya Garg (Ananya2) changed the title Remove sqljdbc_xa DLL and rely on SQL Server 2017+ built-in XA procedures Remove sqljdbc_xa.dll: drop legacy XA extended-procedure DLL Aug 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In progress

Development

Successfully merging this pull request may close these issues.

4 participants