Copied to clipboard

Flag this post as spam?

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


  • stephen 83 posts 124 karma points
    Mar 18, 2021 @ 08:40
    stephen
    0

    Umbraco Form UpdateRecord Slow and spikes CPU

    using (var storage = new RecordStorage())
            {
                record.State = FormState.Submitted;
                storage.UpdateRecord(record, form);
                storage.Dispose();
            }
    

    Using the above example to update a record field but it results in high CPU/memory spikes and timeouts. Is there any known issues with this?

  • AddWeb Solution Pvt. Ltd 109 posts 360 karma points
    Mar 23, 2021 @ 05:00
    AddWeb Solution Pvt. Ltd
    0

    Hello,

    try, delete and insert like this :-

    public static void UpdateRecord(Record record)
    {
    var form = record.GetForm();
    using (var recordStorage = new RecordStorage())
    {
    recordStorage.DeleteRecord(record, form);
    recordStorage.InsertRecord(record, form);
    }
    }
    

    Checkout this link, as there might be many reason for CPU spikes :-

    https://moriyama.co.uk/about-us/news/blog-fixing-umbraco-100-cpu-spikes-and-crashes/#:~:text=The three common reasons for, necessary and can be refactored.

  • Nicholas Westby 2054 posts 7103 karma points c-trib
    Mar 23, 2021 @ 16:37
    Nicholas Westby
    0

    Last time I checked (which, granted, was apparently 6 years ago), it was a known issue that, as far as I know, never got resolved (Contour is the old name for Umbraco Forms): https://our.umbraco.com/forum/umbraco-pro/contour/72902-contour-submissions-extremely-slow

    The main issue there was DFS replicating the giant licensing log file. However, once that was resolved, and after the HQ team provided some updated DLL's, submissions were still taking 12 or so seconds.

    I am not sure if that's what you're seeing now, but should give you some historical perspective that similar issues have long been a problem. Sometimes, you can improve the situation.

    You'd first want to track down the exact cause of the issue if you want to make any headway in resolving it.

  • stephen 83 posts 124 karma points
    Mar 27, 2021 @ 12:35
    stephen
    0

    thanks for the response. I removed it as felt it was unreliable.

Please Sign in or register to post replies

Write your reply to:

Draft