Task: Trying to upgrade from minio.netcore 1.1.1 client to minio client 3.1.13
Problem: When i try to create a bucket with the new client I get the following excpetion thrown:
MinIO API responded with message=The XML you provided was not well-formed or
did not validate against our published schema
I've tested in isolation from the rest of my code and can't see what the issue is:
using System;
using System.Threading.Tasks;
namespace ConsoleApp3
{
class Program
{
static async Task Main(string[] args)
{
Console.WriteLine("Hello World!");
var client = new Minio.MinioClient("{serverIpAddress}:9000", "myaccesskey", "mysecretkey");
var bucketid = Guid.NewGuid().ToString();
await client.MakeBucketAsync(bucketid,"uk-st-1");
var result = await client.BucketExistsAsync(bucketid);
}
}
}
and my csproj is switching between these 2 nugets:
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Minio" Version="3.1.13" />
<!--<PackageReference Include="Minio.NetCore" Version="1.1.1" />-->
</ItemGroup>
</Project>
I've tried catching the traffic and the XML it produces for both nugets is this:
<?xml version="1.0" encoding="utf-8"?>
<q1:CreateBucketConfiguration xmlns:q1="http://s3.amazonaws.com/doc/2006-03-01/">
<q1:LocationConstraint>uk-st-1</q1:LocationConstraint>
</q1:CreateBucketConfiguration>