Activating the SharePoint Server Publising Feature in parallel

Copper Contributor

Hi All,

 

For the moment we are still using our own site provisioning solution, but, off course the office dev Pnp nuget package is references and we are using as much as office dev pnp extension methods as possible.

 

I just wanted to ask a question about activating the "SharePoint Server Publishing" site collection feature.

I know when activating this feature via the SharePoint UI (Site Settings > Site collection features), it also takes quite some time before it's fully activated, but when doing this via code, it feels even worse :(

I wonder if there's something that can be done to increase the performance.

 

For the moment I have 2 webjobs running in Azure, each using a different service account. Each job/worker is picking up requests to provision site collections and apply a template to the site.

Basically what happens is

1. Create site collection

2. Set security

3. Activate site collection Server Publishing feature...

4. Apply template (create lists, content, navigation, ...)

 

What I experience is that the activation of the Server Publishing site collection feature is almost taking 15min per site!! Sometimes even more. See screenshot.

Also when a feature activation is running, also all the other actions seem to run very slow!

Basically site collection creation + activation of the feature takes about 20min per site, after that we need about 2 more minutes to create all the lists and content... So if we could gain time/performance with the feature activation, that would massively increase throughput. As we want to provision about 8.000 site collections in the near future, each minute (maybe even second) counts :)

 

Is the activation of the server publishing feature such a heavy operation that it should not be run in parallel?

Any tips or guidance to increase the throughput are highly appreciated!

Thanks

 

FYI:

The modified field in the screenshot, is the time of when the action was launched (create site, activate feature, ...)

To activate the feature I'm using the office devpnp extension method --> ctx.Site.ActivateFeature(featureToActivate.ID);

 

I'll try to upload similar images, in which you see both requests are waiting, and both are in status "activating features...", and both are started more then 15min ago.

 

Kind Regards,

Thomas

 

3 Replies

I have seen the same slow peformance for several years. While there have been alot of perf improvements in many areas of SPO, this feature activation process has not received any attention in many years.

The Publishing feature is just real slow it takes between 5-30 min i have seen this behaivor on premm and in the cloud. don't know if it is going to speed up but i guess a lot of handling is done in the backend

Hi,

 

We've been struggling with the same problem. Sometimes it has taken hours to activate the publishing infrastructure feature on a single site collection (in SPO). It probably comes back to the architectural decisions made when SharePoint (Site server) was poorly funded many years ago and seems there's little we can do.  How did it turn out with processing multiple requests in parallel?

 

Mark