0
0
Microservicessystem_design~10 mins

Incremental migration plan 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 identify the first step in an incremental migration plan.

Microservices
migration_steps = ['[1]', 'Build new services', 'Redirect traffic', 'Decommission old system']
Drag options to blanks, or click blank then click option'
AAnalyze current system
BTest new services
CRedirect traffic
DDeploy new services
Attempts:
3 left
💡 Hint
Common Mistakes
Choosing deployment or testing as the first step.
2fill in blank
medium

Complete the code to describe the purpose of building new services in migration.

Microservices
purpose = 'To [1] functionality from the monolith into independent services'
Drag options to blanks, or click blank then click option'
Adelay
Bremove
Ccombine
Dextract
Attempts:
3 left
💡 Hint
Common Mistakes
Choosing 'combine' or 'remove' which do not fit the migration goal.
3fill in blank
hard

Fix the error in the migration step that redirects user traffic.

Microservices
def redirect_traffic(service):
    if service.status == 'ready':
        service.[1]('start')
    else:
        print('Service not ready')
Drag options to blanks, or click blank then click option'
Aswitch
Bactivate
Cstop
Dredirect
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'stop' or 'redirect' which are not valid methods here.
4fill in blank
hard

Fill both blanks to complete the code that checks service readiness and switches traffic.

Microservices
if service.[1]() and system.[2]('all_services_ready'):
    system.switch_traffic_to(service)
Drag options to blanks, or click blank then click option'
Ais_ready
Bcheck_status
Cverify
Dis_active
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'verify' or 'is_active' which do not fit both blanks correctly.
5fill in blank
hard

Fill all three blanks to complete the code that decommissions old services after migration.

Microservices
if service.[1]() and not system.[2](service) and service.[3] == 'inactive':
    system.decommission(service)
Drag options to blanks, or click blank then click option'
Ais_deprecated
Bis_referenced
Cstatus
Dis_ready
Attempts:
3 left
💡 Hint
Common Mistakes
Confusing readiness with deprecation or referencing.