Conversation
Allow users to configure how long the MCP server caches database metadata. The parameter is an optional string (e.g. "5m", "1h") passed through to the MCP container config. When omitted, the MCP server defaults to 5 minutes.
Up to standards ✅🟢 Issues
|
| Metric | Results |
|---|---|
| Duplication | 0 |
TIP This summary will be updated as you push new changes. Give us feedback
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughAdded an optional Changes
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@server/internal/orchestrator/swarm/mcp_config_test.go`:
- Around line 248-265: The test TestGenerateMCPConfig_MetadataTTL_Omitted should
assert omission from the raw YAML rather than just the unmarshaled zero value:
after calling GenerateMCPConfig(params) inspect the returned data bytes/string
for the absence of the literal key "metadata_ttl:" (or ensure it is not present
under the first database entry) before or in addition to using parseYAML; update
the test to fail if the raw YAML contains "metadata_ttl:" so you catch
regressions in omitempty behavior for GenerateMCPConfig and the struct field
used for MetadataTTL.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: b397221e-fb7a-42b6-9f2d-f43f610eec2b
📒 Files selected for processing (5)
docs/services/mcp.mdserver/internal/database/mcp_service_config.goserver/internal/database/mcp_service_config_test.goserver/internal/orchestrator/swarm/mcp_config.goserver/internal/orchestrator/swarm/mcp_config_test.go
Summary
metadata_ttlto the MCP service config known keys, typed struct, and parsing pipelineTest plan
make testpasses"metadata_ttl": "10m"— config.yaml should containmetadata_ttl: 10mmetadata_ttl— field should be absent from config.yaml (MCP server defaults to 5m)"metadata_ttl": 300(wrong type) — should return validation errorPLAT-534