Skip to content

Commit

Permalink
add scheme check
Browse files Browse the repository at this point in the history
  • Loading branch information
shreemaan-abhishek committed Sep 17, 2023
1 parent 08f6479 commit cb2e367
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion apisix/plugins/traffic-split.lua
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,9 @@ local function set_upstream(upstream_info, ctx)
end
core.log.info("upstream_key: ", upstream_key)
upstream.set(ctx, upstream_key, ctx.conf_version, up_conf)
upstream.set_scheme(ctx, up_conf)
if upstream_info.scheme == "https" then
upstream.set_scheme(ctx, up_conf)
end
return
end

Expand Down

0 comments on commit cb2e367

Please sign in to comment.