Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagebash
titleEnduranceTest (xLarge)
collapsetrue
$ kubectl autoscale deployment php-apache --cpu-percent=50 --min=1 --max=20
# We started with 2 replicas, then increased to 4
$ kubectl scale deploy infinite-calls --replicas=2 
$ kubectl get hpa --watch
NAME         REFERENCE               TARGETS    MINPODS   MAXPODS   REPLICAS   AGE
php-apache   Deployment/php-apache   0%/50%     1         20        1          89m
php-apache   Deployment/php-apache   209%/50%   1         20        1          89m
php-apache   Deployment/php-apache   209%/50%   1         20        4          89m
php-apache   Deployment/php-apache   209%/50%   1         20        5          89m
php-apache   Deployment/php-apache   110%/50%   1         20        5          90m
php-apache   Deployment/php-apache   110%/50%   1         20        10         90m
php-apache   Deployment/php-apache   110%/50%   1         20        11         90m
php-apache   Deployment/php-apache   47%/50%    1         20        11         91m
.
.
.
php-apache   Deployment/php-apache   70%/50%    1         40        11         142m	# Replicas 2 --> 4
php-apache   Deployment/php-apache   70%/50%    1         40        16         142m
php-apache   Deployment/php-apache   64%/50%    1         40        16         143m
php-apache   Deployment/php-apache   64%/50%    1         40        21         143m
php-apache   Deployment/php-apache   54%/50%    1         40        21         144m
php-apache   Deployment/php-apache   51%/50%    1         40        21         145m
php-apache   Deployment/php-apache   50%/50%    1         40        21         147m

In the images below, taken from Grafana, the "jump" in the use of the CPU in the stress namespace is evident, caused by the increase in requests to the web application.

EduranceTest (xLarge)