profefe

package
v0.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	// The URL of the Profefe service. The config value may be a [placeholder](https://caddyserver.com/docs/conventions#placeholders).
	Address string `json:"address,omitempty"`

	// The service name reported to Profefe. The config value may be a [placeholder](https://caddyserver.com/docs/conventions#placeholders).
	Service string `json:"service,omitempty"`

	// The timeout for the upload call. Setting the value to `0` disables the timeout and the call waits indefinitely until the upload is finished.
	Timeout caddy.Duration `json:"timeout,omitempty"`

	// The profiling parameters to be reported to Profefe.
	// The paramters cpu_profile_rate, block_profile_rate, and mutex_profile_fraction are inherited from the `profiling` app if `profefe`
	// is configured as a child module. The `profile_types` field is inherited if not configured explicitly.
	// If `profefe` is configured as an app, all the parameters are instated as-is.
	Parameters *caddy_profiling.Parameters `json:"parameters,omitempty"`
	// contains filtered or unexported fields
}

The `profefe` app collects profiling data during the life-time of the process and uploads them to the profefe server.

func (*App) CaddyModule

func (*App) CaddyModule() caddy.ModuleInfo

CaddyModule implements caddy.Module

func (*App) Provision

func (p *App) Provision(ctx caddy.Context) error

Provision implements caddy.Provisioner

func (*App) SetProfilingParameter

func (a *App) SetProfilingParameter(parameters caddy_profiling.Parameters)

SetProfilingParameter sets the enabled Profefe profile types as configured by the `profiling` app. If the profefe app is configured with `profile_types`, then the ones specific to profefe take priority and the ones passed from the `profiling` app are ignored.

func (*App) Start

func (p *App) Start() error

Start implements caddy.App

func (*App) Stop

func (p *App) Stop() error

Stop implements caddy.App

type ProfilingApp

type ProfilingApp struct {
	App
}

ProfilingApp is the container of the `profefe` profiler if configured as a guest module of the `profiling` app

func (*ProfilingApp) CaddyModule

func (*ProfilingApp) CaddyModule() caddy.ModuleInfo

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL