Package com.amazonaws.services.glacier.transfer

Examples of com.amazonaws.services.glacier.transfer.ArchiveTransferManager


  public static GlacierClient create(AWSCredentialsImpl credentials) {
    AmazonGlacierClient amazonGlacierClient = new AmazonGlacierClient(
        credentials);
    amazonGlacierClient.setEndpoint(credentials.getGlacierEndpoint());
    return new GlacierClient(new ArchiveTransferManager(amazonGlacierClient,
        credentials), credentials.getGlacierVault());
  }
View Full Code Here


                dlSNS.setEndpoint(notificationEP.snsEndpoint());

                // ArchiveTransferManager atm = new
                // ArchiveTransferManager(dlClient,
                // dlCredentials);
                ArchiveTransferManager atm = new ArchiveTransferManager(
                    dlClient, dlSQS, dlSNS);

                atm.download("-", vaultName, archiveId, outFile);

                JOptionPane.showMessageDialog(
                    null,
                    "Sucessfully downloaded "
                        + outFile.toString(),
View Full Code Here

                // thisFile.valueOf(emptyChar).replaceAll("\\p{C}",
                // "?");

                try {

                  ArchiveTransferManager atm = new ArchiveTransferManager(
                      client, credentials);

                  String fileLength = Long
                      .toString(uploadFileBatch[i]
                          .length());

                  uw.setTitle("(" + (i + 1) + "/"
                      + uploadFileBatch.length + ")"
                      + " Uploading: " + thisFile);

                  UploadResult result = atm.upload(vaultName,
                      cleanFile, uploadFileBatch[i]);

                  uw.addToLog("Done: " + thisFile + "\n");

                  uploadedSize += uploadFileBatch[i].length();
View Full Code Here

    download(vaultName, archiveId, downloadFile);
  }

  public void download(final String vaultName, final String archiveId, final File targetFile) {
    log.info("Downloading archive " + archiveId + " from vault " + vaultName + "...");
    final ArchiveTransferManager atm = new ArchiveTransferManager(client, sqs, sns);
    atm.download(vaultName, archiveId, targetFile);
    log.info("Archive downloaded to " + targetFile);
  }
View Full Code Here

  }

  public void upload(final String vaultName, final File uploadFile) {
    log.info("Starting to upload " + uploadFile + " to vault " + vaultName + "...");
    try {
      final ArchiveTransferManager atm = new ArchiveTransferManager(client, sqs, sns);
      final String archiveId = atm.upload(vaultName, uploadFile.getName(), uploadFile).getArchiveId();
      log.info("Uploaded archive " + archiveId);
    } catch (final IOException e) {
      log.error("Something went wrong while uploading " + uploadFile + vaultName + "to vault " + ".", e);
    }
  }
View Full Code Here

TOP

Related Classes of com.amazonaws.services.glacier.transfer.ArchiveTransferManager

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.