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

Added "User-Agent" header to requests made to the Lambda Runtime API #21458

Merged
merged 1 commit into from
Sep 12, 2022
Merged

Added "User-Agent" header to requests made to the Lambda Runtime API #21458

merged 1 commit into from
Sep 12, 2022

Conversation

msailes
Copy link
Contributor

@msailes msailes commented Nov 15, 2021

The value of the header will be in the format "quarkus/%s-%s" where the first position will be a description of the Java version and the second being the version of Quarkus.

There were no existing tests for the class I changed, I'd be happy to write some tests if given guidance.

Thanks,

@quarkus-bot
Copy link

quarkus-bot bot commented Nov 15, 2021

Thanks for your pull request!

The title of your pull request does not follow our editorial rules. Could you have a look?

  • title should not end up with dot

This message is automatically generated by a bot.

@msailes msailes changed the title Added "User-Agent" header to requests made to the Lambda Runtime API. Added "User-Agent" header to requests made to the Lambda Runtime API Nov 15, 2021
@maxandersen
Copy link
Member

this feels like something we should have config for that the various http clients will be able to use?

@msailes
Copy link
Contributor Author

msailes commented Nov 15, 2021

Hi @maxandersen,

Maybe, I couldn't see any http client in this module, so I followed the style which was existing.

@geoand
Copy link
Contributor

geoand commented Nov 29, 2021

this feels like something we should have config for that the various http clients will be able to use?

I definitely agree

@gsmet
Copy link
Member

gsmet commented Jan 12, 2022

I think having a configurable user agent for lambda would be a good first step. If we generalize it at some point we could use the more general one if not set.

@msailes I'm not sure we have some config root for lambda yet though. My guess would be to add something to LambdaConfig.
If you're still interested in finalizing this, I suppose you could ask for @matejvasek 's help if you have questions.

@matejvasek
Copy link
Contributor

@gsmet @msailes I didn't work much on aws lambda directly, I only did some work wrt Funqy binding, AFAIK we don't configure user-agent there.

cc @patriot1burke

@patriot1burke
Copy link
Contributor

Just curious, why the user agent? Does the lambda event server want that information?

@msailes
Copy link
Contributor Author

msailes commented Sep 5, 2022

Yes, it helps us understand which frameworks are used.

@patriot1burke
Copy link
Contributor

rebase, squash and i'll spin off CI. Sorry this fell through the cracks.

@msailes
Copy link
Contributor Author

msailes commented Sep 6, 2022

No problem

@msailes
Copy link
Contributor Author

msailes commented Sep 9, 2022

Updated

@geoand
Copy link
Contributor

geoand commented Sep 12, 2022

Can you please rebase the PR onto main (instead of merging main into this PR)?

Thanks

@msailes
Copy link
Contributor Author

msailes commented Sep 12, 2022

Done

The value of the header will be in the format "quarkus/%s-%s" where the first position will be a description of the Java version and the second being the version of Quarkus.
@quarkus-bot

This comment has been minimized.

@cescoffier cescoffier merged commit fc5d630 into quarkusio:main Sep 12, 2022
@quarkus-bot quarkus-bot bot added this to the 2.13 - main milestone Sep 12, 2022
@msailes msailes deleted the add-user-agent branch September 13, 2022 08:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants