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 PreReq option sr API #867

Merged
merged 2 commits into from
Jan 20, 2025
Merged

Conversation

mihaitodor
Copy link
Contributor

No description provided.

@mihaitodor mihaitodor force-pushed the add-prereq-option-sr-api branch from ea4728c to 3108f47 Compare December 7, 2024 21:54
type PreReqFunc func(req *http.Request) error

// PreReq sets a hook func to call before every request is sent.
func PreReq(preReq PreReqFunc) ClientOpt {
Copy link
Owner

Choose a reason for hiding this comment

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

I'd remove the defined type for the function and just have this be an inline function, wdyt?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good call! I'm not sure now why I left that in there, but it's not really useful so I removed it. Thanks!

@mihaitodor mihaitodor force-pushed the add-prereq-option-sr-api branch from 3108f47 to 1b122a5 Compare January 8, 2025 13:12
@mihaitodor mihaitodor requested a review from twmb January 8, 2025 13:15
@twmb twmb removed the waiting label Jan 15, 2025
@twmb twmb mentioned this pull request Jan 15, 2025
10 tasks
@twmb twmb merged commit 082c308 into twmb:master Jan 20, 2025
4 checks passed
mihaitodor added a commit to redpanda-data/connect that referenced this pull request Jan 22, 2025
This is a follow-up to twmb/franz-go#867.

Since `sr.URLs()` from franz-go doesn't validate URLs during
client initialisation, I decided to leave our `url.Parse()` in
there because this way we can catch malformed URLs on startup,
before any HTTP requests are attempted.

Signed-off-by: Mihai Todor <[email protected]>
mihaitodor added a commit to redpanda-data/connect that referenced this pull request Jan 22, 2025
This is a follow-up to twmb/franz-go#867.

Since `sr.URLs()` from franz-go doesn't validate URLs during
client initialisation, I decided to leave our `url.Parse()` in
there because this way we can catch malformed URLs on startup,
before any HTTP requests are attempted.

Signed-off-by: Mihai Todor <[email protected]>
mihaitodor added a commit to redpanda-data/connect that referenced this pull request Jan 22, 2025
This is a follow-up to twmb/franz-go#867.

Since `sr.URLs()` from franz-go doesn't validate URLs during
client initialisation, I decided to leave our `url.Parse()` in
there because this way we can catch malformed URLs on startup,
before any HTTP requests are attempted.

Also update the changelog. We forgot to do it in #3134

Signed-off-by: Mihai Todor <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants