---
title: "GCP logs - Alloy + Pub/Sub | Grafana Labs"
description: "Collect GCP logs using Grafana Alloy with Pub/Sub."
---

> For a curated documentation index, see [llms.txt](/llms.txt). For the complete documentation index, see [llms-full.txt](/llms-full.txt).

## How it works

**Complexity:** Moderate | **Infrastructure:** Pub/Sub + Alloy | **Latency:** Streaming

[GCP logs collection pipeline](gcp-logs-pipeline.svg "GCP logs collection pipeline")

## Trade-offs

| Pros                           | Cons                 |
|--------------------------------|----------------------|
| Reliable Pub/Sub delivery      | Pub/Sub costs        |
| Filter at sink (reduce volume) | Alloy infrastructure |
| Workload identity              | Setup complexity     |
| Full processing pipeline       |                      |

## Documentation

View the full documentation. *Learning path coming soon!*

[GCP logs](https://grafana.com/docs/grafana-cloud/monitor-infrastructure/monitor-cloud-provider/gcp/config-gcp-logs/)
