Skip to content

Commit

Permalink
[databases]: add a missing field to Opensearch advanced configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
loosla committed Oct 2, 2024
1 parent 1edf393 commit 8c77a10
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions databases.go
Original file line number Diff line number Diff line change
Expand Up @@ -724,6 +724,7 @@ type OpensearchConfig struct {
ScriptMaxCompilationsRate *string `json:"script_max_compilations_rate,omitempty"`
ClusterRoutingAllocationNodeConcurrentRecoveries *int `json:"cluster_routing_allocation_node_concurrent_recoveries,omitempty"`
ReindexRemoteWhitelist []string `json:"reindex_remote_whitelist,omitempty"`
PluginsAlertingFilterByBackendRolesEnabled *bool `json:"plugins_alerting_filter_by_backend_roles_enabled,omitempty"`
}

type databaseUserRoot struct {
Expand Down
4 changes: 3 additions & 1 deletion databases_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3209,7 +3209,8 @@ func TestDatabases_GetConfigOpensearch(t *testing.T) {
"override_main_response_version": false,
"script_max_compilations_rate": "use-context",
"cluster_max_shards_per_node": 0,
"cluster_routing_allocation_node_concurrent_recoveries": 2
"cluster_routing_allocation_node_concurrent_recoveries": 2,
"plugins_alerting_filter_by_backend_roles_enabled": true
}
}`

Expand Down Expand Up @@ -3251,6 +3252,7 @@ func TestDatabases_GetConfigOpensearch(t *testing.T) {
ScriptMaxCompilationsRate: PtrTo("use-context"),
ClusterRoutingAllocationNodeConcurrentRecoveries: PtrTo(2),
ReindexRemoteWhitelist: nil,
PluginsAlertingFilterByBackendRolesEnabled: PtrTo(true),
}
)

Expand Down

0 comments on commit 8c77a10

Please sign in to comment.