You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2021/11/04 02:01:20 UTC

[GitHub] [apisix] spacewander commented on a change in pull request #5414: fix(traffix-split): multiple rules with multiple weighted_upstreams nder each rule cause upstream_key duplicate

spacewander commented on a change in pull request #5414:
URL: https://github.com/apache/apisix/pull/5414#discussion_r742466415



##########
File path: apisix/plugins/traffic-split.lua
##########
@@ -203,6 +207,14 @@ local function new_rr_obj(weighted_upstreams)
         elseif upstream_obj.upstream then
             -- Add a virtual id field to uniquely identify the upstream key.
             upstream_obj.upstream.vid = i

Review comment:
       It seems the vid is no longer required?

##########
File path: apisix/plugins/traffic-split.lua
##########
@@ -203,6 +207,14 @@ local function new_rr_obj(weighted_upstreams)
         elseif upstream_obj.upstream then
             -- Add a virtual id field to uniquely identify the upstream key.
             upstream_obj.upstream.vid = i
+            if upstream_obj.upstream.nodes then

Review comment:
       Look like the nodes check here can be skipped?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org