Fetch resources for uploading one-by-one to save memory
Fetch remote records in chunks of max. 50 to avoid server and memory problems

* performance optimisation
* refactoring