In the current functionality, we retrieve custom labels from the source organization. The labels are retrieved from salesforce into another Salesforce organization. However, when retrieving the labels we hit the 3 MB Web service governor limit. For the other metadata types, we first get the list of all the objects/components, and we break up those components into smaller chunks so that we can get the entire payload which is less than 3 MB.
However, with custom labels, when we just try to get the list of all the custom labels, we hit the exception. So, we have no way of retrieving the names of the custom labels or the complete definition of the custom labels.
We have tried with the metadata API as well as the tooling API.
What are you thoughts on this? How can we retrieve custom labels or custom fields from another organization without hitting this limit.
The maximum number of custom labels in an organization can be 5000. If we assume that the size of each custom level is 200 bytes, then the total size of all the custom tables is 1 MB. However, we hit still the 3 MB exception limit since the encryption/tokenization takes the rest of the space. What can we do to maximize payload size?
Please advise.