Skip to content

Commit

Permalink
fix: usage of builde when using upgraded client version (#1979)
Browse files Browse the repository at this point in the history
  • Loading branch information
csviri authored Jul 25, 2023
1 parent ed58e6f commit 86b676b
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import io.fabric8.kubernetes.api.model.HasMetadata;
import io.fabric8.kubernetes.api.model.KubernetesResourceList;
import io.fabric8.kubernetes.api.model.NamespaceBuilder;
import io.fabric8.kubernetes.api.model.*;
import io.fabric8.kubernetes.client.KubernetesClient;
import io.fabric8.kubernetes.client.KubernetesClientBuilder;
import io.fabric8.kubernetes.client.dsl.NonNamespaceOperation;
Expand Down Expand Up @@ -164,7 +162,8 @@ protected void before(ExtensionContext context) {
kubernetesClient
.namespaces()
.resource(
new NamespaceBuilder().withNewMetadata().withName(namespace).endMetadata().build())
new NamespaceBuilder().withMetadata(new ObjectMetaBuilder().withName(namespace).build())
.build())
.create();

kubernetesClient
Expand Down

0 comments on commit 86b676b

Please sign in to comment.