-
Notifications
You must be signed in to change notification settings - Fork 4
resource deletion from kb #672
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: testing
Are you sure you want to change the base?
Conversation
|
/windsurf-review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 To request another review, post a new comment with "/windsurf-review".
5ae7f17 to
a58812e
Compare
|
/windsurf-review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Other comments (3)
- src/db_services/agentVersion.service.js (570-587) This function modifies documents but doesn't invalidate related cache entries. Other functions in this file (like `updateAgents` and `deleteAgentVersion`) use `_buildCacheKeys` and `deleteInCache` to maintain cache consistency. Consider adding cache invalidation to prevent stale data.
- src/controllers/rag.controller.js (405-408) While logging cleanup errors is good, consider implementing a more robust error handling strategy for the resource reference cleanup. Orphaned references could cause issues later. You might want to add a background job or retry mechanism for failed cleanups.
- src/db_services/agentVersion.service.js (570-570) This function lacks JSDoc documentation explaining its purpose, parameters, and return value. Consider adding documentation to maintain consistency with the codebase and improve maintainability.
💡 To request another review, post a new comment with "/windsurf-review".
| }); | ||
|
|
||
| // If external deletion was successful | ||
| if (response.status === 200) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The status check response.status === 200 might be too restrictive. Consider using response.status >= 200 && response.status < 300 to handle all successful HTTP responses, as some APIs might return 204 No Content for successful deletions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no issue
a58812e to
95e85dc
Compare
resource is now being deleted