monitoring

package
v1.7.0 Latest Latest
Warning

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

Go to latest
Published: May 25, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package monitoring implements the GCP Cloud Monitoring REST API surface for alert policies. cloud.google.com/go/monitoring uses gRPC by default; this handler covers the REST equivalent for HTTP-level testing.

Supported operations (parity with AWS CloudWatch):

POST   /v3/projects/{p}/alertPolicies          — create policy
GET    /v3/projects/{p}/alertPolicies/{name}   — get
GET    /v3/projects/{p}/alertPolicies          — list
DELETE /v3/projects/{p}/alertPolicies/{name}   — delete

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler struct {
	// contains filtered or unexported fields
}

Handler serves GCP Cloud Monitoring alert-policy REST requests.

func New

New returns a Cloud Monitoring handler.

func (*Handler) Matches

func (*Handler) Matches(r *http.Request) bool

Matches returns true for /v3/projects/.../alertPolicies URLs.

func (*Handler) ServeHTTP

func (h *Handler) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP routes the request based on URL path shape.

Jump to

Keyboard shortcuts

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