Resource Content (read and write) on Azure Slotted Deploys

You’d still have the same though.. if this was warming up against the same DB.. you’ve made a load balanced environment.. server roles could be set looking at the environment name. Which would be slot sticky..

Also you’d have to be very careful warming the staging slot up against the same DB, as schema changes etc would be applied to the DB, potentially bringing down the production site?

Another one to mention is WEBSITE_DISABLE_OVERLAPPED_RECYCLING=1
MainDom Lock Timeout on Azure App Service - Looking for Solution - Umbraco community forum
So that would stop two sites (main and slot) from running a concurrently, but then you’ve potentially lost your reason for hot slot swapping in the first place?

Also I’m questioning that a slot would share a filesystem, I thought slots were completely independent, so the FileSystemMainDomLock should be fine in a slot scenario? :thinking:

So wondering if the crash is actaully the fact in v13 you can’t have two SchedulingPublishers (backoffices) which explict server roles could solve,

public class ServerRegistrar : IServerRoleAccessor
{
    private readonly IWebHostEnvironment _env;

    public ServerRegistrar(IWebHostEnvironment env)
    {
        _env = env;
    }

    public ServerRole CurrentServerRole
    {
        get
        {
            return _env.EnvironmentName.ToLower() switch
            {
                string n when n.EndsWith("api") => ServerRole.SchedulingPublisher,
                "development" => ServerRole.Single,
                _ => ServerRole.Subscriber,
            };
        }
    }
}

public class RegisterServerRegistrar : IComposer
{
    public void Compose(IUmbracoBuilder builder) => builder.SetServerRegistrar<ServerRegistrar>();
}

ps you can now load balance the backoffice in v17 (with config changes) :slight_smile: