Review performance and process considerations when inserting many users using Bulk API, Data Loader, or other tools for bulk processing.
Scenario:
For example, an admin needs to create 5,000 partner portal users for a new Experience Cloud site launch. Using parallel Bulk API processing without deferring group membership calculations causes record-level locking errors and job failures.
Inserting role-based users (such as internal, customer, and partner users) is significantly slower than inserting high-volume community or site users.
Test the performance of inserting users using the same type of user that will be inserted during the actual operation.
Consider what type of users are needed for your business needs based on capabilities, security, and performance.
When inserting role-based users, several related processes occur to make sure access is calculated correctly. These processes can result in record-level locking or group membership locking if multiple threads are inserting users. Multiple threads can occur if the user insert job itself is being processed in parallel or if there's another update job running simultaneously.
To expedite the processing of bulk inserting role-based users and reduce the chances of locking, we suggest that you:
Defer group membership calculations (which also defers sharing rule calculations)
Use sequential mode for bulk processing
Suspend other jobs and activities that perform user, role, and group maintenance
Use smaller batch sizes if experiencing timeouts
004576984

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.