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

Fix invalid proxy setting when the port ends with a whitespace #44708

Merged
merged 1 commit into from
Nov 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@
import io.quarkus.runtime.annotations.ConfigPhase;
import io.quarkus.runtime.annotations.ConfigRoot;
import io.quarkus.runtime.configuration.MemorySize;
import io.quarkus.runtime.configuration.TrimmedStringConverter;
import io.smallrye.config.ConfigMapping;
import io.smallrye.config.ConfigValue;
import io.smallrye.config.SmallRyeConfig;
import io.smallrye.config.WithConverter;
import io.smallrye.config.WithDefault;
import io.smallrye.config.WithDefaults;
import io.smallrye.config.WithKeys;
Expand Down Expand Up @@ -58,7 +60,7 @@ public interface RestClientsConfig {
* <p>
* Can be overwritten by client-specific settings.
*/
Optional<String> proxyAddress();
Optional<@WithConverter(TrimmedStringConverter.class) String> proxyAddress();

/**
* Proxy username, equivalent to the http.proxy or https.proxy JVM settings.
Expand Down Expand Up @@ -449,7 +451,7 @@ default Optional<String> uriReload() {
* <p>
* Use `none` to disable proxy
*/
Optional<String> proxyAddress();
Optional<@WithConverter(TrimmedStringConverter.class) String> proxyAddress();

/**
* Proxy username.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ quarkus.rest-client.client-prefix.providers=io.quarkus.rest.client.reactive.Hell
quarkus.rest-client.client-prefix.connect-timeout=5000
quarkus.rest-client.client-prefix.read-timeout=6000
quarkus.rest-client.client-prefix.follow-redirects=true
quarkus.rest-client.client-prefix.proxy-address=localhost:8080
# intentionally add whitespace at the end to ensure we strip it
quarkus.rest-client.client-prefix.proxy-address=localhost:8080
quarkus.rest-client.client-prefix.query-param-style=COMMA_SEPARATED
quarkus.rest-client.client-prefix.connection-ttl=30000
quarkus.rest-client.client-prefix.connection-pool-size=10
Expand Down
Loading