Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,9 @@ jobs:
uses: actions/checkout@v4

- name: Setup Java ${{ matrix.java }}
uses: actions/setup-java@v1
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: ${{ matrix.java }}

- name: Build and Test
Expand Down
15 changes: 14 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import org.opensearch.gradle.testclusters.OpenSearchCluster

buildscript {
ext {
opensearch_version = System.getProperty("opensearch.version", "3.6.0-SNAPSHOT")
opensearch_version = System.getProperty("opensearch.version", "3.7.0-SNAPSHOT")
isSnapshot = "true" == System.getProperty("build.snapshot", "true")
buildVersionQualifier = System.getProperty("build.version_qualifier", "")
version_tokens = opensearch_version.tokenize('-')
Expand Down Expand Up @@ -220,6 +220,19 @@ dependencies {
// TODO remove once SA commons is published to maven central
api files(sa_commons_file_path)

// Excluded from commons shadow jar to avoid jar hell with alerting plugin.
// Declared compileOnly: alerting provides them at runtime via extendedPlugins classloader sharing.
compileOnly 'com.fasterxml.jackson.core:jackson-databind:2.17.1'
Copy link
Copy Markdown
Member

@cwperks cwperks May 20, 2026

Choose a reason for hiding this comment

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

Can we possibly take these versions from core's version catalog?

Copy link
Copy Markdown
Collaborator Author

@AWSHurneyt AWSHurneyt May 20, 2026

Choose a reason for hiding this comment

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

compileOnly 'com.fasterxml.jackson.core:jackson-annotations:2.17.1'
compileOnly 'software.amazon.awssdk:sts:2.25.42'
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Same comment as above for the versions here, there's a versions.aws tag that we use in other packages like Alerting

compileOnly 'software.amazon.awssdk:sdk-core:2.25.42'
compileOnly 'software.amazon.awssdk:aws-core:2.25.42'
compileOnly 'software.amazon.awssdk:utils:2.25.42'
compileOnly 'software.amazon.awssdk:regions:2.25.42'
compileOnly 'software.amazon.awssdk:http-client-spi:2.25.42'
compileOnly 'software.amazon.awssdk:profiles:2.25.42'
compileOnly 'software.amazon.awssdk:annotations:2.25.42'

// Needed for integ tests
zipArchive group: 'org.opensearch.plugin', name:'alerting', version: "${opensearch_build}"
zipArchive group: 'org.opensearch.plugin', name:'opensearch-notifications-core', version: "${opensearch_build}"
Expand Down
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionSha256Sum=16f2b95838c1ddcf7242b1c39e7bbbb43c842f1f1a1a0dc4959b6d4d68abcac3
distributionUrl=https\://services.gradle.org/distributions/gradle-9.2.0-all.zip
distributionSha256Sum=708d2c6ecc97ca9a11838ef64a6c2301151b8dd10387e22dc1a12c30557cab5b
distributionUrl=https\://services.gradle.org/distributions/gradle-9.4.1-all.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
Binary file modified security-analytics-commons-1.0.0.jar
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,9 @@ private Monitor buildThreatIntelMonitor(IndexThreatIntelMonitorRequest request)
new DataSources(),
false,
null,
PLUGIN_OWNER_FIELD
PLUGIN_OWNER_FIELD,
null,
null
);
} catch (Exception e) {
String error = "Error occurred while parsing monitor.";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -797,7 +797,7 @@ private IndexMonitorRequest createDocLevelMonitorRequest(List<Pair<String, Rule>
detector.getAlertsHistoryIndex(),
detector.getAlertsHistoryIndexPattern(),
DetectorMonitorConfig.getRuleIndexMappingsByType(),
true), enableDetectorWithDedicatedQueryIndices, null, PLUGIN_OWNER_FIELD);
true), enableDetectorWithDedicatedQueryIndices, null, PLUGIN_OWNER_FIELD, null, null);

return new IndexMonitorRequest(monitorId, SequenceNumbers.UNASSIGNED_SEQ_NO, SequenceNumbers.UNASSIGNED_PRIMARY_TERM, refreshPolicy, restMethod, monitor, null);
}
Expand Down Expand Up @@ -903,7 +903,7 @@ private IndexMonitorRequest createDocLevelMonitorMatchAllRequest(
detector.getAlertsHistoryIndex(),
detector.getAlertsHistoryIndexPattern(),
DetectorMonitorConfig.getRuleIndexMappingsByType(),
true), enableDetectorWithDedicatedQueryIndices, true, PLUGIN_OWNER_FIELD);
true), enableDetectorWithDedicatedQueryIndices, true, PLUGIN_OWNER_FIELD, null, null);

return new IndexMonitorRequest(monitorId, SequenceNumbers.UNASSIGNED_SEQ_NO, SequenceNumbers.UNASSIGNED_PRIMARY_TERM, refreshPolicy, restMethod, monitor, null);
}
Expand Down Expand Up @@ -1079,7 +1079,7 @@ public void onResponse(GetIndexMappingsResponse getIndexMappingsResponse) {
detector.getAlertsHistoryIndex(),
detector.getAlertsHistoryIndexPattern(),
DetectorMonitorConfig.getRuleIndexMappingsByType(),
true), false, null, PLUGIN_OWNER_FIELD);
true), false, null, PLUGIN_OWNER_FIELD, null, null);

listener.onResponse(new IndexMonitorRequest(monitorId, SequenceNumbers.UNASSIGNED_SEQ_NO, SequenceNumbers.UNASSIGNED_PRIMARY_TERM, refreshPolicy, restMethod, monitor, null));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,9 @@ public void testGetAlerts_success() {
new DataSources(),
true,
null,
TransportIndexDetectorAction.PLUGIN_OWNER_FIELD
TransportIndexDetectorAction.PLUGIN_OWNER_FIELD,
null,
null
),
new DocumentLevelTrigger("trigger_id_1", "my_trigger", "severity_low", List.of(), new Script("")),
List.of("finding_id_1"),
Expand Down Expand Up @@ -133,7 +135,9 @@ public void testGetAlerts_success() {
new DataSources(),
true,
null,
TransportIndexDetectorAction.PLUGIN_OWNER_FIELD
TransportIndexDetectorAction.PLUGIN_OWNER_FIELD,
null,
null
),
new DocumentLevelTrigger("trigger_id_1", "my_trigger", "severity_low", List.of(), new Script("")),
List.of("finding_id_1"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,9 @@ public void testThreatInputSerde() throws IOException {
new DataSources(),
false,
null,
"security_analytics"
"security_analytics",
null,
null
);
BytesStreamOutput monitorOut = new BytesStreamOutput();
monitor.writeTo(monitorOut);
Expand Down
Loading