-
Notifications
You must be signed in to change notification settings - Fork 360
refactor(remote_config): move appsec-specific logic to appsec folder #7122
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: watson/refactor-rc
Are you sure you want to change the base?
Conversation
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
Overall package sizeSelf size: 4.36 MB Dependency sizes| name | version | self size | total size | |------|---------|-----------|------------| | import-in-the-middle | 2.0.0 | 68.46 kB | 797.03 kB | | dc-polyfill | 0.1.10 | 26.73 kB | 26.73 kB |🤖 This report was automatically generated by heaviest-objects-in-the-universe |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## watson/refactor-rc #7122 +/- ##
======================================================
+ Coverage 84.81% 84.82% +0.01%
======================================================
Files 522 523 +1
Lines 22207 22213 +6
======================================================
+ Hits 18834 18842 +8
+ Misses 3373 3371 -2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This comment has been minimized.
This comment has been minimized.
BenchmarksBenchmark execution time: 2025-12-19 19:11:44 Comparing candidate commit 69d7527 in PR branch Found 0 performance improvements and 0 performance regressions! Performance is the same for 291 metrics, 29 unstable metrics. |
42b32af to
8023afd
Compare
eec9001 to
3efdc4c
Compare
8023afd to
05e2209
Compare
3efdc4c to
b49c683
Compare
05e2209 to
6b3bd2e
Compare
Resolves TODO by decoupling the remote_config module from appsec, improving separation of concerns and module independence. Problem: The remote_config module contained appsec-specific code including WAF update capabilities, ASM_FEATURES handlers, and user tracking configuration. This created tight coupling between core remote config and appsec, making the remote_config module difficult to understand and maintain in isolation. Solution: Extract all appsec-specific remote config logic into a new appsec/remote_config.js module. The core remote_config module now focuses solely on APM tracing capabilities, while appsec manages its own remote config integration. The proxy.js orchestrator wires them together at initialization. Benefits: - Clear ownership: appsec folder contains all appsec functionality - Reduced coupling: remote_config has no knowledge of appsec - Better testability: each module tested independently - Improved maintainability: easier to understand each module's scope - Startup optimization: lazy loading preserved for serverless The appsec module now stores its own RC instance internally and manages its lifecycle independently, eliminating cross-module dependencies.
b49c683 to
c18a9fe
Compare
6b3bd2e to
69d7527
Compare

What Does This Do?
Resolves the TODO in
remote_config/index.jsby moving all appsec-specific remote configuration logic into the appsec folder, improving separation of concerns and module independence.Motivation
The
remote_configmodule contained appsec-specific code including:This created tight coupling between core remote config and appsec, making both modules harder to understand and maintain. The
remote_configmodule should focus on core APM tracing capabilities and be agnostic to appsec.Benefits
remote_confighas zero knowledge of appsec