Skip to content

Commit 804649e

Browse files
Fix load balancing results
1 parent 0a604a9 commit 804649e

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

samples/load-balancing/create.ipynb

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -141,32 +141,32 @@
141141
"\n",
142142
"# 1) Prioritized API calls\n",
143143
"utils.print_message('1/5: Starting API calls for prioritized distribution (50/50)')\n",
144-
"output = reqs.multiGet('/lb-prioritized', runs = 15, msg = 'Calling prioritized APIs')\n",
145-
"tests.verify(len(output), 15)\n",
144+
"api_results_prioritized = reqs.multiGet('/lb-prioritized', runs = 15, msg = 'Calling prioritized APIs')\n",
145+
"tests.verify(len(api_results_prioritized), 15)\n",
146146
"\n",
147147
"# # 2) Weighted API calls\n",
148148
"zzzs()\n",
149149
"utils.print_message('2/5: Starting API calls for weighted distribution (50/50)', blank_above = True)\n",
150-
"output = reqs.multiGet('/lb-weighted-equal', runs = 15, msg = 'Calling weighted (equal) APIs')\n",
151-
"tests.verify(len(output), 15)\n",
150+
"api_results_weighted_equal = reqs.multiGet('/lb-weighted-equal', runs = 15, msg = 'Calling weighted (equal) APIs')\n",
151+
"tests.verify(len(api_results_weighted_equal), 15)\n",
152152
"\n",
153153
"# # 3) Weighted API calls\n",
154154
"zzzs()\n",
155155
"utils.print_message('3/5: Starting API calls for weighted distribution (80/20)', blank_above = True)\n",
156-
"output = reqs.multiGet('/lb-weighted-unequal', runs = 15, msg = 'Calling weighted (unequal) APIs')\n",
157-
"tests.verify(len(output), 15)\n",
156+
"api_results_weighted_unequal = reqs.multiGet('/lb-weighted-unequal', runs = 15, msg = 'Calling weighted (unequal) APIs')\n",
157+
"tests.verify(len(api_results_weighted_unequal), 15)\n",
158158
"\n",
159159
"# 4) Prioritized & weighted API calls\n",
160160
"zzzs()\n",
161161
"utils.print_message('4/5: Starting API calls for prioritized & weighted distribution', blank_above = True)\n",
162-
"output = reqs.multiGet('/lb-prioritized-weighted', runs = 20, msg = 'Calling prioritized & weighted APIs')\n",
163-
"tests.verify(len(output), 20)\n",
162+
"api_results_prioritized_and_weighted = reqs.multiGet('/lb-prioritized-weighted', runs = 20, msg = 'Calling prioritized & weighted APIs')\n",
163+
"tests.verify(len(api_results_prioritized_and_weighted), 20)\n",
164164
"\n",
165165
"# 5) Prioritized & weighted API calls (500ms sleep)\n",
166166
"zzzs()\n",
167167
"utils.print_message('5/5: Starting API calls for prioritized & weighted distribution (500ms sleep)', blank_above = True)\n",
168-
"output = reqs.multiGet('/lb-prioritized-weighted', runs = 20, msg = 'Calling prioritized & weighted APIs', sleepMs = 500)\n",
169-
"tests.verify(len(output), 20)\n",
168+
"api_results_prioritized_and_weighted_sleep = reqs.multiGet('/lb-prioritized-weighted', runs = 20, msg = 'Calling prioritized & weighted APIs', sleepMs = 500)\n",
169+
"tests.verify(len(api_results_prioritized_and_weighted_sleep), 20)\n",
170170
"\n",
171171
"tests.print_summary()\n",
172172
"\n",

0 commit comments

Comments
 (0)