0

I can extract the files to minio root folder but not elsewhere

Hello all. I'm using MinIO Java Client API: minio 8.4.5

I use: Map<String, String> headers = new HashMap<>(); headers.put("X-Amz-Meta-Snowball-Auto-Extract", "true");

in the PutObjectArgs and Minio extracts the contents to the root folder (of the Bucket).

public ObjectWriteResponse createObject(MinioClient minioClient, String bucket, String objectPath, InputStream inputStream,
                                        Map<String, String> headers) throws
        ServerException, InsufficientDataException, ErrorResponseException,
        IOException, NoSuchAlgorithmException, InvalidKeyException, InvalidResponseException,
        XmlParserException, InternalException {
    try {
        PutObjectArgs.Builder builder = PutObjectArgs.builder().bucket(bucket).object(safeUrl(objectPath)).
                stream(inputStream, inputStream.available(), -1);
        if (!CollectionUtils.isEmpty(headers)) {
            builder = builder.headers(headers);
        }
        return minioClient.putObject(builder.build());
    } finally {
        inputStream.close();
    }
}

How to define an extract destination folder for my tar?

Is it possible to extract a tar already present in the Minio server, without a new upload?

Best Regards

0 Answers0