SaaS CMS has officially launched! Learn more now.

TWO EPiServer Web Project in One Solution Do not work on Parrallel run



I am having two EPiServer Web Project (WebProject1 and WebProject2) pointing to the same Database. And The EPiServer Page/Block/Variation Models are placed in Common Assembly project (Web.Common) reference to the both (WebProject1 and WebProject2) application.

Running the project induvidually works well. But accessing them in the same time keep the Site Down. EPI APIs Do not work. IContentLoader actions threws Null exception.

Do we missed any configs in this approach?

Can you help us?



Aug 09, 2018 17:28

Hi, why do you try to use the same database for two different sites (based on your description you have two IIS web sites as you have two different codebases)? As you have to separate sites you should have own database per site.

Same database is used in multi-site setup but the sites have the same code base in that case.

Aug 09, 2018 17:58


Due to the bussiness need we are approching the way. Since contents are shared among the sites. But WebProject1 is act as the Website. WebProject2 will be used as WebService calls.

Aug 09, 2018 18:02

That sounds completely dangerous that you have two separate websites running the same database. You can do that with the same application running on the same database when you're doing a load balanced environment. But this is really asking for trouble.

I agree with Antti, If you really want to have two websites (domains) I'd say it's better to have a multisite solution with only one IIS site and multiple start pages in Epi.

Aug 09, 2018 22:52


I completely agree with you. But In our end, Its completely depends on running them in the seperate IIS thread due to performance concerns. The WebProject1 is running on heavy weight implementation having depenendency with 3rd party webservice calls. But WebProject2 does not have any 3rd party dependencies.

Considering the performance factor we have decided to seperate them to running in each IIS instance.

is that possible or not while via referencing the same assembly having the EPi models?

Aug 10, 2018 12:22

What kinds of performance concerns?

Otherwise, what about using the same application that contains both the website and the webservices, but one site only receives webservice traffic and the other one the website-traffic?

Aug 10, 2018 12:54


Due to the 3rd party WebService calls in the WebProject1, may goes down/too slow interms of App Pool Utilization whenever the 3rd party responses are lagging. So for, We are planning to use seperate app pool instances.

Aug 10, 2018 15:07

That is a very dangerous setup that I would not recommend at all.

If I read and understand your need correctly you have the need for one site and one api.

If that is the case the I would recommend you to not have two episerver sites, but one and then an ordinary web api solution in for example .net core.

If you need authentication between them you could implement that with federated security and for example IdentityServer 4.

This will give you the best solution and best performance

Aug 10, 2018 17:53

Thank you Henrik...

We will plan accodingly as all of your suggestions.

Thank you All...

Aug 12, 2018 13:51

Great! And your welcome!

Please mark those answers you felt were helpful as answers


Aug 13, 2018 8:17
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.