Skip to content

Commit

Permalink
Bigtable autoscaler: use size variable [(#1156)](GoogleCloudPlatform/…
Browse files Browse the repository at this point in the history
  • Loading branch information
waprin authored and Jon Wayne Parrott committed Oct 9, 2017
1 parent 17fa85e commit 509067d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion samples/metricscaler/metricscaler.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ def scale_bigtable(bigtable_instance, bigtable_cluster, scale_up):

if scale_up:
if current_node_count < max_node_count:
new_node_count = min(current_node_count + 3, max_node_count)
new_node_count = min(
current_node_count + size_change_step, max_node_count)
cluster.serve_nodes = new_node_count
cluster.update()
print('Scaled up from {} to {} nodes.'.format(
Expand Down

0 comments on commit 509067d

Please sign in to comment.