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

Add Passing Client Headers section to rest-client.adoc #14349

Merged
merged 1 commit into from
Apr 1, 2021

Conversation

pehala
Copy link
Contributor

@pehala pehala commented Jan 17, 2021

This section can be useful for passing Authorization headers in rest-client requests. The text is based on javadoc here https://github.com/eclipse/microprofile-rest-client/blob/master/api/src/main/java/org/eclipse/microprofile/rest/client/ext/DefaultClientHeadersFactoryImpl.java.

@michalszynkiewicz
Copy link
Member

@pehala thank you for your PR :)
I'm wondering what's the best way of structuring this info. The guide already has a section that talks a bit about headers: https://quarkus.io/guides/rest-client#custom-headers-support

It mentions the @RegisterClientHeaders annotation. I think the info from this PR and what's in this section should be merged. It wouldn't hurt to add some info about @ClientHeaderParam btw...

@pehala
Copy link
Contributor Author

pehala commented Jan 21, 2021

@michalszynkiewicz The main reason why I even have this MR was that I needed to pass Authorization and it was really hard to find some info about how to do it. The thing that was missing the most was the property value which is needed if you don't specify the factory, e.g. you use the default one, which in my opinion will suffice for many cases.

If that is ok with you, I can ditch this new section and incorporate only that thing into the existing one.

@michalszynkiewicz
Copy link
Member

👍🏻

Base automatically changed from master to main March 12, 2021 15:55
@gsmet
Copy link
Member

gsmet commented Apr 1, 2021

Could we finalize this PR? Thanks!

@gastaldi
Copy link
Contributor

gastaldi commented Apr 1, 2021

+1 to move that section near (or inside) https://quarkus.io/guides/rest-client#custom-headers-support, for consistency

@pehala
Copy link
Contributor Author

pehala commented Apr 1, 2021

Sorry for the delay, I moved the section inside https://quarkus.io/guides/rest-client#custom-headers-support.

Is it now ok?

@gastaldi
Copy link
Contributor

gastaldi commented Apr 1, 2021

Could you squash the commits in this PR to a single commit too?

@pehala
Copy link
Contributor Author

pehala commented Apr 1, 2021

Squashed and rebased

Copy link
Contributor

@gastaldi gastaldi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@gastaldi gastaldi merged commit 8896cad into quarkusio:main Apr 1, 2021
@quarkus-bot quarkus-bot bot added this to the 1.14 - main milestone Apr 1, 2021
@gsmet gsmet modified the milestones: 1.14 - main, 1.13.1.Final Apr 3, 2021
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.

4 participants