Activating the SharePoint Server Publising Feature in parallel

%3CLINGO-SUB%20id%3D%22lingo-sub-33296%22%20slang%3D%22en-US%22%3EActivating%20the%20SharePoint%20Server%20Publising%20Feature%20in%20parallel%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-33296%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20All%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EFor%20the%20moment%20we%20are%20still%20using%20our%20own%20site%20provisioning%20solution%2C%20but%2C%20off%20course%20the%20office%20dev%20Pnp%20nuget%20package%20is%20references%20and%20we%20are%20using%20as%20much%20as%20office%20dev%20pnp%20extension%20methods%20as%20possible.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20just%20wanted%20to%20ask%20a%20question%20about%20activating%20the%20%22SharePoint%20Server%20Publishing%22%20site%20collection%20feature.%3C%2FP%3E%3CP%3EI%20know%20when%20activating%20this%20feature%20via%20the%20SharePoint%20UI%20(Site%20Settings%20%26gt%3B%20Site%20collection%20features)%2C%20it%20also%20takes%20quite%20some%20time%20before%20it's%20fully%20activated%2C%20but%20when%20doing%20this%20via%20code%2C%20it%20feels%20even%20worse%20%3A(%3C%2Fimg%3E%3C%2FP%3E%3CP%3EI%20wonder%20if%20there's%20something%20that%20can%20be%20done%20to%20increase%20the%20performance.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EFor%20the%20moment%20I%20have%202%20webjobs%20running%20in%20Azure%2C%20each%20using%20a%20different%20service%20account.%20Each%20job%2Fworker%20is%20picking%20up%20requests%20to%20provision%20site%20collections%20and%20apply%20a%20template%20to%20the%20site.%3C%2FP%3E%3CP%3EBasically%20what%20happens%20is%3C%2FP%3E%3CP%3E1.%20Create%20site%20collection%3C%2FP%3E%3CP%3E2.%20Set%20security%3C%2FP%3E%3CP%3E3.%20Activate%20site%20collection%20Server%20Publishing%20feature...%3C%2FP%3E%3CP%3E4.%20Apply%20template%20(create%20lists%2C%20content%2C%20navigation%2C%20...)%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EWhat%20I%20experience%20is%20that%20the%20activation%20of%20the%20Server%20Publishing%20site%20collection%20feature%20is%20almost%20taking%2015min%20per%20site!!%20Sometimes%20even%20more.%26nbsp%3BSee%20screenshot.%3C%2FP%3E%3CP%3EAlso%20when%20a%20feature%20activation%20is%20running%2C%20also%20all%20the%20other%20actions%20seem%20to%20run%20very%20slow!%3C%2FP%3E%3CP%3EBasically%20site%20collection%20creation%20%2B%20activation%20of%20the%20feature%20takes%20about%2020min%20per%20site%2C%20after%20that%20we%20need%20about%202%20more%20minutes%20to%20create%20all%20the%20lists%20and%20content...%20So%20if%20we%20could%20gain%20time%2Fperformance%20with%20the%20feature%20activation%2C%20that%20would%20massively%20increase%20throughput.%20As%20we%20want%20to%20provision%20about%208.000%20site%20collections%20in%20the%20near%20future%2C%20each%20minute%20(maybe%20even%20second)%20counts%20%3A)%3C%2Fimg%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20the%20activation%20of%20the%20server%20publishing%20feature%20such%20a%20heavy%20operation%20that%20it%20should%20not%20be%20run%20in%20parallel%3F%3C%2FP%3E%3CP%3EAny%20tips%20or%20guidance%20to%20increase%20the%20throughput%20are%20highly%20appreciated!%3C%2FP%3E%3CP%3EThanks%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EFYI%3A%3C%2FP%3E%3CP%3EThe%20modified%20field%20in%20the%20screenshot%2C%20is%20the%20time%20of%20when%20the%20action%20was%20launched%20(create%20site%2C%20activate%20feature%2C%20...)%3C%2FP%3E%3CP%3ETo%20activate%20the%20feature%20I'm%20using%20the%20office%20devpnp%20extension%20method%20--%26gt%3B%20ctx.Site.ActivateFeature(featureToActivate.ID)%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI'll%20try%20to%20upload%20similar%20images%2C%20in%20which%20you%20see%20both%20requests%20are%20waiting%2C%20and%20both%20are%20in%20status%20%22activating%20features...%22%2C%20and%20both%20are%20started%20more%20then%2015min%20ago.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EKind%20Regards%2C%3C%2FP%3E%3CP%3EThomas%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-52246%22%20slang%3D%22en-US%22%3ERe%3A%20Activating%20the%20SharePoint%20Server%20Publising%20Feature%20in%20parallel%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-52246%22%20slang%3D%22en-US%22%3E%3CP%3EHi%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EWe've%20been%20struggling%20with%20the%20same%20problem.%20Sometimes%20it%20has%20taken%20hours%20to%20activate%20the%20publishing%20infrastructure%20feature%20on%20a%20single%20site%20collection%20(in%20SPO).%20It%20probably%20comes%20back%20to%20the%20architectural%20decisions%20made%20when%20SharePoint%20(Site%20server)%20was%20poorly%20funded%20many%20years%20ago%20and%20seems%20there's%20little%20we%20can%20do.%20%26nbsp%3BHow%20did%20it%20turn%20out%20with%20processing%20multiple%20requests%20in%20parallel%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EMark%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-33439%22%20slang%3D%22en-US%22%3ERe%3A%20Activating%20the%20SharePoint%20Server%20Publising%20Feature%20in%20parallel%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-33439%22%20slang%3D%22en-US%22%3E%3CP%3EThe%20Publishing%20feature%20is%20just%20real%20slow%20it%20takes%20between%205-30%20min%20i%20have%20seen%20this%20behaivor%20on%20premm%20and%20in%20the%20cloud.%20don't%20know%20if%20it%20is%20going%20to%20speed%20up%20but%20i%20guess%20a%20lot%20of%20handling%20is%20done%20in%20the%20backend%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-33313%22%20slang%3D%22en-US%22%3ERe%3A%20Activating%20the%20SharePoint%20Server%20Publising%20Feature%20in%20parallel%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-33313%22%20slang%3D%22en-US%22%3E%3CP%3EI%20have%20seen%20the%20same%20slow%20peformance%20for%20several%20years.%20While%20there%20have%20been%20alot%20of%20perf%20improvements%20in%20many%20areas%20of%20SPO%2C%20this%20feature%20activation%20process%20has%20not%20received%20any%20attention%20in%20many%20years.%3C%2FP%3E%3C%2FLINGO-BODY%3E
Occasional 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