Skip to content

Commit 9569455

Browse files
committed
Skip shard routing tests on OpenSearch < 2.2.0 with security
OpenSearch < 2.2.0 with the security plugin throws java.io.OptionalDataException on shard-routed requests due to non-thread-safe HashSet/HashMap in User serialization. Fixed in 2.2.0 by opensearch-project/security#1970 (50a94b47). Widen the existing 2.1.0-only skip to cover all versions below 2.2.0. Signed-off-by: Sean Chittenden <sean.chittenden@crowdstrike.com>
1 parent 83bc582 commit 9569455

2 files changed

Lines changed: 6 additions & 5 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
145145

146146
### Fixed
147147

148-
- Fix connection lifecycle bug in multiServerPool.OnFailure where connections were scheduled for resurrection before being moved from ready to dead list, causing potential race conditions
148+
- Skip shard routing integration tests on OpenSearch < 2.2.0 with security plugin due to server-side `OptionalDataException` from non-thread-safe User serialization (opensearch-project/security#1970)
149149
- Fix flaky connection integration test by replacing arbitrary sleep times with proper server readiness polling
150150
- Fix cluster readiness checks in integration tests to handle HTTPS cold start delays (increase timeout to 15s)
151151
- Fix GitHub Actions workflow authentication for OpenSearch 2.12.0+ password changes (admin -> myStrongPassword123!)

opensearchtransport/shard_routing_integration_test.go

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -232,11 +232,12 @@ func TestShardExactRouting_FullPipeline_Integration(t *testing.T) {
232232
testutil.WaitForCluster(t)
233233
testutil.SkipIfSingleNode(t, 2) // 1 replica requires at least 2 nodes for green health
234234

235-
// OpenSearch 2.1.0 with the security plugin returns HTTP 500 on search
236-
// requests routed to specific shard-hosting nodes. The insecure 2.1.0
237-
// compat job passes; this is a server-side security plugin bug.
235+
// OpenSearch < 2.2.0 with the security plugin returns HTTP 500 on
236+
// shard-routed requests due to non-thread-safe User serialization
237+
// (java.io.OptionalDataException). Fixed in 2.2.0 by
238+
// opensearch-project/security#1970 (50a94b47).
238239
if testutil.IsSecure(t) {
239-
testutil.SkipIfVersion(t, "=", "2.1.0", "shard-exact pipeline (security plugin HTTP 500)")
240+
testutil.SkipIfVersion(t, "<", "2.2.0", "shard-exact pipeline (security plugin OptionalDataException)")
240241
}
241242

242243
u := testutil.GetTestURL(t)

0 commit comments

Comments
 (0)