uSync Performance Tuning
We work hard to make uSync's impact on your site as small as possible, but as your site gets larger some of the work uSync has to do to keep the sync folders in order will increase.
In most cases you shouldn't need to tune uSync performance.
The following tips can help you do less work, and make uSync run faster.
Keep uSync Up to Date​
Running the latest version of uSync will ensure you are running with all the latest fixes and updates. This way uSync can run as fast and trouble free as possible.
You can keep an eye on the latest releases on the uSync github page. You can also check the issues for performance
label to see if we have made any performance related improvements or fixes.
Keep Your uSync Folder Up to Date​
Occasionally an update in Umbraco or uSync functionality will cause us to make a change in the format/detail of the uSync .config
files. When this happens, we will increment the 'format version' of the files and uSync will warn you that the files might be using an old version.
Within a major version and often between major versions the files will still be compatible but changes can lead to "false positives" when checking files.
Checks are always faster then import operations, To minimize "false positives" in uSync when checking files, perform clean exports after you upgrade uSync minor versions (e.g 10.0 -> 10.1).
Use Flat Folders and Guid Filenames​
Switching to guid file names will reduce the amount of checks that uSync needs to perform when an item is saved or deleted. Flat folders reduce the need to check multiple folders when an item is moved in Umbraco.
Switching to guid file names on a large site will can have an impact on save/update times.
Don't Sync Content/Media If You Don't Need to.​
The default configuration for uSync will sync content and media items to disk when they are saved. If you are not going to use 'standard' uSync to sync content (e.g via the uSync dashboard) then you can turn off the content and media sync.
If you are using uSync.Complete and uSync.Publisher to push and pull your content between sites you can turn off the default Content/Media as the the files in the uSync/v9 folder are not used for this process.
To only sync settings to disk you can set the ExportOnSave
setting to Settings
in the appsettings.json
file:
{
"uSync": {
"Settings": {
"ExportOnSave": "Settings",
}
}
}
Don't Import at Startup​
For uSync v9+ Import at Startup is off by default, but if turned on on a large import during startup it can impact the start times for your site. While a sync might only take a few seconds, during this time the site will still be 'booting' and may not be available to users.
Ensure Import at Startup is off for your site.
This setting is off by default, so if there is no entry in your appsettings.json file, ImportAtStartup will be false
{
"uSync": {
"Settings": {
"ImportAtStartup": "None",
}
}
}