Tuesday, November 27, 2018

SharePoint Online Data Access Performance test - CSOM and PowerShell / C#

Two years ago, I did a similar test on SharePoint 2016. That's through server-side API.

Now, it's time to test SharePoint Online through client side CSOM + PowerShell.

SharePoint Online as access threshold for one user, which make it hard to test "multiple thread" performance.

However, we still can test "ExecuteQuery for each item" and "ExecuteQuery for a batch of items".

I assume the SharePoint Online host center is quite close to where I am, as the network latency is less than 3 ms for tenant 1, and less than 15 ms for tenant 2.

* The test is based on two different tenants and 100 list items.
* The unit in the table below is "items per second".
* There is no "Bulk commit" for Delete, Recycle and Retrieve.
* 5 single-line text fields in the test list.

ActionSingle, tenant 1Single, tenant 2Bulk, tenant 1Bulk, tenant 2
Insert7.16.614.112.7
Update8.67.121.313.5
Delete5.86.310.410.4
Retrieve11.913.310001000

For single item "insert", it takes around 140 ms.

The performance is around 25% of SharePoint 2016 (local server). This is disappointing, even if we exclude the 15 ms consumed on the traffic.

So, it's fast for "read-only" access on SharePoint Online, but pretty slow for any "write" access.

[update, 2018-12-07]

PowerShell script is slower than C#, so I did some other test by C#

Run the C# code remotely

ActionSingle, test 1Single, test 2Bulk, test 1Bulk, test 2
Insert6.906.097.7912.91
Update7.946.4219.4917.25
Delete6.016.005.786.34
Recycle6.466.596.377.10
Retrieve1307.851183.34807.41746.23


Run the C# code from Azure API Apps

ActionSingle, test 1Single, test 2Bulk, test 1Bulk, test 2
Insert8.177.147.1412.35
Update10.638.168.1614.93
Delete7.696.416.417.12
Recycle9.086.766.766.68
Retrieve2133.051600.181600.181280.42

Not much difference.

No comments:

Post a Comment