diff --git a/build.gradle b/build.gradle index 4813202d..91eb4458 100644 --- a/build.gradle +++ b/build.gradle @@ -89,6 +89,27 @@ allprojects { group 'org.opensearch.sdk' version '2.0.0-SNAPSHOT' +publishing { + publications { + mavenJava(MavenPublication) { + from components.java + } + } + + repositories { + maven { + name = "Snapshots" // optional target repository name + url = "https://aws.oss.sonatype.org/content/repositories/snapshots" + credentials { + username "$System.env.SONATYPE_USERNAME" + password "$System.env.SONATYPE_PASSWORD" + } + } + } +} + +validateMavenJavaPom.enabled = false + repositories { mavenLocal() mavenCentral() @@ -155,6 +176,9 @@ dependencies { resolutionStrategy.force("jakarta.json:jakarta.json-api:${jakartaVersion}") resolutionStrategy.force("com.fasterxml.jackson.core:jackson-databind:${jacksonDatabindVersion}") resolutionStrategy.force("com.fasterxml.jackson.core:jackson-core:${jacksonDatabindVersion}") + resolutionStrategy.force("com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:${jacksonDatabindVersion}") + resolutionStrategy.force("com.fasterxml.jackson.dataformat:jackson-dataformat-smile:${jacksonDatabindVersion}") + resolutionStrategy.force("com.fasterxml.jackson.dataformat:jackson-dataformat-cbor:${jacksonDatabindVersion}") resolutionStrategy.force("org.apache.logging.log4j:log4j-api:${log4jVersion}") resolutionStrategy.force("org.apache.logging.log4j:log4j-core:${log4jVersion}") resolutionStrategy.force("org.apache.logging.log4j:log4j-jul:${log4jVersion}")