0
0
Microservicessystem_design~10 mins

Parallel running in Microservices - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to start the new service alongside the old one.

Microservices
new_service[1]();
Drag options to blanks, or click blank then click option'
Astart
Bstop
Crestart
Dpause
Attempts:
3 left
💡 Hint
Common Mistakes
Using stop() instead of start() causes the service not to run.
Using restart() stops the old service first, not parallel.
2fill in blank
medium

Complete the code to route traffic to both services during parallel running.

Microservices
router.addRoute('/api', [1]);
Drag options to blanks, or click blank then click option'
Acache
Bnew_service
Cold_service
DloadBalancer
Attempts:
3 left
💡 Hint
Common Mistakes
Routing only to old_service or new_service defeats parallel running.
Using cache does not distribute traffic.
3fill in blank
hard

Fix the error in the code to ensure both services run without conflict.

Microservices
if (old_service.status() == 'running' [1] new_service.status() == 'stopped') new_service.start();
Drag options to blanks, or click blank then click option'
Axor
Bor
Cand
Dnot
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'or' starts new_service even if old_service is not running.
Using 'not' or 'xor' causes logical errors.
4fill in blank
hard

Fill both blanks to correctly implement traffic splitting and monitoring.

Microservices
traffic_manager.setStrategy([1]); monitor.enable([2]);
Drag options to blanks, or click blank then click option'
Acanary
Blogging
Cmetrics
DblueGreen
Attempts:
3 left
💡 Hint
Common Mistakes
Using blueGreen for traffic splitting here is less gradual than canary.
Using logging instead of metrics misses performance data.
5fill in blank
hard

Fill all three blanks to complete the parallel running deployment steps.

Microservices
deploy([1]); monitor.[2](); if (monitor.status() [3] 'healthy') { old_service.stop(); }
Drag options to blanks, or click blank then click option'
Anew_version
Bstart
C==
Drollback
Attempts:
3 left
💡 Hint
Common Mistakes
Using rollback instead of deploy breaks deployment flow.
Using '!=' instead of '==' causes wrong condition check.