Skip to content

Fix Always Encrypted GUID test in multi-server pipelines - #3069

Merged
Muskan Gupta (muskan124947) merged 1 commit into
mainfrom
muskan124947-pipeline-failure
Oct 9, 2026
Merged

Muskan Gupta (muskan124947) merged 1 commit into
mainfrom
muskan124947-pipeline-failure

Conversation

@muskan124947

@muskan124947 Muskan Gupta (muskan124947) commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Description

Fix the Always Encrypted GUID bulk-copy test introduced in #3041. The test creates its table through the AE connection, but its ciphertext check opened the base connection, which can target a different server in multi-server configurations and fail with "Invalid object name".

Reuse the connection that created the table and set SQLServerStatementColumnEncryptionSetting.DISABLED only on the ciphertext verification statement. This preserves the AE endpoint and authentication without changing connection-level encryption or enclave settings. The helper closes only its statement and result set; the caller retains ownership of the connection.

Test-only change; no driver behavior or public API changes.

Issues

Related to #3041.

Testing

  • Existing failing integration coverage: BulkCopyGuidAETest.testBulkCopyGuidIntoEncryptedColumn; retains both decrypted GUID round-trip and ciphertext-length assertions.
  • BulkCopyGuidParserTest and BulkCopyGuidMetadataTest: 44 tests passed under each of the jre11 and jre8 Maven profiles on JDK 21.
  • Changed Java formatted with the repository Eclipse profile; git diff --check passed.
  • Local AE integration execution is blocked in shared setup because JavaKeyStore.txt is missing. The multi-server AE pipeline must confirm the fix; no local AE pass is claimed.

Reuse the table-creating AE connection and disable decryption only on the ciphertext verification statement.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot AI balanced review requested due to automatic review settings October 8, 2026 08:50

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.

🟢 Approval recommended

The focused test-only change correctly uses the statement-level encryption override without altering connection ownership or driver behavior.

0 open findings

What changed in this PR

Fixes the Always Encrypted GUID integration test to verify ciphertext on the same server connection that created the table.

Changes:

  • Reuses the AE connection for ciphertext verification.
  • Disables column decryption only on the verification statement.
File Description
BulkCopyGuidAETest.java Prevents cross-server table lookup failures while preserving ciphertext validation.

🧠 Review effort: Balanced


Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.

@muskan124947

Copy link
Copy Markdown
Contributor Author

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 3 pipeline(s).

@codecov

codecov Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 61.77%. Comparing base (5d5e4df) to head (d9e8e64).

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #3069      +/-   ##
============================================
+ Coverage     61.51%   61.77%   +0.26%     
- Complexity     5309     5393      +84     
============================================
  Files           154      154              
  Lines         36869    36869              
  Branches       6789     6789              
============================================
+ Hits          22680    22777      +97     
+ Misses        10308    10300       -8     
+ Partials       3881     3792      -89     

☔ 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.

@muskan124947
Muskan Gupta (muskan124947) merged commit 53a532a into main Oct 9, 2026
24 checks passed
@muskan124947
Muskan Gupta (muskan124947) deleted the muskan124947-pipeline-failure branch October 9, 2026 06:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Closed/Merged PRs

Development

Successfully merging this pull request may close these issues.

5 participants