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

Use the bucket listing #49

Open
dennari opened this issue Feb 25, 2015 · 5 comments
Open

Use the bucket listing #49

dennari opened this issue Feb 25, 2015 · 5 comments

Comments

@dennari
Copy link

dennari commented Feb 25, 2015

Hi! I've been running into some performance issues that have to do with making a separate headObject request for every file. Why not use the GET Bucket (List Objects) command and get the ETags for 1000 files at a time?

@pgherveou
Copy link
Owner

Have you considered

That's sound a bit harder to develop, but if that does not work for you, you can give it a try

@dennari
Copy link
Author

dennari commented Feb 25, 2015

Well, the cache works really well in a local setup, but in a shared CI environment it's harder to set up. Parallelization would probably help to a degree, but I don't think its a solution that scales. Here's an outline to a solution that does scale: Getting Size and File Count of a 25 Million Object S3 Bucket. Is there some reason you wouldn't like to use the LIST API calls?

@pgherveou
Copy link
Owner

I think the current solution works well for most of the use cases

Concerning your use case what I think what would be best, would be:

  • to add an additional method that let you populate the cache
  • to add an an option to by pass the header requests

So to solve your problem you could then

  • create a transform stream or call an async function that feed the cache
  • call publish

it could look like this

  var publisher = awspublish.create({ bucket: '...' });
  return gulp
     .src('./public/*.js')
     .pipe(publisher.populateCache())
     .pipe(publisher.publish())
     .pipe(awspublish.reporter());

What do you think?

@alexgorbatchev
Copy link
Collaborator

@dennari curious, were you able to find a suitable solution?

@cedricve
Copy link

Is there any news about the feature request?

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

No branches or pull requests

4 participants