-
Notifications
You must be signed in to change notification settings - Fork 76
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
Added gzip as default request header #277
Conversation
swagger-api/swagger-codegen#10085 So, this is a problem with the code gen. Normally for issues such as this, I would apply a patch post generation. Thoughts @Chaffelson ? |
Note, that given url lib support for gzip, this is the right fix for the generated code |
That would be the best option (aside from fixing this upstream). |
The client is primarily generated using mustache templates, so if this was added to the template then all future clients would pick it up.
|
This is an easy fix but could get lost in future updates of the templates. Any preference? |
They are my templates, not upstream, so it won't be lost
…On Fri, 11 Jun 2021, 15:57 rsaggino, ***@***.***> wrote:
The client is primarily generated using mustache templates, so if this was
added to the template then all future clients would pick it up.
https://github.com/Chaffelson/nipyapi/blob/292aa1e8bc1c4d080d7b6acdf0cedfb4e77a1f03/resources/client_gen/swagger_templates/api_client.mustache#L58
This is an easy fix but could get lost in future updates of the templates.
Any preference?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#277 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ACZAZOBJY3I7VLFKYZZUTFLTSIP4RANCNFSM46A4TE7A>
.
|
@Chaffelson maybe you can list out explicitly what we would want to do? |
ie:
|
Applied the change also to the mustache template. |
@Chaffelson can we proceed with this? |
I'm +1 on this, pending whatever testing @Chaffelson does for these kinds of changes |
fwiw |
Yeah this is the way to do it, I was going to cut a release this week but am dealing with unexpected covid isolation so it'll have to be next week sorry. |
Managed to get some testing on this done today and it's looking good, I'll be rolling up the new client for 1.13 in the next week and including this in it |
* Added gzip as default request header * Gzip Fix on the mustache template
Fixes #273 by adding gzip headers to the api client.
Tested on a small dev cluster, nipyapi 0.16.2 and NiFi 1.11.
It seems like there were additional improvements on NiFi/nipyapi that reduced the impact of this patch, this is still necessary on larger clusters and while making complex automations.
Before:
After: