Skip to content

Remove unused config values#6

Merged
ScriptSmith merged 1 commit intomainfrom
config-updates
Mar 4, 2026
Merged

Remove unused config values#6
ScriptSmith merged 1 commit intomainfrom
config-updates

Conversation

@ScriptSmith
Copy link
Owner

No description provided.

@greptile-apps
Copy link
Contributor

greptile-apps bot commented Mar 4, 2026

Greptile Summary

This PR removes unused configuration values and their documentation to simplify the codebase and reduce maintenance burden.

Major changes:

  • Removed unimplemented feature configs: vector_search, web_search, code_execution, moderation, prompt_caching, fallback, load_balancing
  • Removed unused queue backends: RabbitMQ, SQS, Pub/Sub
  • Removed unused cache TTL configs: daily_spend_secs, monthly_spend_secs
  • Removed unused limits configs: token limits, budget exceeded actions
  • Removed request logging config and related infrastructure
  • Converted eviction_batch_size from config to constant with dynamic calculation
  • Removed supports_streaming field from provider configs
  • Updated documentation to reflect removed features

Minor behavioral changes:

  • Memory cache eviction now uses dynamic batch size (10% of max_entries) instead of configured value
  • X-XSS-Protection header default changed from "1; mode=block" to None (CSP provides protection)
  • Tracing service name changed from "ai-gateway" to "hadrian"

Confidence Score: 5/5

  • This PR is safe to merge with minimal risk
  • Clean removal of unused code with thorough cleanup of all references. No remaining dependencies on removed config values were found. The few behavioral changes are minor and intentional improvements.
  • No files require special attention

Important Files Changed

Filename Overview
src/config/features.rs Removed unused feature configs (vector_search, web_search, code_execution, moderation, prompt_caching, fallback, load_balancing) and queue backends (RabbitMq, Sqs, PubSub)
src/config/cache.rs Removed eviction_batch_size, daily_spend_secs, and monthly_spend_secs from cache config
src/config/limits.rs Removed token limits config and budget exceeded action/overage fields
src/config/observability.rs Removed request_logging config and changed default tracing service name from 'ai-gateway' to 'hadrian'
src/config/ui.rs Removed unused UI config options (gzip, brotli, history_enabled, max_conversations, code_execution, web_search, allowed_roles)
src/config/server.rs Removed api_base_path and http2 config fields, changed X-XSS-Protection default from '1; mode=block' to None
src/cache/memory.rs Converted eviction_batch_size from config to constant, updated eviction logic to use dynamic calculation (10% of max_entries)
src/app.rs Removed fallback to vector_search.embedding config when initializing embedding service
src/init.rs Removed fallback to vector_search.embedding in worker embedding service initialization
src/services/document_processor.rs Removed RabbitMQ, SQS, and Pub/Sub queue backend implementations
src/config/providers.rs Removed supports_streaming field from OpenAiProviderConfig, added comments about deny_unknown_fields constraints

Last reviewed commit: 148ee0e

@ScriptSmith ScriptSmith merged commit 45f7c7e into main Mar 4, 2026
19 checks passed
@ScriptSmith ScriptSmith deleted the config-updates branch March 4, 2026 13:02
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