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

force.com export gets LIMIT_EXCEEDED exception #19

Open
lpoulain opened this issue Nov 19, 2013 · 9 comments
Open

force.com export gets LIMIT_EXCEEDED exception #19

lpoulain opened this issue Nov 19, 2013 · 9 comments
Labels

Comments

@lpoulain
Copy link

Running force.com export gives the following error:

ERROR: LIMIT_EXCEEDED: Too many files in retrieve call, limit is: 5000

I guess my org is too large, but I'm not sure how to export just the metadata for a single SObject.

@ddollar
Copy link
Contributor

ddollar commented Nov 19, 2013

/cc @ryanbrainard @dcarroll @quintonwall

What can we do to export such a large org? Can the export be paginated somehow?

@lpoulain
Copy link
Author

For what it's worth, I'm just trying to get the metadata for one SObject.

@ddollar
Copy link
Contributor

ddollar commented Nov 19, 2013

Are you looking for the XML metadata? Do you want to use it externally or run it back through force import ?

@lpoulain
Copy link
Author

Run back through force import. The enhancement I'd like to work on (if I am able to rebuild the project) is to look at permissions (OLS, FLS) and harmonize them.

@ddollar
Copy link
Contributor

ddollar commented Nov 19, 2013

That sounds great. I'd be happy to answer any questions you have along the way.

Let's leave this issue open to track the LIMIT_EXCEEDED error because it seems like a legitimate problem for large orgs. If you'd like to create another issue/pull request to track your enhancement we can discuss there.

@pfeilbr
Copy link

pfeilbr commented Nov 21, 2013

TLDR: Don't try to solve within this tool

This is a general salesforce problem and should be solved at that level. Salesforce doesn't provide a pagination option as of now, but the other tools that deal with this pull subsets of the metadata types per request and merge into the final full directory structure on disk. The issue is that you need to have a backoff retry mechanism to get under LIMIT_EXCEEDED, but each async request takes time and you could be waiting a while. The other bigger issue and the reason salesforce needs to solve for it is because the metadata could change between requests, and you end up with an inconsistent full metadata set.

This problem is only going to get worse with this tool. The barrier to entry to create metadata has been reduced with this tool, which leads to experimentation / more metadata (which is great), and users most likely won't clean up. At the point they decided to provide a file representation of the metadata sitting in a database, they should've considered this. The full metadata state of any org should be able to be downloaded as an archive file at any time.

@dcarroll
Copy link
Contributor

You are correct, the metadata api is not intended to get everything. It is why there are "on platform" ways to cut a sandbox, create change sets and so on. This kind of tool, and the usefulness of it, were not anticipated. I will gladly relate a request for pagination or some other strategy for getting the full set of metadata, through apis, to the engineering team.

@danielsokolowski
Copy link

Has there been any progress on this API limit pagination idea?

@cwarden
Copy link
Member

cwarden commented Nov 16, 2023

Merging the profiles after multiple exports should be feasible. See https://github.com/ForceCLI/force-md/blob/b8b2154b3bc6f28302cdbfeb990126bb47e597f4/cmd/profile/merge.go#L40

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

No branches or pull requests

6 participants