Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Simon Baudart 2 posts 23 karma points
    Jan 24, 2017 @ 08:02
    Simon Baudart
    1

    Load Balancer and call to the ContentService

    Hello all,

    We are developing some Umbraco websites for our clients and we host our applications on Azure. Most of the time, the selected plans are with auto-scale and we set up a master server for the back end.

    In our code, sometimes, we are required to import data from external sources into Umbraco and we use the ContentService. Here is an example :

    var node = UmbracoContext.Current.Application.Services.ContentService.CreateContent(data.Name, parent, "details");
    node.SetValue("myProperty", data.TheValue);
    UmbracoContext.Current.Application.Services.ContentService.SaveAndPublishWithStatus(node);
    

    Can we do this on a load balanced hosting ? Is the ContentService safe or do we have to run these jobs on only one instance ?

    Thanks a lot for your help, I did not find any information about this and we have some of our database that gets corrupted without any reason. We think that this could be an issue, but not sure.

    Simon

  • Damien Holley 180 posts 541 karma points
    Nov 03, 2022 @ 22:25
    Damien Holley
    0

    Just asked essentially this question of Umbraco. +1 to this forum post (will post if I get a solution)

    My query was how do we make sure a service func called from the frontend is processed on the master.

  • Yakov Lebski 591 posts 2346 karma points
    Nov 03, 2022 @ 22:44
    Yakov Lebski
    0

    A possible solution, for example, based on hangfire on any other queue

    1. a front server creating a job
    2. master taking the job and executing the job
Please Sign in or register to post replies

Write your reply to:

Draft