-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #31503 from Sgitario/31476
Fix randomly failures when deploying to OpenShift/K8s on JVM/Native
- Loading branch information
Showing
11 changed files
with
84 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
...src/main/resources/META-INF/services/io.fabric8.kubernetes.client.http.HttpClient$Factory
This file was deleted.
Oops, something went wrong.
18 changes: 11 additions & 7 deletions
18
...-client/spi/src/main/java/io/quarkus/kubernetes/client/spi/KubernetesClientBuildItem.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,30 @@ | ||
package io.quarkus.kubernetes.client.spi; | ||
|
||
import java.util.function.Supplier; | ||
|
||
import io.fabric8.kubernetes.client.Config; | ||
import io.fabric8.kubernetes.client.KubernetesClient; | ||
import io.fabric8.kubernetes.client.KubernetesClientBuilder; | ||
import io.fabric8.kubernetes.client.http.HttpClient; | ||
import io.quarkus.builder.item.SimpleBuildItem; | ||
|
||
public final class KubernetesClientBuildItem extends SimpleBuildItem { | ||
|
||
private final Config config; | ||
private final HttpClient.Factory httpClientFactory; | ||
|
||
public KubernetesClientBuildItem(Config config) { | ||
public KubernetesClientBuildItem(Config config, HttpClient.Factory httpClientFactory) { | ||
this.config = config; | ||
} | ||
|
||
public Supplier<KubernetesClient> getClient() { | ||
return () -> new KubernetesClientBuilder().withConfig(config).build(); | ||
this.httpClientFactory = httpClientFactory; | ||
} | ||
|
||
public Config getConfig() { | ||
return config; | ||
} | ||
|
||
public HttpClient.Factory getHttpClientFactory() { | ||
return httpClientFactory; | ||
} | ||
|
||
public KubernetesClient buildClient() { | ||
return new KubernetesClientBuilder().withConfig(config).withHttpClientFactory(httpClientFactory).build(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.