MCPcopy Create free account

hub / github.com/cloudflare/cloudflare-prometheus-exporter / functions

Functions391 in github.com/cloudflare/cloudflare-prometheus-exporter

↓ 1 callersMethodgetAdaptiveMetrics
* Origin error rates (4xx/5xx), response duration, and error rate gauge. * * @param zoneIds Zone IDs to query. * @param zones Zone metadata for
src/cloudflare/client.ts:2017
↓ 1 callersMethodgetCacheMissMetrics
* Cache miss origin response duration (rt_miss equivalent). * * @param zoneIds Zone IDs to query. * @param zones Zone metadata for label mapping
src/cloudflare/client.ts:3094
↓ 1 callersMethodgetColoErrorMetrics
* Error visits, bytes, requests per colo (4xx+). * * @param zoneIds Zone IDs to query. * @param zones Zone metadata for label mapping. * @para
src/cloudflare/client.ts:2287
↓ 1 callersMethodgetColoMetrics
* Visits, response bytes, requests per colo. * * @param zoneIds Zone IDs to query. * @param zones Zone metadata for label mapping. * @param ti
src/cloudflare/client.ts:2211
↓ 1 callersFunctiongetConfigKey
( env: Env, key: K, )
src/lib/runtime-config.ts:314
↓ 1 callersMethodgetEdgeCountryMetrics
* Requests by edge status, country, host, and edge error rate gauge. * * @param zoneIds Zone IDs to query. * @param zones Zone metadata for labe
src/cloudflare/client.ts:2123
↓ 1 callersMethodgetFirewallRules
* Fetches firewall rules for a zone via DataLoader batching. * Returns map of rule ID to rule name/description. * * @param zoneId Cloudflare zon
src/cloudflare/client.ts:308
↓ 1 callersMethodgetFirewallRulesInternal
* Fetches firewall rules internally (without DataLoader). * Fetches both traditional firewall rules and managed rulesets. * * @param zoneId Clou
src/cloudflare/client.ts:319
↓ 1 callersMethodgetHealthCheckMetrics
* Events per origin with timing metrics (RTT, TTFB, TCP, TLS). * * @param zoneIds Zone IDs to query. * @param zones Zone metadata for label mapp
src/cloudflare/client.ts:2415
↓ 1 callersMethodgetHostnameHttpMetrics
* Hostname-level HTTP metrics (requests, status, cache, latency) for allowlisted hosts. * Uses a fixed 1-minute window anchored by hostMetricsDelayS
src/cloudflare/client.ts:2563
↓ 1 callersMethodgetHttpMetricsHandler
* Extracts ~27 metrics from HTTPMetricsQuery. * Including requests, bandwidth, threats, pageviews, uniques, firewall events, and bot detection. *
src/cloudflare/client.ts:1577
↓ 1 callersMethodgetImagesMetrics
* Fetches Cloudflare Images storage metrics (current count and allowed limit). * * @param accountId Cloudflare account ID. * @param normalizedAc
src/cloudflare/client.ts:1455
↓ 1 callersMethodgetLbWeightMetrics
* Load balancer origin weight metric from REST API. * * @param zones Zone metadata. * @returns LB weight metrics.
src/cloudflare/client.ts:3228
↓ 1 callersMethodgetLbWeightMetricsForZone
* Fetches LB origin weight metrics for a single zone. * Used by zone-scoped MetricExporter DOs. * * @param zone Zone metadata. * @returns Prom
src/cloudflare/client.ts:3367
↓ 1 callersMethodgetLoadBalancerMetrics
* Pool health, requests, RTT, steering policy, and origins selected. * * @param zoneIds Zone IDs to query. * @param zones Zone metadata for labe
src/cloudflare/client.ts:2837
↓ 1 callersMethodgetLogpushAccountMetricsInternal
* Fetches logpush account metrics (failed jobs). * * @param accountId Cloudflare account ID. * @param normalizedAccount Normalized account name
src/cloudflare/client.ts:671
↓ 1 callersMethodgetLogpushZoneMetrics
* Failed jobs per zone. * * @param zoneIds Zone IDs to query. * @param zones Zone metadata for label mapping. * @param timeRange Time range fo
src/cloudflare/client.ts:2984
↓ 1 callersMethodgetMagicFirewallSamplesMetrics
* Magic Firewall per-rule sampled traffic metrics. * * Uses magicFirewallSamplesAdaptiveGroups to show bits/packets * allowed and blocked by spe
src/cloudflare/client.ts:1103
↓ 1 callersMethodgetMagicTransitMetricsInternal
* Magic Transit tunnel health metrics (active, healthy, failures, colo count). * * @param accountId Cloudflare account ID. * @param normalizedAc
src/cloudflare/client.ts:719
↓ 1 callersMethodgetMagicTransitSLOMetricsInternal
* Magic Transit tunnel health check SLO metrics (status, effective SLO, target SLO). * * Uses the magicTransitTunnelHealthCheckSLOsAdaptiveGroups
src/cloudflare/client.ts:911
↓ 1 callersMethodgetMagicTransitTunnelTrafficMetrics
* Magic Transit tunnel bandwidth metrics (bits/packets per tunnel). * * Uses magicTransitTunnelTrafficAdaptiveGroups for per-tunnel throughput *
src/cloudflare/client.ts:1041
↓ 1 callersMethodgetNetworkAnalyticsMetrics
* Network analytics metrics across 6 NAv2 datasets: * Magic Transit, Magic Firewall, DDoS (dosd), IDPS, * Advanced TCP Protection, Advanced DNS Pr
src/cloudflare/client.ts:1164
↓ 1 callersMethodgetOriginStatusMetrics
* Origin responses by status, country, and host. * * @param zoneIds Zone IDs to query. * @param zones Zone metadata for label mapping. * @para
src/cloudflare/client.ts:3037
↓ 1 callersMethodgetRequestMethodMetrics
* Requests by HTTP method. * * @param zoneIds Zone IDs to query. * @param zones Zone metadata for label mapping. * @param timeRange Time range
src/cloudflare/client.ts:2364
↓ 1 callersMethodgetSSLCertificateMetrics
* Certificate expiry timestamps (batched). * * @param zones Zone metadata. * @returns SSL certificate metrics.
src/cloudflare/client.ts:3270
↓ 1 callersMethodgetSSLCertificateMetricsForZone
* Fetches SSL certificate metrics for a single zone. * Used by zone-scoped MetricExporter DOs. * * @param zone Zone metadata. * @returns Promi
src/cloudflare/client.ts:3319
↓ 1 callersMethodgetState
* Gets coordinator state. * * @returns Current coordinator state. * @throws {Error} When state not initialized.
src/durable-objects/MetricCoordinator.ts:83
↓ 1 callersMethodgetStreamLiveInputsMetrics
* Fetches Cloudflare Stream live input (input stream) metrics. * Returns segment counts and ingestion quality gauges, grouped by event code. * *
src/cloudflare/client.ts:1376
↓ 1 callersMethodgetStreamVideoPlaybackMetrics
* Fetches Cloudflare Stream video playback metrics. * Returns playback count and time viewed, grouped by country and media type (VOD/live). * *
src/cloudflare/client.ts:1319
↓ 1 callersMethodgetWorkerTotalsMetrics
* Fetches worker totals metrics (requests, errors, CPU time, duration). * * @param accountId Cloudflare account ID. * @param normalizedAccount N
src/cloudflare/client.ts:562
↓ 1 callersMethodgetZones
* Fetches all zones for a given account. * * @param accountId Cloudflare account ID. * @returns Promise of zones for the account.
src/cloudflare/client.ts:271
↓ 1 callersFunctiongroupStatusCode
* Groups HTTP status code into category string. * * @param code HTTP status code. * @returns Status category string (1xx, 2xx, 3xx, 4xx, 5xx).
src/cloudflare/client.ts:83
↓ 1 callersFunctionhealthResponse
(health: HealthResponse)
src/lib/health.ts:179
↓ 1 callersMethodinitialize
* Initializes coordinator state and starts alarm cycle. Idempotent safe to call multiple times. * * @param accountId Cloudflare account ID. * @p
src/durable-objects/AccountMetricCoordinator.ts:135
↓ 1 callersMethodinitializeZone
* Initialize zone-scoped exporter with zone metadata. * Called by AccountMetricCoordinator when ensuring zone exporters exist. * Triggers immediat
src/durable-objects/MetricExporter.ts:265
↓ 1 callersFunctionisAccountLevelQuery
(query: string)
src/cloudflare/queries.ts:94
↓ 1 callersFunctionisChunkFormat
(value: unknown)
src/lib/chunked-storage.ts:43
↓ 1 callersFunctionisFreeTierZone
(zone: Zone)
src/lib/filters.ts:72
↓ 1 callersFunctionisPaidTierGraphQLQuery
( query: string, )
src/cloudflare/queries.ts:158
↓ 1 callersFunctionisZoneLevelQuery
(query: string)
src/cloudflare/queries.ts:104
↓ 1 callersFunctionlabelSignature
* Creates stable signature from labels for deduplication. * * @param labels Label key-value pairs. * @returns Stable string signature for compariso
src/lib/prometheus.ts:125
↓ 1 callersMethodlimit
* Rate limit a request based on the provided options. * @see https://developers.cloudflare.com/workers/runtime-apis/bindings/rate-limit/ * @
worker-configuration.d.ts:10036
↓ 1 callersFunctionmakeLogger
(tag: string, baseContext: StructuredData = {})
src/lib/logger.ts:278
↓ 1 callersFunctionmergeMetricDefinitions
( ...arrays: MetricDefinition[][] )
src/lib/metrics.ts:52
↓ 1 callersFunctionmetricKey
( name: string, labels: Record<string, string>, )
src/lib/time.ts:32
↓ 1 callersFunctionnormalizeAccountName
* Normalizes account name for use in Prometheus labels. * * @param name Account name. * @returns Normalized account name (lowercase, spaces replace
src/cloudflare/client.ts:120
↓ 1 callersFunctionparseBasicAuthConfig
* Parses basic auth configuration from environment variables. * Logs warnings if configuration is incomplete. * * @param user BASIC_AUTH_USER envir
src/lib/config.ts:123
↓ 1 callersFunctionparseConfig
(env: Env)
src/lib/config.ts:68
↓ 1 callersFunctionparseManifest
(value: unknown)
src/lib/chunked-storage.ts:52
↓ 1 callersFunctionpartitionZonesByTier
(zones: Zone[])
src/lib/filters.ts:82
↓ 1 callersMethodrefreshAccountsIfStale
* Refreshes accounts from Cloudflare API if cache expired. * * @param config Resolved runtime configuration. * @param logger Logger instance.
src/durable-objects/MetricCoordinator.ts:97
↓ 1 callersMethodrefreshZonesAndPushContext
* Refreshes zone list if stale then pushes context to all exporters. * * @param config Resolved runtime configuration. * @param logger Logger in
src/durable-objects/AccountMetricCoordinator.ts:195
↓ 1 callersFunctionresetAllConfig
(env: Env)
src/lib/runtime-config.ts:392
↓ 1 callersFunctionresetConfigKey
( env: Env, key: ConfigKey, )
src/lib/runtime-config.ts:376
↓ 1 callersMethodretryFailedStateLoad
Retry constructor load failures from inside the protected alarm path.
src/durable-objects/MetricExporter.ts:114
↓ 1 callersFunctionserializeToPrometheus
( metrics: readonly MetricDefinition[], options?: SerializeOptions, )
src/lib/prometheus.ts:22
↓ 1 callersFunctionsetConfigKey
( env: Env, key: ConfigKey, value: unknown, )
src/lib/runtime-config.ts:351
↓ 1 callersMethodsetIdentifier
* Initializes coordinator state if not already set. * * @param id Unique identifier for this coordinator instance.
src/durable-objects/MetricCoordinator.ts:69
↓ 1 callersFunctionshortenTag
* Shorten tag for display: truncate zone/account IDs to 8 chars. * * @param tag Tag string to shorten. * @returns Shortened tag string.
src/lib/logger.ts:178
↓ 1 callersMethodtransform
* Apply transform next, returning a transform handle. * You can then apply more transformations, draw, or retrieve the output. * @param tran
worker-configuration.d.ts:9768
↓ 1 callersMethodupdateZoneContext
* Update zone context for account-scoped exporters. * Called by AccountMetricCoordinator after zone list refresh. * Triggers immediate fetch on fi
src/durable-objects/MetricExporter.ts:218
↓ 1 callersFunctionutcTimestamp
* Get current UTC timestamp in ISO format. * * @returns ISO 8601 timestamp string.
src/lib/logger.ts:144
↓ 1 callersMethodwithContext
* Create logger with merged context data. * * @param ctx Context data merged into all log entries. * @returns New logger instance.
src/lib/logger.ts:94
↓ 1 callersFunctionzoneScopeFromMetricKey
(key: string)
src/lib/counters.ts:21
Method"assert"
(condition?: boolean, ...data: any[])
worker-configuration.d.ts:130
FunctionLandingPage
({ config })
src/components/LandingPage.tsx:8
FunctionLandingPageScript
({ metricsPath, disableConfigApi, })
src/components/LandingPageScript.tsx:6
Method[Symbol.asyncIterator]
(options?: ReadableStreamValuesOptions)
worker-configuration.d.ts:2195
Methodabort
(reason?: string)
worker-configuration.d.ts:549
Methodabort
()
worker-configuration.d.ts:1964
Methodaccept
()
worker-configuration.d.ts:3062
MethodacceptWebSocket
(ws: WebSocket, tags?: string[])
worker-configuration.d.ts:541
Methodack
()
worker-configuration.d.ts:1916
MethodackAll
()
worker-configuration.d.ts:1922
MethodackAll
()
worker-configuration.d.ts:1928
Methodaddress
()
worker-configuration.d.ts:9914
Methodafter
(content: string | ReadableStream | Response, options?: ContentOptions)
worker-configuration.d.ts:1515
Methodafter
(content: string | ReadableStream | Response, options?: ContentOptions)
worker-configuration.d.ts:1527
Methodafter
(content: string, options?: ContentOptions)
worker-configuration.d.ts:1534
Methodafter
(content: string | ReadableStream | Response, options?: ContentOptions)
worker-configuration.d.ts:1543
Methodalarm
()
src/durable-objects/AccountMetricCoordinator.ts:158
Methodalarm
* Durable Object alarm handler. * Triggers metric refresh and reschedules next alarm with jitter.
src/durable-objects/MetricExporter.ts:303
Methodappend
(content: string | ReadableStream | Response, options?: ContentOptions)
worker-configuration.d.ts:1517
Methodappend
(content: string, options?: ContentOptions)
worker-configuration.d.ts:1548
MethodarrayBuffer
()
worker-configuration.d.ts:1989
Methodatob
(data: string)
worker-configuration.d.ts:321
FunctionbatchScheduleFn
(cb: () => void)
src/cloudflare/client.ts:183
Methodbefore
(content: string | ReadableStream | Response, options?: ContentOptions)
worker-configuration.d.ts:1514
Methodbefore
(content: string | ReadableStream | Response, options?: ContentOptions)
worker-configuration.d.ts:1526
Methodbefore
(content: string, options?: ContentOptions)
worker-configuration.d.ts:1533
Methodbefore
(content: string | ReadableStream | Response, options?: ContentOptions)
worker-configuration.d.ts:1542
Methodblob
()
worker-configuration.d.ts:1993
FunctionblockConcurrencyWhile
(callback: () => Promise<void>)
src/durable-objects/MetricExporter.test.ts:43
Methodbody
()
worker-configuration.d.ts:1987
MethodbodyUsed
()
worker-configuration.d.ts:1988
Methodbtoa
(data: string)
worker-configuration.d.ts:320
Methodbytes
()
worker-configuration.d.ts:1990
Methodcancel
* The **`cancel()`** method of the ReadableStream interface returns a Promise that resolves when the stream is canceled. * * [MDN Reference]
worker-configuration.d.ts:2160
Methodclear
* The **`console.clear()`** static method clears the console if possible. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/con
worker-configuration.d.ts:136
MethodclearInterval
(timeoutId: number | null)
worker-configuration.d.ts:327
← previousnext →101–200 of 391, ranked by callers