diff --git a/extensions/s3/src/main/java/io/deephaven/extensions/s3/S3Instructions.java b/extensions/s3/src/main/java/io/deephaven/extensions/s3/S3Instructions.java index aca19c2ca71..14dacb4c71a 100644 --- a/extensions/s3/src/main/java/io/deephaven/extensions/s3/S3Instructions.java +++ b/extensions/s3/src/main/java/io/deephaven/extensions/s3/S3Instructions.java @@ -110,10 +110,11 @@ public Duration readTimeout() { /** * The amount of time to wait when writing a fragment before giving up and timing out. This is accomplished through - * calling the {@link software.amazon.awssdk.core.RequestOverrideConfiguration.Builder#apiCallTimeout(java.time.Duration)} + * calling the + * {@link software.amazon.awssdk.core.RequestOverrideConfiguration.Builder#apiCallTimeout(java.time.Duration)} * method to time out api calls. */ - public abstract Optional writeTimeout(); + public abstract Optional writeTimeout(); /** * The credentials to use when reading or writing to S3. By default, uses {@link Credentials#resolving()}. diff --git a/extensions/s3/src/test/java/io/deephaven/extensions/s3/S3SeekableChannelSimpleTestBase.java b/extensions/s3/src/test/java/io/deephaven/extensions/s3/S3SeekableChannelSimpleTestBase.java index b1ce5979651..3a4d1b2bf2e 100644 --- a/extensions/s3/src/test/java/io/deephaven/extensions/s3/S3SeekableChannelSimpleTestBase.java +++ b/extensions/s3/src/test/java/io/deephaven/extensions/s3/S3SeekableChannelSimpleTestBase.java @@ -174,7 +174,8 @@ void readWriteTestExpectWriteTimeout() throws IOException { final Throwable cause = e.getCause(); assertThat(cause.getClass().equals(ExecutionException.class)).isEqualTo(true); final String s = cause.getMessage(); - assertThat(s.contains("Client execution did not complete before the specified timeout configuration")).isEqualTo(true); + assertThat(s.contains("Client execution did not complete before the specified timeout configuration")) + .isEqualTo(true); } } } diff --git a/extensions/s3/src/test/java/io/deephaven/extensions/s3/testlib/S3SeekableChannelTestSetup.java b/extensions/s3/src/test/java/io/deephaven/extensions/s3/testlib/S3SeekableChannelTestSetup.java index 9453ee02f5b..1e9eb043fed 100644 --- a/extensions/s3/src/test/java/io/deephaven/extensions/s3/testlib/S3SeekableChannelTestSetup.java +++ b/extensions/s3/src/test/java/io/deephaven/extensions/s3/testlib/S3SeekableChannelTestSetup.java @@ -6,6 +6,7 @@ import io.deephaven.extensions.s3.S3Instructions; import io.deephaven.extensions.s3.S3SeekableChannelProviderPlugin; import io.deephaven.util.channel.SeekableChannelsProvider; +import org.jetbrains.annotations.Nullable; import software.amazon.awssdk.core.async.AsyncRequestBody; import software.amazon.awssdk.services.s3.S3AsyncClient; import software.amazon.awssdk.services.s3.model.CreateBucketRequest; @@ -71,14 +72,15 @@ protected final void putObject(String key, AsyncRequestBody body) } protected final SeekableChannelsProvider providerImpl() { - final S3SeekableChannelProviderPlugin plugin = new S3SeekableChannelProviderPlugin(); - final S3Instructions instructions = s3Instructions(S3Instructions.builder()).build(); - return plugin.createProvider(SCHEME, instructions); + return providerImpl(null); } - protected final SeekableChannelsProvider providerImpl(final S3Instructions.Builder s3InstructionsBuilder) { + protected final SeekableChannelsProvider providerImpl( + @Nullable final S3Instructions.Builder s3InstructionsBuilder) { final S3SeekableChannelProviderPlugin plugin = new S3SeekableChannelProviderPlugin(); - final S3Instructions instructions = s3Instructions(s3InstructionsBuilder).build(); + final S3Instructions instructions = + s3Instructions(s3InstructionsBuilder == null ? S3Instructions.builder() : s3InstructionsBuilder) + .build(); return plugin.createProvider(SCHEME, instructions); } diff --git a/py/server/deephaven/experimental/s3.py b/py/server/deephaven/experimental/s3.py index 311c2df6a95..9492ae4847d 100644 --- a/py/server/deephaven/experimental/s3.py +++ b/py/server/deephaven/experimental/s3.py @@ -165,7 +165,8 @@ def __init__(self, "PT1s", or other time duration types. Default to 2 seconds. write_timeout (DurationLike): the amount of time to wait when writing a fragment before giving up and timing out. Can be expressed as an integer in nanoseconds, a time interval string, e.g. "PT00:00:00.001" or - "PT1s", or other time duration types. Default to 2 seconds. + "PT1s", or other time duration types. This value is a Java Optional and must be tested as such. + If not set then the Optional is empty. access_key_id (str): (Deprecated) the access key for reading files. Both access key and secret access key must be provided to use static credentials. If you specify both access key and secret key, then you cannot provide other credentials like setting anonymous_access or credentials argument.