Skip to content

Conversation

@sunitaprajapati89
Copy link
Contributor

add waiting plugin interface.

  • any plugin implement this interface will pause event processing when it's added to analytics
  • any plugin implement this interface can pause and resume event processing as needed

@abueide
Copy link
Contributor

abueide commented Feb 12, 2026

@claude
@copilot
can you implement the review comments in this PR?

Copy link

Copilot AI commented Feb 12, 2026

@abueide I've opened a new pull request, #1123, to work on those changes. Once the pull request is ready, I'll request review from you.

Implements WaitingPlugin functionality that allows plugins to pause event
processing until async operations complete (e.g., permissions, SDK initialization).

Key features:
- WaitingPlugin base class with pause/resume methods
- Automatic event buffering when paused
- Support for multiple waiting plugins
- 30-second timeout to prevent permanent blocking
- Works with both root-level and destination plugins

Implementation details:
- Add running state to storage (separate from enabled)
- Events queued when running=false
- Process pending events when all waiting plugins resume
- QueueFlushingPlugin respects running state

Includes comprehensive tests and documentation with real-world examples
(IDFA permissions, native SDK initialization, remote config loading).

Co-Authored-By: Claude <noreply@anthropic.com>
- Fix strict-boolean-expressions error in QueueFlushingPlugin.ts
- Replace 'any' type with proper ClientWithInternals type in tests
- All linting errors resolved
@abueide abueide self-assigned this Feb 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants