Skip to content
Unverified Commit 265d414c authored by Russell Cohen's avatar Russell Cohen Committed by GitHub
Browse files

Refactor Operation Code generation (#335)

* Refactor Operation Code generation

This all started when I wanted to the public API in my protocol tests but couldn't because it depended on the input. So began
a large sequence of refactoring that overall lead to major improvements.

1. `Operation` no longer carries an input around. This was originally done to support paginators, but we'll handle that differently later.
2. `Builders` are now uniform—no more special builders for operation shapes.
3. Idempotency token insertion is now handled during operation construction instead of during builder construction. This removes
a ton of special casing from various parts of the code base.
4. Protocol tests now use the public traits. This will enable us to generate protocol tests for streaming inputs without any
special casing.

This wasn't done originally because the main API was the low-level API and I didn't want `.build().make_operation()`. But now
that this is only an escape hatch, the double call isn't nearly as big of a deal.

* Delete unused variable

* Update other tests that used the LL API
parent bc342293
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment