Skip to content

Conversation

@Anxhela21
Copy link
Contributor

@Anxhela21 Anxhela21 commented Sep 16, 2025

Description

Fix the URLs in the REST API sequence diagram

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

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

  • Documentation
    • Updated REST API docs to reflect new endpoint paths:
      • GET /v1/conversation/{id} → GET /v1/conversations/{conversation_id}
      • DELETE /v1/conversation/{id} → DELETE /v1/conversations/{conversation_id}
      • GET /v1/ready → GET /readiness
      • GET /v1/live → GET /liveness
    • Response formats remain unchanged (ConversationResponse, ConversationDeleteResponse, ReadinessResponse, LivenessResponse).
    • Other endpoints are unaffected.

Signed-off-by: Anxhela Coba <[email protected]>
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Sep 16, 2025

Walkthrough

The REST API documentation in docs/rest_api.uml updates endpoint names: conversation endpoints gain pluralized paths and explicit path parameter names; readiness/liveness endpoints move to root paths. Response types and other endpoints remain unchanged.

Changes

Cohort / File(s) Summary of Changes
Docs: REST API UML
docs/rest_api.uml
Renamed endpoints: GET /v1/conversation/{id}GET /v1/conversations/{conversation_id}; DELETE /v1/conversation/{id}DELETE /v1/conversations/{conversation_id}; GET /v1/readyGET /readiness; GET /v1/liveGET /liveness. Response types unchanged.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

Poem

I twitch my whiskers, flip a page,
Paths pluralized—what a stage!
From ready to readiness we hop,
Liveness too—clean pit stop.
In UML fields I thump with cheer,
Neat little trails are crystal-clear. 🐇✨

Pre-merge checks and finishing touches

✅ 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 "[LCORE-462] Fix URLs in REST API sequence diagram" is concise, a single sentence, and accurately summarizes the primary change—correcting REST API endpoint URLs in the sequence diagram—which matches the edits to docs/rest_api.uml and includes the ticket ID for traceability without extraneous detail.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.
✨ Finishing touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment

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.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 146e8eb and 027af3f.

⛔ Files ignored due to path filters (2)
  • docs/rest_api.png is excluded by !**/*.png
  • docs/rest_api.svg is excluded by !**/*.svg
📒 Files selected for processing (1)
  • docs/rest_api.uml (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
  • GitHub Check: e2e_tests
  • GitHub Check: build-pr
🔇 Additional comments (3)
docs/rest_api.uml (3)

21-22: Approved — /v1/conversations and {conversation_id} are used consistently across router, OpenAPI, docs, and tests; diagram is correct.


27-28: Unversioned /readiness is fine — but align docs/tests.
Code and OpenAPI use GET /readiness (src/app/endpoints/health.py:80; docs/openapi.json:618; tests/integration/test_openapi_json.py:72) while README.md documents GET /v1/readiness (README.md:708). Update README to /readiness or make the route/tests/docs versioned consistently; ensure k8s readinessProbe/ingress reference the chosen path.


24-25: DELETE handler correctly wired to /v1/conversations/{conversation_id}.
@router.delete("/conversations/{conversation_id}") exists in src/app/endpoints/conversations.py (lines 341–345) and conversations.router is mounted with prefix "/v1" in src/app/routers.py (line 33). No DELETE route found for a singular /v1/conversation.

Comment on lines +30 to 31
Client->>"API Server": GET /liveness
"API Server"-->>Client: LivenessResponse
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue

🧩 Analysis chain

Unversioned /liveness likewise—verify consistency across manifests and monitors.
Confirm livenessProbe, dashboards, and alerts reference /liveness (not /v1/live).

Probe alignment check:


🏁 Script executed:

#!/bin/bash
set -euo pipefail
echo "Look for probe paths and any legacy /v1/live:"
rg -nP -C3 '(livenessProbe|/liveness|/v1/live)' || true

Length of output: 13730


Unify liveness path: /liveness vs /v1/liveness.

README.md documents GET /v1/liveness (README.md:732) while code and repo references use GET /liveness (src/app/endpoints/health.py:124, docker-compose.yaml:39, tests/integration/test_openapi_json.py:73, docs/openapi.json). Choose the canonical path and update README or align code/healthchecks/tests/dashboards/alerts to match; verify external monitors/alerts.

🤖 Prompt for AI Agents
In docs/rest_api.uml around lines 30-31 the liveness endpoint is shown as GET
/liveness but README.md documents GET /v1/liveness and other artifacts reference
/liveness; pick a canonical path (either /liveness or /v1/liveness), update this
UML to match the chosen canonical path, and then make a coordinated change
across the repo: update README.md (line ~732) or update
src/app/endpoints/health.py, docker-compose.yaml,
tests/integration/test_openapi_json.py, docs/openapi.json (and any other
references) so they all use the same path; run tests and update external
monitor/alert configurations to point to the canonical endpoint.

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 adbf0f6 into lightspeed-core:main Sep 17, 2025
18 of 19 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