Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support configuration-cache for S3Sync #15

Open
nedtwigg opened this issue Oct 20, 2021 · 0 comments
Open

Support configuration-cache for S3Sync #15

nedtwigg opened this issue Oct 20, 2021 · 0 comments

Comments

@nedtwigg
Copy link

nedtwigg commented Oct 20, 2021

This plugin doesn't support configuration cache. There are two problems for S3Sync:

  1. Easy to fix by injecting ObjectFactory and using ObjectFactory.fileTree().from(dir)

    getProject().fileTree(source).visit(new EmptyFileVisitor() {
    public void visitFile(FileVisitDetails element) {
    es.execute(
    new UploadTask(s3, element, bucketName, prefix, storageClass, acl, metadataProvider,
    getLogger()));
    }
    });

  2. Harder to fix

    AmazonS3PluginExtension ext = getProject().getExtensions().getByType(AmazonS3PluginExtension.class);
    AmazonS3 s3 = ext.getClient();

Not a big deal, very easy to just add --no-configuration-cache when doing an upload.

EDIT: P.S. Thanks for resurrecting this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant