Skip to content

feat(config): add shaper environment variables#111

Open
TheArchitectit wants to merge 2 commits intomcowger:mainfrom
TheArchitectit:feat/config-shaper-env
Open

feat(config): add shaper environment variables#111
TheArchitectit wants to merge 2 commits intomcowger:mainfrom
TheArchitectit:feat/config-shaper-env

Conversation

@TheArchitectit
Copy link
Contributor

Part 1: Config (278 lines)

Add environment variables for RequestShaper feature.

Changes

  • PLEXUS_REQUEST_SHAPER_ENABLED
  • PLEXUS_REQUEST_SHAPER_QUEUE_DEPTH
  • PLEXUS_REQUEST_SHAPER_QUEUE_TIMEOUT_MS
  • PLEXUS_REQUEST_SHAPER_DEFAULT_RPM

Size: 278 lines ✅

Independent Security Research added 2 commits March 8, 2026 23:16
- SHAPER_QUEUE_TIMEOUT_MS, SHAPER_CLEANUP_INTERVAL_MS

- SHAPER_DEFAULT_RPM with validation

- Comprehensive test coverage
@TheArchitectit
Copy link
Contributor Author

Code Overview

This PR adds configuration infrastructure for the RequestShaper feature.

Key Changes:

  1. packages/backend/src/config.ts - Added environment variable parsing
  2. packages/backend/.env.example - Documented new variables

Architecture:

The configuration integrates with the existing PlexusConfig system, allowing runtime configuration of rate limiting parameters.

Testing:

  • Config validation on startup
  • Default values provided for backward compatibility

Review Notes:

  • Check that default values are reasonable
  • Verify backward compatibility with existing configs

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.

1 participant