Skip to content

Fix Solr port and update rag_guide#1280

Merged
tisnik merged 1 commit intolightspeed-core:mainfrom
Anxhela21:anx/solr
Mar 5, 2026
Merged

Fix Solr port and update rag_guide#1280
tisnik merged 1 commit intolightspeed-core:mainfrom
Anxhela21:anx/solr

Conversation

@Anxhela21
Copy link
Contributor

@Anxhela21 Anxhela21 commented Mar 5, 2026

Fix solr port and update rag_guide.md to include instructions on how to properly configure run.yaml with vector stores (solr and byok) using llama-stack-configuration.py

Description

Type of change

  • Refactor
  • New feature
  • Bug fix
  • CVE fix
  • Optimization
  • Documentation Update
  • Configuration Update
  • Bump-up service version
  • Bump-up dependent library
  • Bump-up library or tool used for development (does not change the final image)
  • CI configuration change
  • Konflux configuration change
  • Unit tests improvement
  • Integration tests improvement
  • End to end tests improvement
  • Benchmarks improvement

Tools used to create PR

Identify any AI code assistants used in this PR (for transparency and review context)

  • Assisted-by: (e.g., Claude, CodeRabbit, Ollama, etc., N/A if not used)
  • Generated by: (e.g., tool name and version; N/A if not used)

Related Tickets & Documents

  • Related Issue #
  • Closes #

Checklist before requesting a review

  • I have performed a self-review of my code.
  • PR has passed all pre-merge test jobs.
  • If it is a core feature, I have added thorough tests.

Testing

  • Please provide detailed steps to perform tests related to this code change.
  • How were the fix/results from this change verified? Please provide relevant screenshots or results.

Summary by CodeRabbit

Release Notes

  • Documentation

    • Added comprehensive guide for automatic configuration enrichment with CLI options and example commands.
    • Reorganized configuration workflow documentation with dedicated sections for automatic and manual configuration approaches.
  • Configuration

    • Updated default Solr endpoint URL to align with standard port configuration.

…n.yaml enrichment.

Signed-off-by: Anxhela Coba <acoba@redhat.com>
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 5, 2026

Walkthrough

This change adds documentation for an automatic configuration enrichment workflow in the RAG guide and updates the default Solr URL in the configuration script from port 8081 to port 8983.

Changes

Cohort / File(s) Summary
Documentation Update
docs/rag_guide.md
Replaced TOC entry with two new sections: "Automatic Configuration Enrichment" and "Manual Configuration". Added documentation for a configuration enrichment script workflow with example commands and CLI options.
Configuration Default
src/llama_stack_configuration.py
Updated default Solr URL from http://localhost:8081/solr to http://localhost:8983/solr in the vector_io enrichment logic.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Fix Solr port and update rag_guide' directly corresponds to the two main changes: fixing the Solr port default in llama_stack_configuration.py and updating the rag_guide.md documentation with new configuration workflow instructions.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Tip

Try Coding Plans. Let us write the prompt for your AI agent so you can ship faster (with fewer bugs).
Share your feedback on Discord.


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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
src/llama_stack_configuration.py (1)

408-408: Centralize the Solr default URL constant.

Line 408 hardcodes the Solr endpoint. Move the default URL to src/constants.py (for example, SOLR_DEFAULT_URL) and reference it here so future endpoint changes stay single-source.

Proposed refactor
diff --git a/src/constants.py b/src/constants.py
@@
 SOLR_DEFAULT_EMBEDDING_DIMENSION = 384
+SOLR_DEFAULT_URL = "http://localhost:8983/solr"
diff --git a/src/llama_stack_configuration.py b/src/llama_stack_configuration.py
@@
-        solr_url_env = "${env.SOLR_URL:=http://localhost:8983/solr}"
+        solr_url_env = f"${{env.SOLR_URL:={constants.SOLR_DEFAULT_URL}}}"
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/llama_stack_configuration.py` at line 408, Extract the hardcoded Solr
default URL from the solr_url_env assignment in llama_stack_configuration.py and
centralize it by creating a SOLR_DEFAULT_URL constant in src/constants.py; then
replace the literal "http://localhost:8983/solr" with a reference to that
constant (e.g., import SOLR_DEFAULT_URL into llama_stack_configuration.py and
use "${env.SOLR_URL:=" + SOLR_DEFAULT_URL + "}" or equivalent string
interpolation) so the default endpoint is maintained in one place; update
imports to reference SOLR_DEFAULT_URL and run tests to ensure no import cycles.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@src/llama_stack_configuration.py`:
- Line 408: Extract the hardcoded Solr default URL from the solr_url_env
assignment in llama_stack_configuration.py and centralize it by creating a
SOLR_DEFAULT_URL constant in src/constants.py; then replace the literal
"http://localhost:8983/solr" with a reference to that constant (e.g., import
SOLR_DEFAULT_URL into llama_stack_configuration.py and use "${env.SOLR_URL:=" +
SOLR_DEFAULT_URL + "}" or equivalent string interpolation) so the default
endpoint is maintained in one place; update imports to reference
SOLR_DEFAULT_URL and run tests to ensure no import cycles.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 9159fa39-7149-4d05-af25-654d8c9f925e

📥 Commits

Reviewing files that changed from the base of the PR and between 410bb5f and f585b19.

📒 Files selected for processing (2)
  • docs/rag_guide.md
  • src/llama_stack_configuration.py

Copy link
Contributor

@tisnik tisnik left a comment

Choose a reason for hiding this comment

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

LGTM

@tisnik tisnik merged commit 745a2c8 into lightspeed-core:main Mar 5, 2026
20 of 22 checks passed
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.

2 participants