Search Results for

    Show / Hide Table of Contents
    View Source

    Class MiniDump

    Provides functionality to create Windows minidump files for diagnostic purposes.

    Inheritance
    object
    Namespace: Umbraco.Cms.Core.Diagnostics
    Assembly: Umbraco.Core.dll
    Syntax
    public static class MiniDump
    Remarks

    This class enables the creation of memory dump files that can be analyzed to diagnose application crashes and other issues.

    Based on: https://blogs.msdn.microsoft.com/dondu/2010/10/24/writing-minidumps-in-c/ and https://blogs.msdn.microsoft.com/dondu/2010/10/31/writing-minidumps-from-exceptions-in-c/ which itself got it from http://blog.kalmbach-software.de/2008/12/13/writing-minidumps-in-c/

    Methods

    View Source

    Dump(IMarchal, IHostingEnvironment, Option, bool)

    Creates a minidump file in the MiniDump directory.

    Declaration
    public static bool Dump(IMarchal marchal, IHostingEnvironment hostingEnvironment, MiniDump.Option options = Option.WithFullMemory, bool withException = false)
    Parameters
    Type Name Description
    IMarchal marchal

    The marshalling interface for getting exception pointers.

    IHostingEnvironment hostingEnvironment

    The hosting environment for path resolution.

    MiniDump.Option options

    The dump options specifying what information to include.

    bool withException

    Whether to include exception information in the dump.

    Returns
    Type Description
    bool

    true if the dump was created successfully; otherwise, false.

    View Source

    OkToDump(IHostingEnvironment)

    Determines whether it is safe to create a new dump file.

    Declaration
    public static bool OkToDump(IHostingEnvironment hostingEnvironment)
    Parameters
    Type Name Description
    IHostingEnvironment hostingEnvironment

    The hosting environment for path resolution.

    Returns
    Type Description
    bool

    true if fewer than 8 dump files exist; otherwise, false.

    Remarks

    This method limits the number of dump files to prevent disk space exhaustion.

    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX