Package com.amazonaws.services.s3

Examples of com.amazonaws.services.s3.AmazonS3Client


        if (LOGGER.isDebugEnabled()) {
            LOGGER.debug(format("Creating S3 client with configuration: [protocol: %1$s, connectionTimeOut: " + "%2$s, maxErrorRetry: %3$s, socketTimeout: %4$s]",
                configuration.getProtocol(), configuration.getConnectionTimeout(), configuration.getMaxErrorRetry(), configuration.getSocketTimeout()));
        }

        final AmazonS3Client client = new AmazonS3Client(credentials, configuration);

        if (isNotBlank(clientOptions.getEndPoint())) {
            if (LOGGER.isDebugEnabled()) {
                LOGGER.debug(format("Setting the end point for S3 client %1$s to %2$s.", client, clientOptions.getEndPoint()));
            }
            client.setEndpoint(clientOptions.getEndPoint());
        }

        return client;

    }
View Full Code Here


     * @param credentials
     *            The AWS security credentials to use when making authenticated
     *            requests.
     */
    public TransferManager(AWSCredentials credentials) {
        this(new AmazonS3Client(credentials));
    }
View Full Code Here

     * @param credentials
     *            The AWS security credentials to use when making authenticated
     *            requests.
     */
    public TransferManager(AWSCredentials credentials) {
        this(new AmazonS3Client(credentials));
    }
View Full Code Here

     * @param credentialsProvider
     *            The AWS security credentials provider to use when making
     *            authenticated requests.
     */
    public TransferManager(AWSCredentialsProvider credentialsProvider) {
        this(new AmazonS3Client(credentialsProvider));
    }
View Full Code Here

     * @param credentials
     *            The AWS security credentials to use when making authenticated
     *            requests.
     */
    public TransferManager(AWSCredentials credentials) {
        this(new AmazonS3Client(credentials));
    }
View Full Code Here

     * @param credentials
     *            The AWS security credentials to use when making authenticated
     *            requests.
     */
    public TransferManager(AWSCredentials credentials) {
        this(new AmazonS3Client(credentials));
    }
View Full Code Here

    if (!artifactFile.exists())
      throw new MojoFailureException("Artifact File does not exists! (file="
          + path);

    AmazonS3Client client = new AmazonS3Client(getAWSCredentials(), getClientConfiguration());

    getLog().info("Target Path: s3://" + s3Bucket + "/" + s3Key);
    getLog().info("Uploading artifact file: " + path);

    PutObjectResult result = client.putObject(s3Bucket, s3Key, artifactFile);
   
    getLog().info("Artifact Uploaded");

    return result;
  }
View Full Code Here

  // Constructors
 
  public AwsInfiniteFile(String url, NtlmPasswordAuthentication auth) throws IOException {
    BasicAWSCredentials awsAuth = new BasicAWSCredentials(auth.getUsername(), auth.getPassword());
    AmazonS3Client client = new AmazonS3Client(awsAuth);
    _awsClient = (Object)client;
   
    getBucketAndObjectName(url, false);
  }//TESTED
View Full Code Here

    @PostConstruct
    public void initializeAmazonClient() {
        final BasicAWSCredentials credentials = new BasicAWSCredentials(username, password);
        final ClientConfiguration modifiedConf = new ClientConfiguration();
        modifiedConf.setMaxConnections(MAX_HTTP_CONNECTIONS);
        client = new AmazonS3Client(credentials, modifiedConf);
    }
View Full Code Here

    if (configBean == null) {
      throw new IllegalStateException("config is missing");
    }

    if (client == null) {
      client = new AmazonS3Client(credentials());
      client.setEndpoint(configBean.endpoint());
    } else {
      // throw new IllegalStateException("client is present");
    }
View Full Code Here

TOP

Related Classes of com.amazonaws.services.s3.AmazonS3Client

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.