> For the complete documentation index, see [llms.txt](https://docs.pharos.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.pharos.ai/platform-overview/pharos-platform-architecture/monitoring.md).

# Monitoring

Learn about complex monitoring scenarios and where these use cases may arise.

Monitoring in Pharos represents a more advanced layer of observability that goes beyond simple error notifications. While alerts notify you about individual issues as they occur, monitoring helps you detect patterns, spikes, and systemic problems that might indicate a larger concern requiring immediate attention.

## Understanding Monitoring vs. Alerting

The distinction between monitoring and alerting is crucial for effective production support. Alerting typically focuses on individual events—a new issue appears, you get notified. Monitoring, however, looks at the bigger picture by analyzing trends and detecting anomalies across your log data in real-time.

Think of monitoring as your early warning system. When something unusual starts happening in your org—perhaps a new deployment has introduced problems, or a Salesforce release has broken existing functionality—monitoring catches these patterns before they become critical incidents.

## Complex Monitoring Scenarios

Monitoring becomes particularly valuable in several scenarios that organizations commonly face:

**Release-Related Issues:** When a new release gets pushed to production, things can break in unexpected ways. Perhaps flows that worked perfectly in UAT start failing at scale, or integration errors spike due to configuration differences. Monitoring detects these issues quickly, allowing you to respond while the problem is still manageable rather than waiting for user complaints to surface.

**Platform Changes:** Salesforce releases happen regularly, and sometimes they introduce breaking changes. Winter '24, for example, caused issues for many organizations. Having monitoring in place means you'll know immediately if a platform update has caused problems in your org, even if users haven't reported anything yet.

**Capacity and Scale Issues:** As your data grows and processes become more complex, you might start hitting governor limits or experiencing performance degradation that manifests as intermittent errors. Monitoring can detect when error frequencies increase, signaling that you're approaching a threshold that needs attention.

**Time-Based Patterns:** Some issues only manifest during specific times—perhaps batch jobs that run overnight start failing, or peak usage hours cause problems that don't appear during testing. Monitoring helps you correlate these temporal patterns with system behavior.

{% hint style="warning" %}
**Incident Response Readiness** Monitoring is most effective when coupled with a clear incident response process. When a monitoring event fires, your team should know exactly who responds, how quickly, and what steps to take.
{% endhint %}

## Integration with the Observability Framework

Monitoring fits into the broader observability framework as part of the awareness and action phases. After logs are captured and issues are created, monitoring provides that crucial real-time analysis layer that helps you move from reactive troubleshooting to proactive incident prevention.

The monitoring system operates independently but works in concert with your notification rules and ticketing automation. When a monitoring event is triggered, it can automatically create notifications in Teams or Slack, generate tickets in Jira or Azure DevOps, and provide the relevant log data for immediate investigation.

## When to Implement Monitoring

While basic observability should be implemented early, monitoring rules are typically established after you have baseline data about your production environment. Once you understand normal error patterns and volumes in your org, you can set meaningful thresholds that distinguish between routine issues and genuine incidents requiring immediate response.

{% hint style="info" %}
**Starting Point** Most organizations begin with monitoring rules focused on high-impact scenarios: critical flows, integration endpoints, or processes that directly affect end users. As you mature your observability practice, you can expand monitoring coverage to include more granular scenarios.
{% endhint %}

***

## In This Section

<table data-view="cards"><thead><tr><th></th><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>📈 Log Monitoring</strong></td><td>How log-based monitoring works and where it fits in the log lifecycle.</td><td><a href="https://docs.pharos.ai/platform-overview/pharos-platform-architecture/monitoring/log-monitoring.md">Log Monitoring</a></td></tr><tr><td><strong>⚡ Governor Limits</strong></td><td>Monitor governor limits with spike and threshold rules, and review snapshot logs.</td><td><a href="https://docs.pharos.ai/platform-overview/pharos-platform-architecture/monitoring/governor-limits.md">Governor Limits</a></td></tr><tr><td><strong>📊 Event Monitoring</strong></td><td>Integrate with the Salesforce Event Monitoring add-on to track events and set thresholds.</td><td><a href="https://docs.pharos.ai/platform-overview/pharos-platform-architecture/monitoring/event-monitoring.md">Event Monitoring</a></td></tr></tbody></table>
