From 70fe73cd11c9d21da750e2eb148d2bd801d58d03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Mathieu?= Date: Thu, 21 Nov 2024 11:09:49 +0100 Subject: [PATCH] feat: storage now have a namespace parameter --- gradle.properties | 2 +- src/test/java/io/kestra/plugin/mongodb/BulkTest.java | 4 +--- src/test/java/io/kestra/plugin/mongodb/LoadTest.java | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/gradle.properties b/gradle.properties index d140d9f..3ccabc3 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,2 +1,2 @@ version=0.20.0-SNAPSHOT -kestraVersion=[0.18,) +kestraVersion=[0.20,) diff --git a/src/test/java/io/kestra/plugin/mongodb/BulkTest.java b/src/test/java/io/kestra/plugin/mongodb/BulkTest.java index cf6e853..93f0220 100644 --- a/src/test/java/io/kestra/plugin/mongodb/BulkTest.java +++ b/src/test/java/io/kestra/plugin/mongodb/BulkTest.java @@ -4,7 +4,6 @@ import io.kestra.core.runners.RunContextFactory; import io.kestra.core.storages.StorageInterface; import io.kestra.core.utils.IdUtils; -import io.micronaut.context.annotation.Value; import io.kestra.core.junit.annotations.KestraTest; import jakarta.inject.Inject; import org.junit.jupiter.api.Test; @@ -15,7 +14,6 @@ import java.io.OutputStream; import java.net.URI; import java.nio.charset.StandardCharsets; -import java.util.List; import java.util.Locale; import static org.hamcrest.MatcherAssert.assertThat; @@ -51,7 +49,7 @@ void run() throws Exception { output.write(("{ replaceOne : {\"filter\" : { \"char\" : \"Meldane\" },\"replacement\" : { \"char\" : \"Tanys\", \"class\" : \"oracle\", \"lvl\": 4 }, \"collation\": { \"locale\": \"en\", \"strength\": 2 } } }\n").getBytes(StandardCharsets.UTF_8)); } - URI uri = storageInterface.put(null, URI.create("/" + IdUtils.create() + ".ion"), new FileInputStream(tempFile)); + URI uri = storageInterface.put(null, null, URI.create("/" + IdUtils.create() + ".ion"), new FileInputStream(tempFile)); Bulk put = Bulk.builder() .connection(MongoDbConnection.builder() diff --git a/src/test/java/io/kestra/plugin/mongodb/LoadTest.java b/src/test/java/io/kestra/plugin/mongodb/LoadTest.java index 0489c05..9a5bed6 100644 --- a/src/test/java/io/kestra/plugin/mongodb/LoadTest.java +++ b/src/test/java/io/kestra/plugin/mongodb/LoadTest.java @@ -43,7 +43,7 @@ void run() throws Exception { "name", "john" )); } - URI uri = storageInterface.put(null, URI.create("/" + IdUtils.create() + ".ion"), new FileInputStream(tempFile)); + URI uri = storageInterface.put(null, null, URI.create("/" + IdUtils.create() + ".ion"), new FileInputStream(tempFile)); Load put = Load.builder() .connection(MongoDbConnection.builder()