Skip to content
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

POC for generating API endpoints using code generation, take 2 #567

Closed
wants to merge 8 commits into from

Conversation

kpfleming
Copy link
Contributor

This PR is a second proof-of-concept for generating API endpoints using the Jennifer code-generation module. It generates endpoints for Brotli compression and NGWAF as examples. For NGWAF, it includes configuration-during-enablement of the 'workspace_id', and configuration of 'workspace_id' and 'traffic_ramp' after enablement.

Makefile Show resolved Hide resolved
fastly/client.go Show resolved Hide resolved
…kages.

To support future API endpoints being located outside of the 'fastly'
package, a number of types/functions/variables used in the
implementations of those endpoints (and their unit tests) need to be
exposed from the 'fastly' package.

In addition, the 'fastly_test.go' file must be given a different name,
as files named '..._test.go' cannot expose any of their declarations
outside of their package.

Finally, add support for Next-Gen WAF workspace IDs along side
Delivery and Compute service IDs, as future API endpoints will require
them.
This PR is a second proof-of-concept for generating API endpoints
using the Jennifer code-generation module. It generates endpoints for
Brotli compression and NGWAF as examples. For NGWAF, it includes
configuration-during-enablement of the 'workspace_id', and
configuration of 'workspace_id' and 'traffic_ramp' after enablement.
Initial support for generating unit tests.
@kpfleming
Copy link
Contributor Author

Closing this as I've opted for a radically different approach which does not use code generation.

@kpfleming kpfleming closed this Dec 7, 2024
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