Package com.amazonaws.services.cloudfront.model

Examples of com.amazonaws.services.cloudfront.model.InvalidationBatch


    if (results.isEmpty())
      return;

    List<String> paths = new ArrayList<String>();

    InvalidationBatch batch = new InvalidationBatch("invalidate-" + d.id);
    CreateInvalidationRequest invalidationRequest = new CreateInvalidationRequest()
        .withDistributionId(d.id).withInvalidationBatch(batch);

    for (Map.Entry<String, PutObjectRequest> entry : results.entrySet()) {
      String key = entry.getKey();
      PutObjectRequest request = entry.getValue();

      if (null != request && request.getBucketName().equals(d.s3Bucket)) {
        paths.add("/" + request.getKey());
      } else {
        paths.add("/" + key);
      }
    }

    if (!paths.isEmpty()) {
      batch.setPaths(paths);

      invalidationRequest.withInvalidationBatch(batch);

      getService().createInvalidation(invalidationRequest);
    } else {
View Full Code Here


    if (results.isEmpty())
      return;

    List<String> paths = new ArrayList<String>();

    InvalidationBatch batch = new InvalidationBatch("invalidate-" + d.id);
    CreateInvalidationRequest invalidationRequest = new CreateInvalidationRequest()
        .withDistributionId(d.id).withInvalidationBatch(batch);

    for (Map.Entry<String, PutObjectRequest> entry : results.entrySet()) {
      String key = entry.getKey();
      PutObjectRequest request = entry.getValue();

      if (null != request && request.getBucketName().equals(d.s3Bucket)) {
        paths.add("/" + request.getKey());
      } else {
        paths.add("/" + key);
      }
    }

    if (!paths.isEmpty()) {
      batch.setPaths(new Paths().withItems(paths));

      invalidationRequest.withInvalidationBatch(batch);

      getService().createInvalidation(invalidationRequest);
    } else {
View Full Code Here

    if (results.isEmpty())
      return;

    List<String> paths = new ArrayList<String>();

    InvalidationBatch batch = new InvalidationBatch("invalidate-" + d.id);
    CreateInvalidationRequest invalidationRequest = new CreateInvalidationRequest()
        .withDistributionId(d.id).withInvalidationBatch(batch);

    for (Map.Entry<String, PutObjectRequest> entry : results.entrySet()) {
      String key = entry.getKey();
      PutObjectRequest request = entry.getValue();

      if (null != request && request.getBucketName().equals(d.s3Bucket)) {
        paths.add("/" + request.getKey());
      } else {
        paths.add("/" + key);
      }
    }

    if (!paths.isEmpty()) {
      batch.setPaths(new Paths().withItems(paths));

      invalidationRequest.withInvalidationBatch(batch);

      getService().createInvalidation(invalidationRequest);
    } else {
View Full Code Here

    if (results.isEmpty())
      return;

    List<String> paths = new ArrayList<String>();

    InvalidationBatch batch = new InvalidationBatch("invalidate-" + d.id);
    CreateInvalidationRequest invalidationRequest = new CreateInvalidationRequest()
        .withDistributionId(d.id).withInvalidationBatch(batch);

    for (Map.Entry<String, PutObjectRequest> entry : results.entrySet()) {
      String key = entry.getKey();
      PutObjectRequest request = entry.getValue();

      if (null != request && request.getBucketName().equals(d.s3Bucket)) {
        paths.add("/" + request.getKey());
      } else {
        paths.add("/" + key);
      }
    }

    if (!paths.isEmpty()) {
      batch.setPaths(paths);

      invalidationRequest.withInvalidationBatch(batch);

      getService().createInvalidation(invalidationRequest);
    } else {
View Full Code Here

TOP

Related Classes of com.amazonaws.services.cloudfront.model.InvalidationBatch

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.