Skip to content

Commit 209377b

Browse files
committed
add adebug flag to Kuber context
Add a debug flag to the Kuber context that switches on lower level HTTP debug messages through OpenAPI.jl. Useful to debug transport layer when needed.
1 parent 4a702bb commit 209377b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/helpers.jl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -235,10 +235,11 @@ function set_server(
235235
reset_api_versions::Bool=false;
236236
max_tries=retries(ctx, false),
237237
verbose::Bool=false,
238+
debug::Bool=false,
238239
kwargs...
239240
)
240241
rtfn = (return_types,response_code,response_data)->kuber_type(ctx, return_types, response_code, response_data)
241-
ctx.client = OpenAPI.Clients.Client(uri; get_return_type=rtfn, kwargs...)
242+
ctx.client = OpenAPI.Clients.Client(uri; get_return_type=rtfn, verbose=debug, kwargs...)
242243
ctx.client.headers["Connection"] = "close"
243244
reset_api_versions && set_api_versions!(
244245
ctx;
@@ -453,4 +454,4 @@ end
453454

454455
# Add validations for the k8s spec specific int-or-string format
455456
OpenAPI.val_format(val::Union{AbstractString,Integer}, ::Val{Symbol("int-or-string")}) = true
456-
OpenAPI.val_format(val, ::Val{Symbol("int-or-string")}) = false
457+
OpenAPI.val_format(val, ::Val{Symbol("int-or-string")}) = false

0 commit comments

Comments
 (0)