Skip to content

Conversation

@SgtPooki
Copy link
Collaborator

@SgtPooki SgtPooki commented Feb 11, 2026

Summary

Remove the ENABLE_CDN_TESTING environment variable and always disable CDN testing
in deal creation.

Problem

The ENABLE_CDN_TESTING flag controlled whether CDN was randomly enabled (50%
chance) during deal creation. However, dealbot should be testing storage providers
directly — not services that wrap SPs. Having a toggle for CDN testing adds
unnecessary configuration complexity and inconsistent test behavior.

Solution

  • Removed ENABLE_CDN_TESTING from the Joi validation schema, config interface
    (IBlockchainConfig), and config loader
  • Hardcoded enableCDN = false in DealService.getTestingDealOptions()
  • Removed the env var from .env.example, kustomize configmap, and all
    documentation
  • Updated test mocks and assertions to reflect the change

Notes

  • The enableCDN parameter still flows through DealPreprocessingConfig and the
    CDN addon strategy — only the config toggle was removed
  • Existing deals in the database are unaffected; this only changes future deal
    creation behavior
  • No migration needed

Fixes #169

CDN testing should always be on — dealbot tests SPs directly, not
services that wrap SPs. This removes the env var, config plumbing,
and documentation for ENABLE_CDN_TESTING, and hardcodes enableCDN
to true.

Closes #169
Copilot AI review requested due to automatic review settings February 11, 2026 20:01
@FilOzzy FilOzzy added this to FOC Feb 11, 2026
@github-project-automation github-project-automation bot moved this to 📌 Triage in FOC Feb 11, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request removes the ENABLE_CDN_TESTING environment variable configuration and hardcodes CDN testing to always be enabled during deal creation. The changes remove the configuration toggle from validation schemas, config interfaces, environment files, and documentation, while setting enableCDN = true in the deal service. However, the CDN addon strategy and related infrastructure remain in place.

Changes:

  • Removed ENABLE_CDN_TESTING from Joi validation schema, IBlockchainConfig interface, and config loader
  • Hardcoded enableCDN = true in DealService.getTestingDealOptions()
  • Removed environment variable from .env.example, kustomize configmap, and all documentation
  • Updated test mocks to remove enableCDNTesting property and changed test assertions to expect enableCDN: true

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
apps/backend/src/config/app.config.ts Removed ENABLE_CDN_TESTING from Joi schema, IBlockchainConfig interface, and loadConfig() function
apps/backend/src/deal/deal.service.ts Hardcoded enableCDN = true in getTestingDealOptions() method
apps/backend/src/deal/deal.service.spec.ts Removed enableCDNTesting from mock configs and changed assertion from expect.any(Boolean) to true
apps/backend/src/wallet-sdk/wallet-sdk.service.spec.ts Removed enableCDNTesting: false from base test configuration
apps/backend/.env.example Removed ENABLE_CDN_TESTING=true environment variable
apps/backend/README.md Removed ENABLE_CDN_TESTING row from blockchain configuration table
docs/environment-variables.md Removed entire ENABLE_CDN_TESTING documentation section
kustomize/overlays/local/backend-configmap-local.yaml Removed ENABLE_CDN_TESTING: "false" and associated comment

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@SgtPooki SgtPooki self-assigned this Feb 11, 2026
@SgtPooki SgtPooki moved this from 📌 Triage to 🔎 Awaiting review in FOC Feb 11, 2026
@SgtPooki SgtPooki changed the title fix: always enable CDN testing fix: always disable CDN testing Feb 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: 🔎 Awaiting review

Development

Successfully merging this pull request may close these issues.

remove ENABLE_CDN_TESTING and places that use it

1 participant