Skip to content

One Observability Workshop v3.0.0


One Observability Workshop / constructs/managed-prometheus-collector / ManagedPrometheusCollector

Class: ManagedPrometheusCollector

Defined in: constructs/managed-prometheus-collector.ts:62

Creates an AMP Managed Scraper with CloudWatch destination using AwsCustomResource.

The scraper uses DNS-based service discovery via Cloud Map to find targets, and applies relabel_configs to enrich metrics with service context.

Extends

  • Construct

Constructors

Constructor

new ManagedPrometheusCollector(scope, id, properties): ManagedPrometheusCollector

Defined in: constructs/managed-prometheus-collector.ts:72

Parameters

scope

Construct

id

string

properties

ManagedPrometheusCollectorProperties

Returns

ManagedPrometheusCollector

Overrides

Construct.constructor

Properties

scraperId

readonly scraperId: string

Defined in: constructs/managed-prometheus-collector.ts:64

The scraper ID returned by the CreateScraper API


scraperArn

readonly scraperArn: string

Defined in: constructs/managed-prometheus-collector.ts:66

The scraper ARN


scrapeConfigYaml

readonly scrapeConfigYaml: string

Defined in: constructs/managed-prometheus-collector.ts:68

The raw scrape configuration YAML (not base64-encoded)


updateScrapeConfigYaml?

readonly optional updateScrapeConfigYaml: string

Defined in: constructs/managed-prometheus-collector.ts:70

The full scrape config YAML including additional update targets (for hands-on exercise)