-
Notifications
You must be signed in to change notification settings - Fork 81
Add missing endpoints in general-request-handling #706
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: master
Are you sure you want to change the base?
Add missing endpoints in general-request-handling #706
Conversation
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.
Pull Request Overview
This PR adds missing general request handling endpoints to the ArangoDB Go driver v2, specifically implementing admin version and status endpoints. The implementation includes proper handling of both database-scoped and global admin requests.
- Added
HandleAdminVersion
method that provides an alias forGET /_admin/version
with optional details - Updated
GetServerStatus
to support both global (/_admin/status
) and database-scoped (/_db/{name}/_admin/status
) requests - Added comprehensive test coverage for both new and updated functionality
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
v2/arangodb/client_server_info.go | Adds AdminVersionInfo struct and HandleAdminVersion interface method |
v2/arangodb/client_server_info_impl.go | Implements HandleAdminVersion method with proper error handling |
v2/arangodb/client_admin_impl.go | Updates GetServerStatus to handle empty dbName for global status requests |
v2/tests/admin_test.go | Adds comprehensive tests for both HandleAdminVersion and updated GetServerStatus behavior |
v2/CHANGELOG.md | Documents the addition of general-request-handling endpoints |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
d458233
to
fe08d20
Compare
This PR includes the following general-request-handling- related endpoints:
Note
Introduces
_admin/version
via new HandleAdminVersion and updates GetServerStatus to use global_admin/status
whendbName
is empty, with expanded tests and minor test robustness improvements.HandleAdminVersion(opts)
to fetch version via_admin/version
(alias of_api/version
).GetServerStatus
to support both_db/{db}/_admin/status
and global_admin/status
whendbName
is empty.Test_HandleAdminVersion
(with/without options).Test_GetServerStatus
to cover no DB, with DB, and invalid DB cases.v2/CHANGELOG.md
to note general-request-handling endpoints.Written by Cursor Bugbot for commit d7c7672. This will update automatically on new commits. Configure here.