Wanchai / FTPbucket

FTPbucket is a PHP script that enables you to sync your BitBucket or GitHub repository with any web-server
102 stars 22 forks source link

Idea: Better handling for REST API limit #28

Open d2roth opened 4 years ago

d2roth commented 4 years ago

BitBucket limits requests to about 1000/hour. Every minute you get a few more requests. When handling pushes with a large number of files this can be problematic. One thought I have for a solution is to fetch a ZIP of the repository and then extract the zip and push just the changed files up to the remote server. I am not sure if there would be a config switch/opt-in/out or something else for this but it would be easier on BitBucket's servers I think when handling a large number of changed files.

Their Rate limits are here: https://confluence.atlassian.com/bitbucket/rate-limits-668173227.html

My concern is what if the repository you are pushing is very big and you just changed a bunch of files? Like changing 1,500 files, say adding some icons, to a repository that is 200MB. Would that cause problems for the server hosting FTPBucket? Too much memory or something.