zap

package module
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package zap wraps a zapcore.Core and mirrors accepted structured log entries into webpprof while preserving the original core.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Profile

func Profile(core zapcore.Core) zapcore.Core

Profile instruments core with the default profiler.

func ProfileWith

func ProfileWith(profiler *webpprof.Profiler, core zapcore.Core) zapcore.Core

ProfileWith instruments core with an explicit profiler.

Types

type ProfilerZap

type ProfilerZap struct{}

ProfilerZap implements webpprof.Integration for zap cores.

func New

func New() ProfilerZap

New creates a zap core integration.

func (ProfilerZap) Name

func (ProfilerZap) Name() string

Name returns the integration cache namespace.

func (ProfilerZap) Profile

func (ProfilerZap) Profile(scope webpprof.Scope, core zapcore.Core) zapcore.Core

Profile wraps core so accepted entries and structured fields are mirrored into webpprof. Existing wrappers for the same profiler are reused.

Jump to

Keyboard shortcuts

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