Sha256: 95ef7c2199182f1e2cbc98b079a9e6c34e20b3d1328d84776e0ac2782718a5ef
Contents?: true
Size: 1.23 KB
Versions: 6
Compression:
Stored size: 1.23 KB
Contents
package org.embulk.input.riak_cs; import com.amazonaws.ClientConfiguration; import com.amazonaws.services.s3.AmazonS3; import org.embulk.config.Config; import org.embulk.input.s3.AbstractS3FileInputPlugin; import static com.amazonaws.client.builder.AwsClientBuilder.EndpointConfiguration; public class RiakCsFileInputPlugin extends AbstractS3FileInputPlugin { public interface RiakCsPluginTask extends PluginTask { @Config("endpoint") public String getEndpoint(); } @Override protected Class<? extends PluginTask> getTaskClass() { return RiakCsPluginTask.class; } @Override protected AmazonS3 newS3Client(PluginTask task) { RiakCsPluginTask t = (RiakCsPluginTask) task; return super .defaultS3ClientBuilder(task) .withEndpointConfiguration(new EndpointConfiguration(t.getEndpoint(), null)) .build(); } @Override protected ClientConfiguration getClientConfiguration(PluginTask task) { RiakCsPluginTask t = (RiakCsPluginTask) task; ClientConfiguration config = super.getClientConfiguration(t); config.setSignerOverride("S3SignerType"); return config; } }
Version data entries
6 entries across 6 versions & 1 rubygems