-
Notifications
You must be signed in to change notification settings - Fork 42
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
Support x-databricks-path-style overrides at the operation level #562
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.
Where is it needed? Is it for Terminate/PermanentDelete? Can’t see this reflecting in Go SDK
It's needed for the permissions refactor being done by @Rchakmak. His permissions APIs are all RESTful, but they will be part of services that are marked as RPC style. |
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #562 +/- ##
==========================================
- Coverage 18.73% 18.73% -0.01%
==========================================
Files 85 85
Lines 9388 9405 +17
==========================================
+ Hits 1759 1762 +3
- Misses 7477 7489 +12
- Partials 152 154 +2
☔ View full report in Codecov by Sentry. |
Changes
In order to support multiple styles of request under a single service, we introduce support for overriding x-databricks-path-style at the Operation level. This will allow RPC- and REST-style operations to exist under a single service. To determine the path style for a method, we check for a method-level override, falling back to the service-level setting. If neither is set, the path style is assumed to be "rest".
Tests
Tested by regenerating the Python SDK using a spec I edited by hand to include this extension at the operation level. The generated code was as I expected (using the operation ID to derive name in the Clusters service, which is normally an RPC style service).
make test
passingmake fmt
applied