If one doesn't call WithSSL(...), then a NullReferenceException is triggered inside the MinIO library.
Steps To Reproduce
Given this code:
var services = new ServiceCollection();
services.AddMinio(client =>
{
client
.WithCredentials("minioadmin", "minioadmin")
.WithEndpoint("127.0.0.1", 9000)
//.WithSSL(false)
;
});
var serviceProvider = services.BuildServiceProvider();
var client = serviceProvider.GetRequiredService<IMinioClient>();
using var stream = File.OpenRead("test-data.json");
var putArgs = new PutObjectArgs()
.WithBucket("spot-layouter-push")
.WithObject("TestPut.json")
.WithStreamData(stream)
.WithObjectSize(stream.Length)
.WithContentType("application/json");
await client.PutObjectAsync(putArgs);
Have a test file greater than about 6MB
Execute the code
Error: NullReferenceException
Stacktrace
at Minio.DataModel.Response.NewMultipartUploadResponse..ctor(HttpStatusCode statusCode, String responseContent)
at Minio.MinioClient.NewMultipartUploadAsync(NewMultipartUploadPutArgs args, CancellationToken cancellationToken)
at Minio.MinioClient.PutObjectAsync(PutObjectArgs args, CancellationToken cancellationToken)
Expectations
Omission of calling WithSSL(...) should not cause an exception
If one doesn't call
WithSSL(...)
, then aNullReferenceException
is triggered inside the MinIO library.Steps To Reproduce
Given this code:
NullReferenceException
Stacktrace
Expectations
WithSSL(...)
should not cause an exceptionInfo
MinIO (NuGet): 6.0.2 MinIO (Server): 2024-02-06T21:36:22Z