Runtime Profiling

Heimdall can expose runtime profiling data in the profile.proto format (also known as pprof format), which can be consumed by many APM tools, like Google’s pprof, Grafana Phlare, Pyroscope and many more for analysis and visualization purposes. By default, this service is disabled. If enabled, the profiling information is available on 127.0.0.1:10251/debug/pprof endpoint.

Configuration

Configuration for this service can be adjusted in the profiling property of heimdall’s configuration by making use of the following properties.

  • enabled: boolean (optional)

    By making use of this property, you can configure heimdall to enable or disable runtime profiling. Defaults to false (profiling disabled).

    Example 1. Enabling profiling.
    profiling:
      enabled: true
  • host: string (optional)

    By making use of this property, you can specify the TCP/IP address on which heimdall should listen for connections from client applications interested in profiling data. The entry 0.0.0.0 allows listening for all IPv4 addresses. Defaults to 127.0.0.1, which allow only local TCP/IP “loopback” connections to be made.

    If you operate heimdall in a container, you should set this property to a value, which would allow your APM system to scrape this information.
    Example 2. Configure heimdall to listen on 192.168.2.10.
    profiling:
      host: 192.168.2.10
  • port: integer (optional)

    By making use of this property, you can specify the TCP port the heimdall should listen on. Defaults to 10251.

    Example 3. Configure heimdall to listen on port 9999 for runtime profiling requests.
    metrics:
      port: 9999

Last updated on Jan 20, 2023