You will demonstrate how to achieve zero downtime upgrades of your
pal-tracker
application running on Tanzu Application Service.
After completing the lab, you will be able to:
Check out the Blue/Green slides.
You must have completed (or fast-forwarded to) the
Scaling lab.
You must have your pal-tracker
application associated with the
scaling-availability-solution
codebase deployed and running on
Tanzu Application Service.
In a terminal window,
make sure you start in the ~/workspace/pal-tracker
directory.
Cherry-pick the start point of this lab:
git cherry-pick rolling-upgrade-solution
In this lab you will exercise your pal-tracker
application under load.
You can monitor the pal-tracker
application through the following:
Command Line via the following cf
commands:
cf app pal-tracker
cf events pal-tracker
Apps Manager user interface.
If you will monitor via command line you will need a minimum of four terminal windows open.
If you choose to monitor with Apps Manager you will need only one.
What if you need to perform a zero downtime upgrade? How would you do that?
If you have not already, stage and commit your changes from this lab locally.
Pull in a script which will demonstrate a rolling upgrade:
git cherry-pick rolling-upgrade-solution
You can view the script here:
git show rolling-upgrade-solution:scripts/rolling-update.sh
Run a local build to compile, test and regenerate the
pal-tracker.jar
file:
./gradlew clean build
Run the script from the pal-tracker
project directory,
and make sure to supply the ${DOMAIN}
and ${UNIQUE_IDENTIFIER}
parameters you used in the Deployment Pipelines lab when
specifying the route in your manifest.yml
file:
./scripts/rolling-update.sh ${UNIQUE_IDENTIFIER} ${DOMAIN}
Follow the directions the script gives you to step through the process of a zero downtime upgrade.
cf cli v7
clientRead about how you can use
a newer cf
command line client
to perform a rolling update: