Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions skills/sentry-cocoa-sdk/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,8 @@ For each feature: `Read ${SKILL_ROOT}/references/<feature>.md`, follow steps exa
| `sampleRate` | `Float` | `1.0` | Error event sample rate |
| `beforeSend` | `Closure` | `nil` | Hook to mutate/drop error events |
| `onCrashedLastRun` | `Closure` | `nil` | Called on next launch after a crash |
| `strictTraceContinuation` | `Bool` | `false` | Reject incoming traces from other orgs; validates `org_id` in baggage headers (sentry-cocoa ≥9.10.0) |
| `orgId` | `String?` | `nil` | Organization ID for strict trace validation; auto-parsed from DSN host (e.g. `o123.ingest.sentry.io` → `"123"`) if not set explicitly |

### Environment Variables

Expand Down
22 changes: 22 additions & 0 deletions skills/sentry-php-sdk/references/metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,13 +116,35 @@ Metrics are buffered in a ring buffer (capacity: 1000 entries):

**Buffer limit:** When more than 1000 metrics are buffered, the oldest entries are dropped. Flush periodically in high-volume scripts.

## Auto-Flush Threshold

`metric_flush_threshold` automatically flushes the buffer once the metric count reaches the configured value. Use this to avoid buffer overflow in high-volume scripts without manual flush calls:

**PHP / Laravel:**
```php
\Sentry\init([
'dsn' => '___PUBLIC_DSN___',
'metric_flush_threshold' => 500, // flush automatically after 500 metrics
]);
```

**Symfony:**
```yaml
sentry:
options:
metric_flush_threshold: 500
```

When `metric_flush_threshold` is not set, the SDK uses the ring buffer capacity (1000 entries) as the implicit limit.

## Symfony Configuration

```yaml
sentry:
options:
enable_metrics: true # default: true
attach_metric_code_locations: true # attach file/line info
metric_flush_threshold: 500 # auto-flush after N metrics (optional)
before_send_metric: 'App\Sentry\BeforeSendMetricCallback'
```

Expand Down
1 change: 1 addition & 0 deletions skills/sentry-react-native-sdk/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -569,6 +569,7 @@ For each feature: `Read ${SKILL_ROOT}/references/<feature>.md`, follow steps exa
| `enableAutoPerformanceTracing` | `boolean` | `true` | Auto performance instrumentation |
| `enableNdkScopeSync` | `boolean` | `true` | Java→NDK scope sync (Android) |
| `attachThreads` | `boolean` | `false` | Auto-attach all threads on crash (Android) |
| `attachAllThreads` | `boolean` | `false` | Attach full stack traces for all threads to every captured event (iOS only, requires Cocoa SDK ≥9.9.0) |
| `autoInitializeNativeSdk` | `boolean` | `true` | Set `false` for manual native init |
| `onReady` | `function` | — | Callback after native SDKs initialize |

Expand Down
Loading