Skip to content

Commit 7222ddf

Browse files
authored
Using java-agent gradle plugin to phase off Security Manager in favor of Java-agent. (#303)
* Revert "Support phasing off SecurityManager usage in favor of Java Agent (#296)" This reverts commit 06375ba. Signed-off-by: Pranav Reddy <[email protected]> * Using java-agent gradle plugin to phase off Security Manager in favor of Java-agent. Signed-off-by: Pranav Reddy <[email protected]> --------- Signed-off-by: Pranav Reddy <[email protected]>
1 parent 5a69b30 commit 7222ddf

File tree

1 file changed

+1
-17
lines changed

1 file changed

+1
-17
lines changed

build.gradle

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ apply plugin: 'opensearch.opensearchplugin'
4848
apply plugin: 'opensearch.pluginzip'
4949
apply plugin: 'opensearch.rest-test'
5050
apply plugin: 'opensearch.repositories'
51+
apply plugin: 'opensearch.java-agent'
5152

5253
def pluginName = 'query-insights'
5354
def pluginDescription = 'OpenSearch Query Insights plugin'
@@ -57,13 +58,6 @@ def pluginClassName = 'QueryInsightsPlugin'
5758

5859
configurations {
5960
zipArchive
60-
agent
61-
}
62-
63-
dependencies {
64-
agent "org.opensearch:opensearch-agent-bootstrap:${opensearch_version}"
65-
agent "org.opensearch:opensearch-agent:${opensearch_version}"
66-
agent "net.bytebuddy:byte-buddy:${versions.bytebuddy}"
6761
}
6862

6963
java {
@@ -371,13 +365,3 @@ task updateVersion {
371365
}
372366
}
373367

374-
task prepareAgent(type: Copy) {
375-
from(configurations.agent)
376-
into "$buildDir/agent"
377-
}
378-
379-
tasks.withType(Test) {
380-
dependsOn prepareAgent
381-
jvmArgs += ["-javaagent:" + project.layout.buildDirectory.file("agent/opensearch-agent-${opensearch_version}.jar").get()]
382-
}
383-

0 commit comments

Comments
 (0)