An agent deployment runs the collector on the same host as the application and collects telemetry locally. A gateway deployment aggregates telemetry from other agents and forwards it to the final destination. Use the agent pattern for host-level collection and the gateway pattern when you want centralized ingestion, buffering, or routing across multiple sources.
How agent and gateway deployments differ in an OpenTelemetry Collector pipeline
An agent deployment sits close to the workload and is usually easiest to reason about at host scope: it sees the local process, host metrics, logs, and traces before they move off-box. A gateway deployment shifts collection and forwarding into a shared tier, so it becomes the place where many sources converge, which changes how you handle scaling, buffering, and downstream routing.
That difference is not just architectural, it affects where you place failure boundaries. An agent pattern gives you local collection with smaller blast radius, while a gateway pattern gives you a central choke point that can absorb bursts, normalize traffic, and enforce policy consistently across multiple producers.
If you are deciding between them, start by asking where the telemetry should be enriched, sampled, redacted, or routed. If those choices are highly workload-specific, keep the collector near the application; if they are shared across teams or environments, centralize them in a gateway so the pipeline logic is managed once rather than repeated everywhere.
What each deployment pattern is best at
The agent model is best when you want collection to happen as close as possible to the source. That is useful for host-level observability, short-lived workloads, and cases where you want the collector to see local context before any network hop or aggregation step changes what is available.
The gateway model is best when the problem is not collection itself but consolidation. A gateway can aggregate telemetry from many agents, apply consistent processing rules, and forward data to one or more destinations, which makes it a better fit for organizations that want centralized ingestion, shared retries, queueing, or downstream fan-out.
A practical way to distinguish them is to look at ownership. Agent deployments tend to follow the application or node boundary, while gateways tend to follow the observability platform boundary. That means the first is optimized for proximity, and the second is optimized for coordination.
For teams that use OpenTelemetry alongside a broader telemetry pipeline, NHIMG’s Observability, telemetry and SRE for security teams is a useful companion on pipeline hardening, redaction, and sampling choices that often influence whether an agent or gateway design is the better fit.
Operational trade-offs you should expect
The agent pattern usually reduces network hops and keeps local collection simple, but it also multiplies the number of collectors you operate. That can make rollout consistency, configuration drift, and version management harder if you are running collectors on many hosts.
The gateway pattern reduces that sprawl, but it concentrates responsibility. If the shared tier is overloaded, misconfigured, or unavailable, many sources can be affected at once. In exchange, you gain a single point for buffering, transformation, load balancing, and routing decisions that would otherwise have to be replicated across agents.
Neither pattern is universally “better.” The right choice depends on whether your main constraint is local visibility and autonomy, or central control and uniform pipeline behaviour. In larger environments, teams often use both: agents for capture at the edge, and gateways for central processing and export.
For practitioners building a broader telemetry pipeline, the Security Data Pipeline Guide is directly relevant because it covers collection, normalization, routing, and safe filtering patterns that map cleanly to gateway responsibilities.
Risk and Threat Considerations
Telemetry collectors are part of the trust path for operational data, so placement changes both reliability risk and exposure. An agent that runs beside the workload inherits host risk, while a gateway creates a central target whose failure or compromise can affect many sources at once.
Failure mechanism: An agent can fail quietly if the host is unstable, misconfigured, or short on resources, which leaves you with partial visibility at the exact point you most need local evidence. A gateway can fail more visibly, but its central role means congestion, malformed input, or a bad routing rule can interrupt a much larger share of the pipeline.
Impact: The main operational consequence is lost, delayed, or inconsistent telemetry, which weakens incident investigation, detection tuning, and capacity planning. In regulated or high-assurance environments, a central collector also becomes a higher-value control point, so buffering, access restriction, and configuration governance matter more than in a purely local design.
Standards & Framework Alignment
This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.
NIST CSF 2.0, CIS Controls v8 and NIST SP 800-53 Rev 5 set the governance and control requirements practitioners need to meet.
| Framework | Control / Reference | Relevance |
|---|---|---|
| NIST CSF 2.0 | PR.DS-01 — Data-at-Rest Confidentiality | Telemetry pipelines must protect collected data while it moves and is stored. |
| PR.AA-05 — Authenticator Management | Collector access to upstream and downstream systems depends on managed credentials. | |
| DE.CM-01 — Networks and Systems Are Monitored to Detect Potential Cybersecurity Events | Collectors exist to improve monitoring and detection coverage. | |
| Recommendation — Protect telemetry data in transit and at rest across agent and gateway hops. Control collector credentials and rotate them on a defined lifecycle. Use collectors to maintain continuous monitoring coverage across sources. | ||
| CIS Controls v8 | CIS-8 — Audit Log Management | The pattern directly affects how telemetry is collected, normalized, and forwarded for logging. |
| Recommendation — Centralize log handling where consistent routing and retention are required. | ||
| NIST SP 800-53 Rev 5 | AU-2 — Event Logging | Collector placement determines how events are captured and forwarded for audit visibility. |
| Recommendation — Define which events each collector tier must capture and forward. | ||
Practitioner Guidance
What to verify: Confirm whether the collector must preserve host-local context before any aggregation step. If yes, treat the agent as the primary capture point and reserve the gateway for enrichment, buffering, or routing that benefits from aggregation.
Decision rule: If one team owns a common pipeline policy, a gateway usually simplifies operations; if each workload needs distinct collection logic or low-latency local handling, agent deployment is the safer default. Do not centralize by habit when the real requirement is per-host fidelity.
What practitioners underestimate: The hardest part is often not collection, it is managing the boundary between local collection and shared transport. The more state you move into a gateway, the more you must think about availability, queue behaviour, and the blast radius of a bad configuration.
Practitioner takeaway: Use agents for proximity and workload-specific collection, and use gateways for centralized processing and export, but choose deliberately based on where you want failure to be contained and where you want control to be centralized.
Related resources from NHI Mgmt Group
Deepen Your Knowledge
Free weekly newsletter
Subscribe to the NHI & AI Identity Journal
The latest on NHI and Agentic AI security – articles, research, breaches, news and events every week.
Bonus 33% off our NHI Course when you subscribe.
Reviewed and updated by the NHIMG editorial team on October 31, 2026.
NHI Mgmt Group — the #1 independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org