diff --git a/src/multiplayer-servers/monitoring/introduction.md b/src/multiplayer-servers/monitoring/introduction.md index 4359f980..ff88852a 100644 --- a/src/multiplayer-servers/monitoring/introduction.md +++ b/src/multiplayer-servers/monitoring/introduction.md @@ -32,8 +32,19 @@ For more information on managing permissions, see [Editing Permissions](/multipl ## Metrics -There are metrics for every feature of the product. -There are a lot of predefined dashboards under "Dashboards". +GameFabric comes with a Grafana instance (accessible via the "Monitoring" menu item in the sidebar of your GameFabric instance) and a dozen preinstalled Grafana dashboards. These dashboards help you understand the performance, capacity, and reliability of your game server fleets, nodes, and sites without requiring a custom observability setup for your game servers. + +Some examples of data available in Grafana: + +- Game server scaling activity, including scale-up and scale-down trends +- Game server CPU and memory utilization, including percentiles, averages, regional rollups, and top consumers for anomaly detection +- Node-level host metrics for both bare metal and cloud environments +- Node connectivity checks to common external providers and endpoints +- Cluster utilization and the gap between requested resources and actual usage +- Allocator activity and request patterns +- Kubernetes events that affect your workloads + +For practical guidance on sizing CPU and memory requests and limits using these metrics, see [Resource management](/multiplayer-servers/multiplayer-services/resource-management). ## Logs diff --git a/src/multiplayer-servers/monitoring/obs-tap.md b/src/multiplayer-servers/monitoring/obs-tap.md new file mode 100644 index 00000000..dad4d39c --- /dev/null +++ b/src/multiplayer-servers/monitoring/obs-tap.md @@ -0,0 +1,81 @@ +# Observability tap + +The observability tap gives you direct, read-only access to the Prometheus-compatible metrics API and the Loki-compatible logs API for your GameFabric installation. Use it to display data in your own Grafana instance or in any other observability tool that supports these APIs. + +## Requesting access + +Access to the observability tap is not enabled by default. To request it, contact your **Customer Success Manager** or raise a request through the **GameFabric Help Center**. Once approved, you receive the credentials needed to authenticate against the endpoints. + +## Endpoints + +All observability tap endpoints are available under your installation's base URL: + +``` +https://.gamefabric.dev/observability/ +``` + +Replace `` with your installation name. + +The two sub-paths expose the respective APIs: + +| API | Base URL | +| --- | -------- | +| Prometheus-compatible metrics (VictoriaMetrics) | `https://.gamefabric.dev/observability/metrics/` | +| Loki-compatible logs | `https://.gamefabric.dev/observability/logs/` | + +## Querying metrics + +The metrics endpoint is compatible with the [VictoriaMetrics MetricsQL](https://docs.victoriametrics.com/metricsql/) query language, which is a superset of PromQL. Any tool that supports PromQL also works against this endpoint. + +The following Prometheus HTTP API paths are available under the metrics endpoint: + +- `/observability/metrics/api/v1/query` — instant query +- `/observability/metrics/api/v1/query_range` — range query +- `/observability/metrics/api/v1/series` — series metadata +- `/observability/metrics/api/v1/labels` — label names +- `/observability/metrics/api/v1/label//values` — label values +- `/observability/metrics/api/v1/metadata` — metric metadata +- `/observability/metrics/api/v1/status/buildinfo` — build information + +Refer to the [VictoriaMetrics MetricsQL reference](https://docs.victoriametrics.com/metricsql/) for the full query language documentation. + +## Querying logs + +The logs endpoint is compatible with the [Loki LogQL](https://grafana.com/docs/loki/latest/query/) query language. + +The following Loki HTTP API paths are available under the logs endpoint: + +- `/observability/logs/loki/api/v1/query` — instant query +- `/observability/logs/loki/api/v1/query_range` — range query +- `/observability/logs/loki/api/v1/labels` — label names +- `/observability/logs/loki/api/v1/label//values` — label values +- `/observability/logs/loki/api/v1/series` — series metadata +- `/observability/logs/loki/api/v1/index/stats` — index statistics +- `/observability/logs/loki/api/v1/tail` — live tail +- `/observability/logs/loki/api/v1/status/buildinfo` — build information + +Refer to the [Loki LogQL reference](https://grafana.com/docs/loki/latest/query/) for the full query language documentation. + +## Adding as a Grafana data source + +You can add both endpoints as data sources in your own Grafana instance. + +### Metrics data source + +1. In Grafana, go to **Connections > Data sources** and select **Add new data source**. +2. Choose **Prometheus** as the data source type. +3. Set the **URL** to `https://.gamefabric.dev/observability/metrics/`. +4. Under **Authentication**, set the **Authentication method** to **No authentication** +5. Under **HTTP headers**, click **Add header** and set **Header** to `Authorization` and **Value** to `Bearer `. Replace `` with the token you receive from your Customer Success Manager. Keep the `Bearer` prefix. +1. Select **Save & test** to verify the connection. + +### Logs data source + +1. In Grafana, go to **Connections > Data sources** and select **Add new data source**. +2. Choose **Loki** as the data source type. +3. Set the **URL** to `https://.gamefabric.dev/observability/logs/`. +4. Under **Authentication**, set the **Authentication method** to **No authentication** +5. Under **HTTP headers**, click **Add header** and set **Header** to `Authorization` and **Value** to `Bearer `. Replace `` with the token you receive from your Customer Success Manager. Keep the `Bearer` prefix. +6. Select **Save & test** to verify the connection. + +Once the data sources are configured, you can build dashboards and alerts in your own Grafana instance using the same metrics and logs that power the built-in GameFabric monitoring dashboards. diff --git a/src/multiplayer-servers/monitoring/sidebar.json b/src/multiplayer-servers/monitoring/sidebar.json index 58a0e43c..28b09e2a 100644 --- a/src/multiplayer-servers/monitoring/sidebar.json +++ b/src/multiplayer-servers/monitoring/sidebar.json @@ -22,6 +22,10 @@ { "text": "Debugging", "link": "/monitoring/debugging" + }, + { + "text": "Observability Tap", + "link": "/monitoring/obs-tap" } ] -} +} \ No newline at end of file