<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">

 <title>Robertus - DevOps & SRE Expert</title>
 <link href="https://robee.id/atom.xml" rel="self"/>
 <link href="https://robee.id/"/>
 <updated>2026-08-23T17:13:34+07:00</updated>
 <id>https://robee.id</id>
 <author>
   <name>Robertus</name>
   <email>kontak@robee.id</email>
 </author>

 
 <entry>
   <title>Perbandingan Mendalam: AWS VPC vs Google Cloud VPC</title>
   <link href="https://robee.id/2025/10/25/aws-vs-gcp-vpc-comparison"/>
   <updated>2025-10-25T10:00:00+07:00</updated>
   <id>https://robee.id/2025/10/25/aws-vs-gcp-vpc-comparison</id>
   <content type="html">&lt;p&gt;&lt;img src=&quot;https://images.unsplash.com/photo-1566443280617-35db331c54fb?ixlib=rb-4.1.0&amp;amp;ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&amp;amp;auto=format&amp;amp;fit=crop&amp;amp;q=80&amp;amp;w=2148&quot; alt=&quot;Cloud Networking&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Setelah beberapa tahun bekerja dengan kedua platform cloud ini, saya sering mendapat pertanyaan tentang perbandingan mendalam antara AWS VPC dan Google Cloud VPC. Keduanya memiliki filosofi desain yang sangat berbeda, dan pemahaman yang tepat tentang perbedaan ini sangat penting untuk arsitektur yang optimal.&lt;/p&gt;

&lt;p&gt;Pengalaman saya menunjukkan bahwa pilihan antara AWS dan GCP VPC tidak hanya tentang fitur, tapi juga tentang cara berpikir dalam mendesain jaringan cloud. Mari kita eksplorasi perbedaan fundamental ini.&lt;/p&gt;

&lt;h2 id=&quot;arsitektur-fundamental-regional-vs-global&quot;&gt;Arsitektur Fundamental: Regional vs Global&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;AWS VPC: Regional Approach&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;AWS VPC menggunakan pendekatan regional yang sangat ketat. Setiap VPC terbatas pada satu region saja, dan untuk koneksi antar region, kita perlu menggunakan VPC Peering atau Transit Gateway.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Membuat VPC di region us-east-1&lt;/span&gt;
aws ec2 create-vpc &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--cidr-block&lt;/span&gt; 10.0.0.0/16 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--region&lt;/span&gt; us-east-1

&lt;span class=&quot;c&quot;&gt;# Untuk koneksi ke region lain, perlu setup terpisah&lt;/span&gt;
aws ec2 create-vpc &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--cidr-block&lt;/span&gt; 10.1.0.0/16 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--region&lt;/span&gt; us-west-2
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Yang menarik dari pendekatan ini adalah isolasi yang sangat kuat antar region. Jika ada masalah di satu region, tidak akan mempengaruhi region lain. Tapi ini juga berarti kompleksitas yang lebih tinggi untuk aplikasi yang membutuhkan komunikasi global.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GCP VPC: Global Approach&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;GCP mengambil pendekatan yang sangat berbeda dengan VPC global. Satu VPC bisa span multiple regions, dan subnets bisa dibuat di region yang berbeda dalam VPC yang sama.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Membuat VPC global&lt;/span&gt;
gcloud compute networks create my-global-vpc &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--subnet-mode&lt;/span&gt; custom

&lt;span class=&quot;c&quot;&gt;# Membuat subnet di region berbeda dalam VPC yang sama&lt;/span&gt;
gcloud compute networks subnets create subnet-us &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--network&lt;/span&gt; my-global-vpc &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--range&lt;/span&gt; 10.0.0.0/24 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--region&lt;/span&gt; us-central1

gcloud compute networks subnets create subnet-asia &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--network&lt;/span&gt; my-global-vpc &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--range&lt;/span&gt; 10.0.1.0/24 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--region&lt;/span&gt; asia-southeast1
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Pendekatan global ini sangat powerful untuk aplikasi yang membutuhkan komunikasi internal antar region tanpa perlu konfigurasi tambahan.&lt;/p&gt;

&lt;h2 id=&quot;manajemen-ip-dan-subnet&quot;&gt;Manajemen IP dan Subnet&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;AWS VPC: CIDR Block Management&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;AWS memerlukan CIDR block yang didefinisikan saat membuat VPC. Semua subnet harus berada dalam CIDR block ini.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# VPC dengan CIDR 10.0.0.0/16&lt;/span&gt;
&lt;span class=&quot;c&quot;&gt;# Subnet bisa dibuat dengan range:&lt;/span&gt;
&lt;span class=&quot;c&quot;&gt;# - 10.0.1.0/24 (us-east-1a)&lt;/span&gt;
&lt;span class=&quot;c&quot;&gt;# - 10.0.2.0/24 (us-east-1b)&lt;/span&gt;
&lt;span class=&quot;c&quot;&gt;# - 10.0.3.0/24 (us-east-1c)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Kelemahan dari pendekatan ini adalah jika kita salah planning CIDR block di awal, akan sulit untuk mengubahnya nanti. AWS memang mendukung secondary CIDR blocks, tapi prosesnya tidak semudah yang diharapkan.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GCP VPC: Flexible Subnet Management&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;GCP tidak memerlukan CIDR block di level VPC. Setiap subnet bisa memiliki CIDR block yang independen, dan kita bisa menambah CIDR range ke subnet yang sudah ada tanpa perlu recreate.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Subnet bisa memiliki range yang tidak berurutan&lt;/span&gt;
&lt;span class=&quot;c&quot;&gt;# Subnet 1: 10.0.1.0/24&lt;/span&gt;
&lt;span class=&quot;c&quot;&gt;# Subnet 2: 192.168.1.0/24&lt;/span&gt;
&lt;span class=&quot;c&quot;&gt;# Subnet 3: 172.16.1.0/24&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# Dan bisa di-expand tanpa recreate&lt;/span&gt;
gcloud compute networks subnets expand-ip-range subnet-1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--prefix-length&lt;/span&gt; 23
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Fleksibilitas ini sangat berguna untuk organisasi yang memiliki IP planning yang kompleks atau yang perlu mengintegrasikan dengan jaringan on-premise.&lt;/p&gt;

&lt;h2 id=&quot;security-model-layered-vs-unified&quot;&gt;Security Model: Layered vs Unified&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;AWS VPC: Multi-Layer Security&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;AWS menggunakan model security yang berlapis dengan Security Groups dan Network ACLs.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Security Group (stateful, instance level)&lt;/span&gt;
aws ec2 create-security-group &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--group-name&lt;/span&gt; web-servers &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--description&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;Security group for web servers&quot;&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# Network ACL (stateless, subnet level)&lt;/span&gt;
aws ec2 create-network-acl &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--vpc-id&lt;/span&gt; vpc-xxxxxxxxx
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Security Groups bersifat stateful dan diterapkan di level instance, sementara Network ACLs bersifat stateless dan diterapkan di level subnet. Ini memberikan granular control yang sangat detail, tapi juga kompleksitas yang tinggi.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GCP VPC: Unified Firewall Rules&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;GCP menggunakan sistem firewall rules yang unified dan stateful. Rules bisa diterapkan berdasarkan network tags atau service accounts.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Firewall rule berdasarkan network tags&lt;/span&gt;
gcloud compute firewall-rules create allow-web &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--network&lt;/span&gt; my-global-vpc &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--allow&lt;/span&gt; tcp:80,tcp:443 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--target-tags&lt;/span&gt; web-server &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--source-ranges&lt;/span&gt; 0.0.0.0/0
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Pendekatan ini lebih sederhana untuk di-manage, tapi mungkin kurang granular dibandingkan AWS. Yang menarik, GCP firewall rules bisa diterapkan secara global dalam VPC.&lt;/p&gt;

&lt;h2 id=&quot;load-balancing-regional-vs-global&quot;&gt;Load Balancing: Regional vs Global&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;AWS VPC: Regional Load Balancers&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;AWS memiliki berbagai jenis load balancer yang semuanya regional:&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Application Load Balancer (ALB)&lt;/li&gt;
  &lt;li&gt;Network Load Balancer (NLB)&lt;/li&gt;
  &lt;li&gt;Classic Load Balancer (CLB)&lt;/li&gt;
&lt;/ul&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# ALB hanya bisa di satu region&lt;/span&gt;
aws elbv2 create-load-balancer &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt; my-alb &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--subnets&lt;/span&gt; subnet-aaaa1111 subnet-bbbb2222
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Untuk multi-region, kita perlu setup load balancer terpisah di setiap region dan menggunakan Route 53 untuk traffic distribution.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GCP VPC: Global Load Balancers&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;GCP menawarkan global load balancers yang bisa span multiple regions dengan failover otomatis.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Global HTTP(S) Load Balancer&lt;/span&gt;
gcloud compute backend-services create web-backend &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--global&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--protocol&lt;/span&gt; HTTP

&lt;span class=&quot;c&quot;&gt;# Bisa menambahkan backend di region berbeda&lt;/span&gt;
gcloud compute backend-services add-backend web-backend &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--global&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--instance-group&lt;/span&gt; us-central1-group &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--instance-group-region&lt;/span&gt; us-central1
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Ini sangat powerful untuk aplikasi yang membutuhkan high availability dan low latency global.&lt;/p&gt;

&lt;h2 id=&quot;hybrid-connectivity&quot;&gt;Hybrid Connectivity&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;AWS VPC: Direct Connect dan VPN&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;AWS menawarkan Direct Connect untuk dedicated connection dan Site-to-Site VPN untuk IPsec-based connectivity.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Site-to-Site VPN&lt;/span&gt;
aws ec2 create-vpn-connection &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--type&lt;/span&gt; ipsec.1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--customer-gateway-id&lt;/span&gt; cgw-xxxxxxxxx &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--vpn-gateway-id&lt;/span&gt; vgw-xxxxxxxxx
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Direct Connect memberikan dedicated bandwidth dan lower latency, tapi harganya cukup mahal dan memerlukan setup yang kompleks.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GCP VPC: Cloud Interconnect dan Cloud VPN&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;GCP menawarkan Cloud Interconnect (dedicated) dan Cloud VPN dengan high availability.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Cloud VPN dengan HA&lt;/span&gt;
gcloud compute vpn-tunnels create tunnel-1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--peer-address&lt;/span&gt; 203.0.113.1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--shared-secret&lt;/span&gt; secret123 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--target-vpn-gateway&lt;/span&gt; vpn-gateway-1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--local-traffic-selector&lt;/span&gt; 0.0.0.0/0 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--remote-traffic-selector&lt;/span&gt; 0.0.0.0/0
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Yang menarik, GCP Cloud VPN mendukung active-active configuration yang memberikan redundancy yang lebih baik.&lt;/p&gt;

&lt;h2 id=&quot;monitoring-dan-observability&quot;&gt;Monitoring dan Observability&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;AWS VPC: VPC Flow Logs&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;AWS VPC Flow Logs bisa dikirim ke CloudWatch Logs atau S3 untuk analisis.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Enable VPC Flow Logs&lt;/span&gt;
aws ec2 create-flow-logs &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--resource-type&lt;/span&gt; VPC &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--resource-ids&lt;/span&gt; vpc-xxxxxxxxx &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--traffic-type&lt;/span&gt; ALL &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--log-destination-type&lt;/span&gt; s3 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--log-destination&lt;/span&gt; arn:aws:s3:::my-flow-logs-bucket
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Integrasi dengan GuardDuty dan Athena memberikan security monitoring yang comprehensive.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GCP VPC: Rich Flow Logs&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;GCP VPC Flow Logs lebih kaya metadata dan terintegrasi dengan Cloud Logging.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Enable VPC Flow Logs&lt;/span&gt;
gcloud compute networks subnets update subnet-1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--region&lt;/span&gt; us-central1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--enable-flow-logs&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--logging-aggregation-interval&lt;/span&gt; interval-5-sec &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--logging-flow-sampling&lt;/span&gt; 0.5
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Data bisa di-export ke BigQuery untuk analisis yang lebih advanced.&lt;/p&gt;

&lt;h2 id=&quot;pricing-model&quot;&gt;Pricing Model&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;AWS VPC: Pay-per-Use dengan Kompleksitas&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;AWS menggunakan model pricing yang cukup kompleks dengan berbagai komponen:&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Data transfer antar AZ: $0.01/GB&lt;/li&gt;
  &lt;li&gt;NAT Gateway: $0.045/hour + $0.045/GB&lt;/li&gt;
  &lt;li&gt;VPC Endpoints: $0.01/GB&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Yang sering mengejutkan adalah biaya data transfer yang bisa sangat tinggi untuk aplikasi yang banyak komunikasi antar AZ.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GCP VPC: Simplified Pricing&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;GCP memiliki pricing yang lebih sederhana:&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Data transfer antar region: $0.12/GB (first 1TB)&lt;/li&gt;
  &lt;li&gt;Cloud NAT: $0.045/hour + $0.045/GB&lt;/li&gt;
  &lt;li&gt;Tidak ada biaya untuk data transfer dalam region&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Yang menarik, GCP tidak mengenakan biaya untuk data transfer dalam region yang sama.&lt;/p&gt;

&lt;h2 id=&quot;pros-dan-cons-summary&quot;&gt;Pros dan Cons Summary&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;AWS VPC - Pros:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Ecosystem yang sangat mature dengan third-party integrations yang luas&lt;/li&gt;
  &lt;li&gt;Granular control yang sangat detail untuk networking components&lt;/li&gt;
  &lt;li&gt;Security features yang robust dan battle-tested&lt;/li&gt;
  &lt;li&gt;Dokumentasi dan community support yang sangat baik&lt;/li&gt;
  &lt;li&gt;Integrasi yang seamless dengan layanan AWS lainnya&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;AWS VPC - Cons:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Learning curve yang sangat steep karena kompleksitas&lt;/li&gt;
  &lt;li&gt;Pricing structure yang kompleks dan bisa unpredictable&lt;/li&gt;
  &lt;li&gt;Regional limitation yang memerlukan setup tambahan untuk global connectivity&lt;/li&gt;
  &lt;li&gt;Management overhead yang tinggi untuk multi-region deployments&lt;/li&gt;
  &lt;li&gt;Biaya data transfer yang bisa sangat mahal&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;GCP VPC - Pros:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Global networking yang simplified dan powerful&lt;/li&gt;
  &lt;li&gt;Pricing model yang lebih predictable dan cost-effective&lt;/li&gt;
  &lt;li&gt;Performance yang excellent untuk AI dan data analytics workloads&lt;/li&gt;
  &lt;li&gt;Global load balancing dengan failover otomatis&lt;/li&gt;
  &lt;li&gt;Flexible IP management dan subnet expansion&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;GCP VPC - Cons:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Market share yang lebih kecil, sehingga community resources lebih terbatas&lt;/li&gt;
  &lt;li&gt;Enterprise support yang masih berkembang dibandingkan AWS&lt;/li&gt;
  &lt;li&gt;Global reach yang lebih terbatas dengan fewer data centers&lt;/li&gt;
  &lt;li&gt;Learning curve untuk team yang sudah familiar dengan AWS&lt;/li&gt;
  &lt;li&gt;Beberapa advanced networking features masih dalam development&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;use-cases-dan-rekomendasi&quot;&gt;Use Cases dan Rekomendasi&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Pilih AWS VPC jika:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Aplikasi membutuhkan granular control yang sangat detail&lt;/li&gt;
  &lt;li&gt;Sudah memiliki investment yang besar di AWS ecosystem&lt;/li&gt;
  &lt;li&gt;Memerlukan compliance dan security features yang sangat ketat&lt;/li&gt;
  &lt;li&gt;Team sudah familiar dengan AWS dan tidak ingin learning curve tambahan&lt;/li&gt;
  &lt;li&gt;Aplikasi bersifat regional dan tidak memerlukan global connectivity yang kompleks&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Pilih GCP VPC jika:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Aplikasi membutuhkan global connectivity dan multi-region deployment&lt;/li&gt;
  &lt;li&gt;Budget adalah concern utama dan ingin pricing yang lebih predictable&lt;/li&gt;
  &lt;li&gt;Aplikasi heavy di AI/ML dan data analytics&lt;/li&gt;
  &lt;li&gt;Ingin simplified networking management&lt;/li&gt;
  &lt;li&gt;Aplikasi membutuhkan global load balancing dengan high availability&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;refleksi-dan-pembelajaran&quot;&gt;Refleksi dan Pembelajaran&lt;/h2&gt;

&lt;p&gt;Setelah bekerja dengan kedua platform ini, beberapa insight yang saya dapatkan:&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Philosophy Matters&lt;/strong&gt;: AWS dan GCP memiliki filosofi desain yang sangat berbeda. AWS fokus pada granular control dan flexibility, sementara GCP fokus pada simplicity dan global connectivity.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Trade-offs are Real&lt;/strong&gt;: Tidak ada solusi yang perfect. AWS memberikan control yang lebih detail tapi dengan kompleksitas yang tinggi. GCP memberikan simplicity tapi dengan flexibility yang lebih terbatas.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Cost Implications&lt;/strong&gt;: Pricing model yang berbeda bisa memberikan impact yang signifikan pada total cost of ownership, terutama untuk aplikasi yang data-intensive.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Team Expertise&lt;/strong&gt;: Pilihan platform seringkali dipengaruhi oleh expertise team yang ada, dan ini adalah faktor yang valid untuk dipertimbangkan.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Future-Proofing&lt;/strong&gt;: Kedua platform terus berkembang, dan fitur yang tidak ada hari ini mungkin akan tersedia besok.&lt;/p&gt;
  &lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Yang paling penting adalah memahami kebutuhan aplikasi dan organisasi dengan baik sebelum memilih platform. Tidak ada jawaban yang benar atau salah - yang ada adalah pilihan yang tepat untuk konteks yang spesifik.&lt;/p&gt;

&lt;p&gt;Dalam pengalaman saya, banyak organisasi yang akhirnya menggunakan multi-cloud strategy, memanfaatkan strength dari masing-masing platform untuk use case yang berbeda. Ini adalah pendekatan yang semakin populer dan bisa memberikan best of both worlds.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Belajar Setup AWS Application Load Balancer dengan AWS CLI</title>
   <link href="https://robee.id/2025/10/04/aws-alb-practice"/>
   <updated>2025-10-04T10:00:00+07:00</updated>
   <id>https://robee.id/2025/10/04/aws-alb-practice</id>
   <content type="html">&lt;p&gt;&lt;img src=&quot;https://images.unsplash.com/photo-1558494949-ef010cbdcc31?ixlib=rb-4.0.3&amp;amp;auto=format&amp;amp;fit=crop&amp;amp;w=1200&amp;amp;q=80&quot; alt=&quot;AWS Load Balancer&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Baru-baru ini saya memutuskan untuk belajar lebih dalam tentang AWS Application Load Balancer (ALB) dengan mencoba setup dari nol menggunakan AWS CLI. Meskipun sudah familiar dengan konsep load balancing, ternyata ada banyak detail teknis yang perlu dipahami ketika melakukan setup manual via command line.&lt;/p&gt;

&lt;p&gt;Pengalaman ini memberikan insight yang cukup menarik tentang bagaimana AWS mengelola infrastruktur load balancing di balik layar, dan juga beberapa gotcha yang tidak terduga.&lt;/p&gt;

&lt;h2 id=&quot;persiapan-environment&quot;&gt;Persiapan Environment&lt;/h2&gt;

&lt;p&gt;Sebelum memulai eksperimen, saya perlu memastikan beberapa hal:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. AWS CLI sudah terinstall&lt;/strong&gt;
Saya cek dulu versi yang terinstall:&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws &lt;span class=&quot;nt&quot;&gt;--version&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;2. AWS credentials sudah dikonfigurasi&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws configure
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Saya menggunakan region us-east-1 dan output format json untuk konsistensi.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Infrastructure yang sudah ada:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;VPC ID (vpc-xxxxxxxxxxxxxxxxx)&lt;/li&gt;
  &lt;li&gt;Dua subnet dalam VPC yang sama&lt;/li&gt;
  &lt;li&gt;Security group yang mengizinkan inbound HTTP (port 80)&lt;/li&gt;
  &lt;li&gt;Dua instance EC2 yang menjalankan web server (Apache)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Saya sengaja menggunakan environment yang sudah ada untuk meminimalisir biaya eksperimen.&lt;/p&gt;

&lt;h2 id=&quot;membuat-load-balancer&quot;&gt;Membuat Load Balancer&lt;/h2&gt;

&lt;p&gt;Langkah pertama adalah membuat Application Load Balancer. Saya memilih ALB karena lebih modern dibandingkan Classic Load Balancer dan mendukung advanced routing features.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws elbv2 create-load-balancer &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt; my-LB &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--subnets&lt;/span&gt; subnet-aaaa1111 subnet-bbbb2222 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--security-groups&lt;/span&gt; sg-cccc3333
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Yang menarik, command ini langsung menghasilkan output JSON dengan LoadBalancerArn:&lt;/p&gt;
&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;arn:aws:elasticloadbalancing:us-east-1:123456789012:loadbalancer/app/my-LB/abcd1234efgh5678
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Saya menyimpan ARN ini karena akan digunakan di hampir semua command selanjutnya. Ini adalah pattern yang konsisten di AWS CLI - setiap resource yang dibuat akan menghasilkan ARN yang unik.&lt;/p&gt;

&lt;h2 id=&quot;membuat-target-groups&quot;&gt;Membuat Target Groups&lt;/h2&gt;

&lt;p&gt;Konsep target group ini cukup baru bagi saya. Ternyata ALB tidak langsung mengarahkan traffic ke instance, tapi melalui target group dulu. Ini memberikan fleksibilitas untuk mengelompokkan instance berdasarkan kriteria tertentu.&lt;/p&gt;

&lt;p&gt;Saya membuat dua target group untuk eksperimen:&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws elbv2 create-target-group &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt; TG1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--protocol&lt;/span&gt; HTTP &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--port&lt;/span&gt; 80 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--vpc-id&lt;/span&gt; vpc-xxxxxxxxxxxxxxxxx

aws elbv2 create-target-group &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt; TG2 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--protocol&lt;/span&gt; HTTP &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--port&lt;/span&gt; 80 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--vpc-id&lt;/span&gt; vpc-xxxxxxxxxxxxxxxxx
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Setiap target group menghasilkan ARN yang unik:&lt;/p&gt;
&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG1/aaaa1111bbbb2222
arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG2/cccc3333dddd4444
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Saya mulai memahami mengapa AWS menggunakan ARN - ini memungkinkan referensi yang unik dan konsisten di seluruh layanan.&lt;/p&gt;

&lt;h2 id=&quot;registrasi-ec2-instances-ke-target-groups&quot;&gt;Registrasi EC2 Instances ke Target Groups&lt;/h2&gt;

&lt;p&gt;Ini adalah bagian yang cukup tricky. Saya perlu mendaftarkan instance EC2 ke target group yang sesuai. Awalnya saya bingung, kenapa tidak bisa langsung assign instance ke load balancer?&lt;/p&gt;

&lt;p&gt;Ternyata konsepnya adalah: Load Balancer → Target Group → EC2 Instances&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws elbv2 register-targets &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--target-group-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG1/aaaa1111bbbb2222 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--targets&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;i-1111aaaa2222bbbb

aws elbv2 register-targets &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--target-group-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG2/cccc3333dddd4444 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--targets&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;i-3333cccc4444dddd
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Sekarang TG1 memiliki instance1, TG2 memiliki instance2. Saya mulai melihat pola arsitektur AWS yang lebih modular dibandingkan solusi tradisional.&lt;/p&gt;

&lt;h2 id=&quot;membuat-listener-untuk-load-balancer&quot;&gt;Membuat Listener untuk Load Balancer&lt;/h2&gt;

&lt;p&gt;Ini adalah bagian yang paling membingungkan bagi saya. Load balancer tanpa listener tidak akan menerima traffic sama sekali! Listener adalah “telinga” yang mendengarkan request masuk.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws elbv2 create-listener &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--load-balancer-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:loadbalancer/app/my-LB/abcd1234efgh5678 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--protocol&lt;/span&gt; HTTP &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--port&lt;/span&gt; 80 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--default-actions&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Type&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;forward,TargetGroupArn&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG1/aaaa1111bbbb2222
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Saya set TG1 sebagai default action, artinya semua traffic yang tidak match dengan rule lain akan pergi ke TG1. Ini adalah konsep “catch-all” yang cukup berguna.&lt;/p&gt;

&lt;h2 id=&quot;membuat-rules-untuk-path-based-routing&quot;&gt;Membuat Rules untuk Path-Based Routing&lt;/h2&gt;

&lt;p&gt;Ini adalah fitur yang paling menarik bagi saya! ALB bisa melakukan routing berdasarkan path pattern. Saya ingin mencoba skenario:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;/images/*&lt;/code&gt; → TG1 (untuk static assets)&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;/work/*&lt;/code&gt; → TG2 (untuk aplikasi work)&lt;/li&gt;
&lt;/ul&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws elbv2 create-rule &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--listener-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:listener/app/my-LB/abcd1234efgh5678/xyz9876 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--priority&lt;/span&gt; 10 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--conditions&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Field&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;path-pattern,Values&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;/images/*&apos;&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--actions&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Type&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;forward,TargetGroupArn&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG1/aaaa1111bbbb2222

aws elbv2 create-rule &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--listener-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:listener/app/my-LB/abcd1234efgh5678/xyz9876 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--priority&lt;/span&gt; 5 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--conditions&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Field&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;path-pattern,Values&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;/work/*&apos;&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--actions&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Type&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;forward,TargetGroupArn&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG2/cccc3333dddd4444
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Yang menarik, priority 5 akan dievaluasi sebelum priority 10. Saya sempat bingung dengan urutan ini, tapi ternyata AWS menggunakan sistem priority yang lebih rendah = lebih tinggi prioritasnya.&lt;/p&gt;

&lt;h2 id=&quot;verifikasi-target-health&quot;&gt;Verifikasi Target Health&lt;/h2&gt;

&lt;p&gt;Setelah semua setup, saya penasaran apakah instance saya benar-benar sehat dan siap menerima traffic. ALB punya health check mechanism yang otomatis.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws elbv2 describe-target-health &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--target-group-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG1/aaaa1111bbbb2222

aws elbv2 describe-target-health &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--target-group-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG2/cccc3333dddd4444
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Ketika saya melihat &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&quot;state&quot;: &quot;healthy&quot;&lt;/code&gt;, rasanya lega! Ini berarti instance saya benar-benar siap dan ALB akan mengirim traffic ke sana. Health check ini adalah fitur yang sangat penting untuk production environment.&lt;/p&gt;

&lt;h2 id=&quot;testing-load-balancer&quot;&gt;Testing Load Balancer&lt;/h2&gt;

&lt;p&gt;Moment of truth! Saya buka DNS name dari load balancer (bisa ditemukan di output create-load-balancer command) dan mulai testing:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;http://&amp;lt;LB-DNS&amp;gt;/images/&lt;/code&gt; → seharusnya pergi ke TG1 backend&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;http://&amp;lt;LB-DNS&amp;gt;/work/&lt;/code&gt; → seharusnya pergi ke TG2 backend&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Dan ternyata… berhasil! Saya bisa melihat response yang berbeda dari kedua backend. Ini adalah momen yang cukup memuaskan setelah setup yang cukup panjang.&lt;/p&gt;

&lt;p&gt;Yang menarik, ALB juga memberikan response header &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;X-Amzn-Trace-Id&lt;/code&gt; yang bisa digunakan untuk tracing request flow.&lt;/p&gt;

&lt;h2 id=&quot;cleanup-resources&quot;&gt;Cleanup Resources&lt;/h2&gt;

&lt;p&gt;Setelah eksperimen selesai, saya harus cleanup semua resources agar tidak kena charge. Ini adalah bagian yang tidak kalah penting!&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Hapus Rules:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws elbv2 delete-rule &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--rule-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:listener-rule/app/my-LB/abcd1234efgh5678/xyz9876/priority10

aws elbv2 delete-rule &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--rule-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:listener-rule/app/my-LB/abcd1234efgh5678/xyz9876/priority5
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Hapus Listener:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws elbv2 delete-listener &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--listener-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:listener/app/my-LB/abcd1234efgh5678/xyz9876
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Hapus Load Balancer:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws elbv2 delete-load-balancer &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--load-balancer-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:loadbalancer/app/my-LB/abcd1234efgh5678
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Saya harus menunggu sampai load balancer benar-benar terhapus (ini memakan waktu 1-2 menit). AWS tidak mengizinkan penghapusan target group jika masih ada dependency.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Hapus Target Groups:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws elbv2 delete-target-group &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--target-group-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG1/aaaa1111bbbb2222

aws elbv2 delete-target-group &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--target-group-arn&lt;/span&gt; arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/TG2/cccc3333dddd4444
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Environment ALB saya sekarang sudah bersih dan tidak akan kena charge lagi.&lt;/p&gt;

&lt;h2 id=&quot;refleksi-dan-pembelajaran&quot;&gt;Refleksi dan Pembelajaran&lt;/h2&gt;

&lt;p&gt;Eksperimen ini memberikan beberapa insight menarik:&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Modularity&lt;/strong&gt;: AWS ALB menggunakan arsitektur yang sangat modular dengan komponen yang saling terpisah (Load Balancer → Listener → Rules → Target Groups → Instances)&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;ARN System&lt;/strong&gt;: Setiap resource memiliki ARN yang unik, memungkinkan referensi yang konsisten di seluruh AWS ecosystem&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Health Checks&lt;/strong&gt;: ALB secara otomatis melakukan health check dan hanya mengirim traffic ke instance yang sehat&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Path-based Routing&lt;/strong&gt;: Fitur ini sangat powerful untuk microservices architecture&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Cost Awareness&lt;/strong&gt;: Cleanup yang proper sangat penting untuk menghindari unexpected charges&lt;/p&gt;
  &lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Yang paling mengejutkan adalah betapa kompleksnya setup yang terlihat sederhana di AWS Console. Melakukan setup via CLI memberikan pemahaman yang lebih dalam tentang bagaimana AWS mengelola infrastruktur di balik layar.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Eksperimen Rclone untuk Sinkronisasi Data antar Cloud Provider</title>
   <link href="https://robee.id/2025/08/27/rclone-experiment-s3-gcs-sync"/>
   <updated>2025-08-27T10:00:00+07:00</updated>
   <id>https://robee.id/2025/08/27/rclone-experiment-s3-gcs-sync</id>
   <content type="html">&lt;p&gt;&lt;img src=&quot;https://images.unsplash.com/photo-1451187580459-43490279c0fa?ixlib=rb-4.0.3&amp;amp;auto=format&amp;amp;fit=crop&amp;amp;w=1200&amp;amp;q=80&quot; alt=&quot;Cloud Data Synchronization&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Sebagai bagian dari eksperimen pribadi untuk memahami berbagai tool sinkronisasi cloud storage, saya tertarik untuk mencoba kemampuan rclone dalam memindahkan data antara Google Cloud Storage (GCS) bucket dan Amazon S3 bucket. Meskipun tersedia managed service seperti AWS DataSync atau GCP Storage Transfer Service, eksperimen ini bertujuan untuk mengevaluasi rclone sebagai alternatif yang lebih cost-effective.&lt;/p&gt;

&lt;p&gt;Rclone, sebagai sebuah command line tool yang cukup matang untuk sinkronisasi cloud storage, ternyata memberikan hasil yang cukup memuaskan dengan beberapa catatan penting yang perlu diperhatikan dalam eksperimen ini.&lt;/p&gt;

&lt;h2 id=&quot;konfigurasi-rclone&quot;&gt;Konfigurasi Rclone&lt;/h2&gt;

&lt;p&gt;Untuk dapat melakukan sinkronisasi antar cloud provider, terlebih dahulu perlu dilakukan konfigurasi rclone untuk kedua layanan cloud storage. Alih-alih menggunakan mode interaktif, saya memilih pendekatan command line agar konfigurasi dapat direproduksi dengan mudah.&lt;/p&gt;

&lt;h3 id=&quot;konfigurasi-google-cloud-storage&quot;&gt;Konfigurasi Google Cloud Storage&lt;/h3&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;rclone config create gcs &lt;span class=&quot;s2&quot;&gt;&quot;google cloud storage&quot;&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  project_number &lt;span class=&quot;s2&quot;&gt;&quot;123456789&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Hal penting yang perlu diperhatikan adalah penggunaan &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;project_number&lt;/code&gt; dan bukan &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;project_id&lt;/code&gt;. Kesalahan umum yang sering terjadi adalah mencampurkan kedua parameter ini, yang dapat menyebabkan kegagalan otentikasi.&lt;/p&gt;

&lt;h3 id=&quot;konfigurasi-aws-s3&quot;&gt;Konfigurasi AWS S3&lt;/h3&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;rclone config create aws s3 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  provider AWS &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  env_auth &lt;span class=&quot;nb&quot;&gt;true&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  region ap-southeast-3 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  endpoint https://s3.ap-southeast-3.amazonaws.com
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Pada konfigurasi S3, saya menggunakan &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;env_auth true&lt;/code&gt; yang memungkinkan rclone mengambil credentials dari environment variables (AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, dll). Pendekatan ini lebih aman dibandingkan dengan menyimpan credentials secara langsung di file konfigurasi.&lt;/p&gt;

&lt;p&gt;Region &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;ap-southeast-3&lt;/code&gt; adalah Jakarta region yang memiliki performa cukup baik untuk user di Indonesia.&lt;/p&gt;

&lt;h2 id=&quot;verifikasi-akses-bucket&quot;&gt;Verifikasi Akses Bucket&lt;/h2&gt;

&lt;p&gt;Sebelum memulai proses sinkronisasi, langkah yang baik adalah memverifikasi terlebih dahulu bahwa rclone dapat mengakses kedua bucket:&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;rclone lsd gcs:gcp-bucket
rclone lsd aws:aws-bucket
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Command &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;lsd&lt;/code&gt; (list directories) berguna untuk memverifikasi akses dan melihat struktur folder di dalam bucket.&lt;/p&gt;

&lt;h2 id=&quot;proses-sinkronisasi-data&quot;&gt;Proses Sinkronisasi Data&lt;/h2&gt;

&lt;p&gt;Berikut adalah command utama yang digunakan untuk melakukan sinkronisasi:&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;rclone &lt;span class=&quot;nb&quot;&gt;sync &lt;/span&gt;gcs:gcp-bucket aws:aws-bucket  &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--transfers&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;64 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--checkers&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;64 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--multi-thread-streams&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;16 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--multi-thread-cutoff&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;100M &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--buffer-size&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;256M &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--s3-chunk-size&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;64M &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--s3-upload-concurrency&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;32 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--fast-list&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--progress&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;--stats&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;30s
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Berikut penjelasan detail dari masing-masing parameter:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;--transfers=64&lt;/code&gt;: Jumlah file transfer yang berjalan secara paralel&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;--checkers=64&lt;/code&gt;: Jumlah checker yang berjalan paralel untuk membandingkan source dan destination&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;--multi-thread-streams=16&lt;/code&gt;: Jumlah stream per file untuk file berukuran besar&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;--multi-thread-cutoff=100M&lt;/code&gt;: File yang lebih besar dari nilai ini akan dipecah menjadi multiple streams&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;--buffer-size=256M&lt;/code&gt;: Buffer size untuk operasi read&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;--s3-chunk-size=64M&lt;/code&gt;: Ukuran chunk untuk S3 multipart uploads&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;--s3-upload-concurrency=32&lt;/code&gt;: Jumlah concurrent S3 uploads&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;--fast-list&lt;/code&gt;: Menggunakan recursive listing (lebih cepat tapi menggunakan memori lebih banyak)&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;--progress --stats=30s&lt;/code&gt;: Menampilkan progress setiap 30 detik&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Perlu diperhatikan bahwa pengaturan ini cukup agresif dan dapat membebani network atau mencapai API rate limits. Disarankan untuk memulai dengan nilai yang lebih rendah dan melakukan penyesuaian secara bertahap.&lt;/p&gt;

&lt;h2 id=&quot;verifikasi-hasil-sinkronisasi&quot;&gt;Verifikasi Hasil Sinkronisasi&lt;/h2&gt;

&lt;p&gt;Setelah proses sinkronisasi selesai, langkah penting selanjutnya adalah melakukan verifikasi:&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;rclone size aws:aws-bucket
rclone size gcs:gcp-bucket
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Command ini akan menampilkan total ukuran dan jumlah objek di masing-masing bucket. Kedua nilai tersebut seharusnya sama jika proses sinkronisasi berhasil.&lt;/p&gt;

&lt;h2 id=&quot;perbandingan-dengan-managed-solutions&quot;&gt;Perbandingan dengan Managed Solutions&lt;/h2&gt;

&lt;h3 id=&quot;aws-datasync&quot;&gt;AWS DataSync&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Keunggulan DataSync:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Layanan yang sepenuhnya dikelola oleh AWS&lt;/li&gt;
  &lt;li&gt;Built-in data validation&lt;/li&gt;
  &lt;li&gt;Integrasi yang lebih baik dengan layanan AWS lainnya&lt;/li&gt;
  &lt;li&gt;Automatic retry mechanism&lt;/li&gt;
  &lt;li&gt;Bandwidth throttling&lt;/li&gt;
  &lt;li&gt;Integrasi dengan CloudWatch untuk monitoring&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Kekurangan DataSync:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Biaya yang lebih mahal, terutama untuk dataset besar&lt;/li&gt;
  &lt;li&gt;Opsi konfigurasi yang lebih terbatas&lt;/li&gt;
  &lt;li&gt;Vendor lock-in dengan ekosistem AWS&lt;/li&gt;
  &lt;li&gt;Customization yang terbatas&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;gcp-storage-transfer-service&quot;&gt;GCP Storage Transfer Service&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Keunggulan Storage Transfer Service:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Integrasi native dengan GCP&lt;/li&gt;
  &lt;li&gt;Scheduled transfers&lt;/li&gt;
  &lt;li&gt;Built-in monitoring dan logging&lt;/li&gt;
  &lt;li&gt;Tidak perlu mengelola infrastruktur&lt;/li&gt;
  &lt;li&gt;Automatic resumption untuk transfer yang gagal&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Kekurangan Storage Transfer Service:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Terbatas pada kombinasi source/destination tertentu&lt;/li&gt;
  &lt;li&gt;Kontrol yang lebih sedikit terhadap parameter transfer&lt;/li&gt;
  &lt;li&gt;Dapat menjadi mahal untuk transfer yang sering&lt;/li&gt;
  &lt;li&gt;Terkadang lebih lambat dibandingkan rclone yang dioptimasi&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;keunggulan-menggunakan-rclone&quot;&gt;Keunggulan Menggunakan Rclone&lt;/h2&gt;

&lt;ol&gt;
  &lt;li&gt;&lt;strong&gt;Cost Effective&lt;/strong&gt;: Hanya perlu membayar compute instance tempat rclone berjalan, ditambah biaya data transfer&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Highly Configurable&lt;/strong&gt;: Banyak parameter yang dapat disesuaikan untuk optimasi performa&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Multi-Cloud Native&lt;/strong&gt;: Kompatibel dengan hampir semua cloud storage provider&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Open Source&lt;/strong&gt;: Gratis dan dapat dikembangkan lebih lanjut&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Powerful Features&lt;/strong&gt;: Enkripsi, kompresi, filtering, dan berbagai fitur lainnya&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Local Control&lt;/strong&gt;: Dapat dijalankan dari infrastruktur sendiri&lt;/li&gt;
&lt;/ol&gt;

&lt;h2 id=&quot;kekurangan-dan-hal-yang-perlu-diperhatikan&quot;&gt;Kekurangan dan Hal yang Perlu Diperhatikan&lt;/h2&gt;

&lt;ol&gt;
  &lt;li&gt;&lt;strong&gt;Complexity&lt;/strong&gt;: Memerlukan pemahaman terhadap berbagai parameter dan implikasinya&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;No Built-in Monitoring&lt;/strong&gt;: Perlu setup monitoring dan alerting secara manual&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Network Dependency&lt;/strong&gt;: Performa sangat bergantung pada koneksi network yang tersedia&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Resource Usage&lt;/strong&gt;: Dapat mengonsumsi CPU dan memory yang signifikan dengan pengaturan agresif&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Error Handling&lt;/strong&gt;: Memerlukan logic retry manual untuk production workloads&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Rate Limiting&lt;/strong&gt;: Mudah mencapai API rate limits dengan pengaturan yang terlalu agresif&lt;/li&gt;
&lt;/ol&gt;

&lt;h2 id=&quot;pembelajaran-dari-eksperimen&quot;&gt;Pembelajaran dari Eksperimen&lt;/h2&gt;

&lt;ol&gt;
  &lt;li&gt;&lt;strong&gt;Mulai dengan Pengaturan Konservatif&lt;/strong&gt;: Mulai dengan transfer rate yang rendah dan tingkatkan secara bertahap&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Monitor Resource Usage&lt;/strong&gt;: Perhatikan penggunaan CPU, memory, dan network&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Test dengan Dataset Kecil&lt;/strong&gt;: Selalu validasi pendekatan dengan subset data terlebih dahulu&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Backup adalah Prioritas&lt;/strong&gt;: Pastikan memiliki backup sebelum melakukan migrasi besar&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Network Matters&lt;/strong&gt;: Bandwidth dan latency berdampak signifikan terhadap performa&lt;/li&gt;
&lt;/ol&gt;

&lt;h2 id=&quot;kesimpulan&quot;&gt;Kesimpulan&lt;/h2&gt;

&lt;p&gt;Rclone terbukti merupakan tool yang powerful untuk sinkronisasi data antar cloud provider. Meskipun managed solutions menyediakan integrasi yang lebih baik dan operational overhead yang lebih rendah, rclone memberikan kontrol yang lebih besar dan dapat menjadi pilihan yang lebih ekonomis untuk dataset berukuran besar.&lt;/p&gt;

&lt;p&gt;Kunci utamanya adalah memahami kebutuhan spesifik:&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Untuk migrasi one-time dengan constraint biaya: rclone dapat menjadi pilihan ideal&lt;/li&gt;
  &lt;li&gt;Untuk production workloads yang berkelanjutan: managed solutions mungkin pilihan yang lebih baik&lt;/li&gt;
  &lt;li&gt;Untuk skenario multi-cloud yang kompleks: fleksibilitas rclone sangat bermanfaat&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Seperti biasa, lakukan testing secara menyeluruh sebelum deployment production. Dan ingat, dengan power yang besar datang tanggung jawab yang besar pula - pengaturan rclone yang agresif dapat dengan mudah membebani sistem jika tidak dikonfigurasi dengan tepat.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Panduan Migrasi Cloud: Dari Perencanaan hingga Eksekusi</title>
   <link href="https://robee.id/2025/05/01/panduan-praktis-migrasi-cloud"/>
   <updated>2025-05-01T09:00:00+07:00</updated>
   <id>https://robee.id/2025/05/01/panduan-praktis-migrasi-cloud</id>
   <content type="html">&lt;p&gt;&lt;img src=&quot;https://images.unsplash.com/photo-1580674285054-bed31e145f59?q=80&amp;amp;w=2340&amp;amp;auto=format&amp;amp;fit=crop&amp;amp;ixlib=rb-4.1.0&amp;amp;ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&quot; alt=&quot;Cloud Migration&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Migrasi cloud bukanlah sekadar memindahkan server dari satu tempat ke tempat lain. Ini adalah proses kompleks yang memerlukan perencanaan matang, eksekusi yang tepat, dan monitoring berkelanjutan. Setelah mengalami berbagai skenario migrasi, dari startup hingga enterprise scale, artikel ini menyajikan panduan praktis berdasarkan pengalaman riil tanpa embel-embel marketing atau janji-janji muluk.&lt;/p&gt;

&lt;p&gt;Realitas migrasi cloud: 70% project melebihi timeline, 60% melebihi budget, dan 40% mengalami performance issues post-migration. Bukan untuk menakut-nakuti, tapi untuk mempersiapkan ekspektasi yang realistis.&lt;/p&gt;

&lt;h2 id=&quot;engineering-challenges-dan-pre-migration-issues&quot;&gt;Engineering Challenges dan Pre-Migration Issues&lt;/h2&gt;

&lt;h3 id=&quot;kondisi-yang-sering-terjadi-dan-harus-diperbaiki&quot;&gt;Kondisi yang Sering Terjadi dan Harus Diperbaiki&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Performance Issues yang Existing:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Jangan pernah migrate aplikasi yang sudah bermasalah performance. Cloud bukan magic bullet yang akan menyelesaikan fundamental performance issues. Sebaliknya, network latency dan shared resources di cloud bisa memperparah masalah yang sudah ada.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Database Performance Problems:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Slow queries yang akan menjadi bottleneck di cloud karena network latency tambahan&lt;/li&gt;
  &lt;li&gt;Missing indexes pada large tables yang akan memperlambat migration&lt;/li&gt;
  &lt;li&gt;Inefficient queries dengan high examination-to-sent ratio (N+1 query problems)&lt;/li&gt;
  &lt;li&gt;Unbounded result sets yang akan menghabiskan memory di cloud environment&lt;/li&gt;
  &lt;li&gt;Lock contention issues yang akan diperparah dengan distributed systems&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Application Architecture Problems:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Synchronous database calls dalam loop operations (N+1 query anti-pattern)&lt;/li&gt;
  &lt;li&gt;Blocking I/O operations tanpa timeout handling yang akan menyebabkan timeout di cloud&lt;/li&gt;
  &lt;li&gt;Hardcoded connection strings dan network dependencies&lt;/li&gt;
  &lt;li&gt;Monolithic services yang tidak dapat di-scale independently&lt;/li&gt;
  &lt;li&gt;Lack of circuit breakers dan retry mechanisms untuk network resilience&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;structural-problems-yang-mempersulit-migration&quot;&gt;Structural Problems yang Mempersulit Migration&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;1. Monolithic Architecture dengan Tight Coupling&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Common Issues:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;God classes dengan 50+ methods yang menghandle multiple responsibilities&lt;/li&gt;
  &lt;li&gt;Hardcoded dependencies dengan internal IP addresses dan local hostnames&lt;/li&gt;
  &lt;li&gt;Single deployment unit yang memerlukan restart entire application untuk changes&lt;/li&gt;
  &lt;li&gt;Shared databases dengan tight schema coupling antar modules&lt;/li&gt;
  &lt;li&gt;No clear service boundaries yang membuat decomposition sulit&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Problems:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Tidak bisa di-scale secara individual&lt;/li&gt;
  &lt;li&gt;Single point of failure&lt;/li&gt;
  &lt;li&gt;Deployment risks tinggi&lt;/li&gt;
  &lt;li&gt;Resource requirements massive&lt;/li&gt;
  &lt;li&gt;Testing complexity extreme&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Solution Strategy:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Decompose berdasarkan business capabilities dan data ownership&lt;/li&gt;
  &lt;li&gt;Implement dependency injection untuk loose coupling&lt;/li&gt;
  &lt;li&gt;Extract shared functionality ke separate services&lt;/li&gt;
  &lt;li&gt;Use event-driven architecture untuk service communication&lt;/li&gt;
  &lt;li&gt;Implement proper service discovery dan configuration management&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;2. Database Issues yang Critical&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Massive Database Tables:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Tables dengan billions of records tanpa partitioning (contoh: audit logs dengan 50+ billion records)&lt;/li&gt;
  &lt;li&gt;Migration time bisa 6-8 weeks untuk single table saja&lt;/li&gt;
  &lt;li&gt;Tidak ada archiving strategy untuk historical data&lt;/li&gt;
  &lt;li&gt;Single-threaded backup/restore processes yang tidak efficient&lt;/li&gt;
  &lt;li&gt;Storage requirements yang massive tanpa compression&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Solution Strategy:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Implement table partitioning berdasarkan date ranges sebelum migration&lt;/li&gt;
  &lt;li&gt;Create archiving strategy untuk old data ke cold storage&lt;/li&gt;
  &lt;li&gt;Use parallel migration tools dan techniques&lt;/li&gt;
  &lt;li&gt;Implement data compression untuk reduce storage requirements&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Schema Design Problems:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;EAV (Entity-Attribute-Value) patterns yang membuat queries complex dan slow&lt;/li&gt;
  &lt;li&gt;Lack of proper normalization menyebabkan data redundancy&lt;/li&gt;
  &lt;li&gt;No foreign key constraints yang menyebabkan data integrity issues&lt;/li&gt;
  &lt;li&gt;Over-normalized schemas dengan excessive joins&lt;/li&gt;
  &lt;li&gt;BLOB/TEXT fields dalam transactional tables&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Solution Strategy:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Normalize EAV structures ke proper relational schema&lt;/li&gt;
  &lt;li&gt;Separate transactional data dari analytical data&lt;/li&gt;
  &lt;li&gt;Implement proper indexing strategies untuk cloud database&lt;/li&gt;
  &lt;li&gt;Move large objects ke object storage (S3, Blob Storage, Cloud Storage)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;3. File System Dependencies&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Common Issues:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Hardcoded file paths yang tidak portable (/var/www/uploads, /tmp/processing)&lt;/li&gt;
  &lt;li&gt;Local file processing yang tidak scalable&lt;/li&gt;
  &lt;li&gt;Single-server storage dengan no redundancy&lt;/li&gt;
  &lt;li&gt;Synchronous file operations yang blocking&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Solution Strategy:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Migrate file storage ke object storage (S3, Azure Blob, GCS)&lt;/li&gt;
  &lt;li&gt;Implement async file processing dengan queue systems&lt;/li&gt;
  &lt;li&gt;Use CDN untuk file delivery dan caching&lt;/li&gt;
  &lt;li&gt;Implement proper error handling dan retry mechanisms untuk file operations&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;legacy-technology-stack-issues&quot;&gt;Legacy Technology Stack Issues&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;4. Outdated Dependencies dan Security Vulnerabilities&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Common Issues:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;End-of-life operating systems dan base images (Ubuntu 14.04, CentOS 6, RHEL 6)&lt;/li&gt;
  &lt;li&gt;Deprecated runtime versions (Python 2.7, Node.js 0.x, Java 8)&lt;/li&gt;
  &lt;li&gt;Libraries dengan known security vulnerabilities&lt;/li&gt;
  &lt;li&gt;Incompatible dependency versions yang conflict&lt;/li&gt;
  &lt;li&gt;No automated security scanning atau dependency updates&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Impact pada Migration:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Cloud providers mungkin tidak support deprecated versions&lt;/li&gt;
  &lt;li&gt;Security compliance issues untuk cloud environments&lt;/li&gt;
  &lt;li&gt;Performance degradation dengan old libraries&lt;/li&gt;
  &lt;li&gt;Compatibility issues dengan cloud-native services&lt;/li&gt;
  &lt;li&gt;Increased attack surface&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Solution Strategy:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Upgrade ke supported LTS versions sebelum migration&lt;/li&gt;
  &lt;li&gt;Implement automated security scanning dalam CI/CD pipeline&lt;/li&gt;
  &lt;li&gt;Use dependency management tools untuk version compatibility&lt;/li&gt;
  &lt;li&gt;Plan incremental upgrades dengan proper testing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;5. Configuration Management Chaos&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Common Issues:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Configuration files scattered across multiple locations&lt;/li&gt;
  &lt;li&gt;Hardcoded environment-specific values dalam source code&lt;/li&gt;
  &lt;li&gt;Sensitive credentials stored dalam plain text files&lt;/li&gt;
  &lt;li&gt;No centralized configuration management&lt;/li&gt;
  &lt;li&gt;Environment detection berdasarkan hostname atau file paths&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Impact pada Migration:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Tidak bisa deploy same artifact ke multiple environments&lt;/li&gt;
  &lt;li&gt;Configuration drift antar environments&lt;/li&gt;
  &lt;li&gt;Security risks dengan exposed credentials&lt;/li&gt;
  &lt;li&gt;Difficult troubleshooting dan environment parity issues&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Solution Strategy:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Externalize configuration menggunakan environment variables&lt;/li&gt;
  &lt;li&gt;Use cloud-native config services (Parameter Store, Key Vault, Secret Manager)&lt;/li&gt;
  &lt;li&gt;Implement configuration validation dan type safety&lt;/li&gt;
  &lt;li&gt;Separate sensitive data dari application configuration&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;network-dependencies-dan-infrastructure-coupling&quot;&gt;Network Dependencies dan Infrastructure Coupling&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;6. Network Architecture yang Tidak Cloud-Ready&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Common Issues:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Hardcoded IP addresses dan hostnames dalam application code&lt;/li&gt;
  &lt;li&gt;Assumptions tentang network topology dan latency&lt;/li&gt;
  &lt;li&gt;No timeout handling untuk network calls&lt;/li&gt;
  &lt;li&gt;Missing retry logic dan circuit breaker patterns&lt;/li&gt;
  &lt;li&gt;Dependencies pada local network resources (printers, legacy services)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Impact pada Migration:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Network calls yang reliable di LAN menjadi unreliable di cloud&lt;/li&gt;
  &lt;li&gt;Application timeouts dan hanging processes&lt;/li&gt;
  &lt;li&gt;Cascade failures ketika dependencies unavailable&lt;/li&gt;
  &lt;li&gt;No graceful degradation untuk network issues&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Solution Strategy:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Implement service discovery mechanisms&lt;/li&gt;
  &lt;li&gt;Add timeout dan retry logic untuk all network calls&lt;/li&gt;
  &lt;li&gt;Use circuit breaker patterns untuk fault tolerance&lt;/li&gt;
  &lt;li&gt;Replace local dependencies dengan cloud-native alternatives&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;performance-anti-patterns&quot;&gt;Performance Anti-Patterns&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;7. Memory dan Resource Management Issues&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Common Issues:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Unbounded caches yang grow forever tanpa eviction policy&lt;/li&gt;
  &lt;li&gt;Loading large datasets ke memory tanpa pagination&lt;/li&gt;
  &lt;li&gt;Resource leaks (connections, file handles, threads)&lt;/li&gt;
  &lt;li&gt;No connection pooling atau resource management&lt;/li&gt;
  &lt;li&gt;Memory-intensive operations tanpa streaming approaches&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Impact pada Migration:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Out of memory errors lebih frequent di cloud dengan resource limits&lt;/li&gt;
  &lt;li&gt;Higher costs karena over-provisioning memory&lt;/li&gt;
  &lt;li&gt;Application instability dan frequent restarts&lt;/li&gt;
  &lt;li&gt;Poor resource utilization dan inefficient scaling&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Solution Strategy:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Implement bounded caches dengan TTL dan size limits&lt;/li&gt;
  &lt;li&gt;Use streaming dan pagination untuk large datasets&lt;/li&gt;
  &lt;li&gt;Proper resource management dengan try-with-resources patterns&lt;/li&gt;
  &lt;li&gt;Implement connection pooling dan resource monitoring&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;pre-migration-remediation-strategy&quot;&gt;Pre-Migration Remediation Strategy&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Assessment Framework:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Key Assessment Areas:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Performance bottlenecks dan slow queries analysis&lt;/li&gt;
  &lt;li&gt;Architecture patterns dan anti-patterns identification&lt;/li&gt;
  &lt;li&gt;Security vulnerabilities dan compliance gaps&lt;/li&gt;
  &lt;li&gt;Configuration management practices&lt;/li&gt;
  &lt;li&gt;Resource utilization dan memory management&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Migration Readiness Scoring:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Critical issues: -20 points each&lt;/li&gt;
  &lt;li&gt;Warning issues: -5 points each&lt;/li&gt;
  &lt;li&gt;Base score: 100 points&lt;/li&gt;
  &lt;li&gt;Final score range: 0-100&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Migration Go/No-Go Criteria:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Critical Blockers (Must Fix):&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Performance degradation over 50% dari baseline&lt;/li&gt;
  &lt;li&gt;High-severity security vulnerabilities&lt;/li&gt;
  &lt;li&gt;Database tables over 100GB tanpa partitioning&lt;/li&gt;
  &lt;li&gt;Hardcoded network dependencies&lt;/li&gt;
  &lt;li&gt;Memory leaks dalam core services&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Must Fix Before Migration:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Slow queries over 30 seconds execution time&lt;/li&gt;
  &lt;li&gt;Unbounded cache implementations&lt;/li&gt;
  &lt;li&gt;Synchronous blocking I/O operations&lt;/li&gt;
  &lt;li&gt;Missing health check endpoints&lt;/li&gt;
  &lt;li&gt;Configuration tidak externalized&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Recommended Improvements:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Circuit breaker implementations&lt;/li&gt;
  &lt;li&gt;Structured logging&lt;/li&gt;
  &lt;li&gt;Graceful shutdown mechanisms&lt;/li&gt;
  &lt;li&gt;Metrics collection&lt;/li&gt;
  &lt;li&gt;Application containerization&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Migration Decision Matrix:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Score 90-100: Ready untuk immediate migration&lt;/li&gt;
  &lt;li&gt;Score 70-89: Fix warnings first, then migrate&lt;/li&gt;
  &lt;li&gt;Score 50-69: Address critical issues sebelum migration&lt;/li&gt;
  &lt;li&gt;Score &amp;lt;50: Major refactoring required sebelum migration&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;downtime-management-strategy&quot;&gt;Downtime Management Strategy&lt;/h2&gt;

&lt;h3 id=&quot;kategori-downtime-dan-mitigation&quot;&gt;Kategori Downtime dan Mitigation&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;1. Zero-Downtime Migration&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Aplikasi&lt;/strong&gt;: Stateless applications dengan load balancer&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Database&lt;/strong&gt;: Read replicas dengan gradual traffic shifting&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Strategy&lt;/strong&gt;: Blue-green deployment, rolling updates&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: Real-time cutover dalam hitungan menit&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk&lt;/strong&gt;: Low, tapi memerlukan preparation extensive&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;2. Minimal Downtime (&amp;lt; 4 jam)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Aplikasi&lt;/strong&gt;: Applications dengan session state&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Database&lt;/strong&gt;: Medium-sized databases dengan replication&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Strategy&lt;/strong&gt;: Maintenance window dengan quick cutover&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: 1-4 jam maintenance window&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk&lt;/strong&gt;: Medium, memerlukan thorough testing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;3. Planned Downtime (4-24 jam)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Aplikasi&lt;/strong&gt;: Legacy monoliths dengan complex dependencies&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Database&lt;/strong&gt;: Large databases tanpa real-time replication&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Strategy&lt;/strong&gt;: Weekend maintenance window&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: Extended maintenance period&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk&lt;/strong&gt;: High, significant business impact&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;4. Extended Downtime (&amp;gt; 24 jam)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Aplikasi&lt;/strong&gt;: Major architecture changes, data migration&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Database&lt;/strong&gt;: Massive databases, schema changes&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Strategy&lt;/strong&gt;: Phased migration dengan temporary solutions&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: Days to weeks&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk&lt;/strong&gt;: Very high, business continuity threatened&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;downtime-minimization-techniques&quot;&gt;Downtime Minimization Techniques&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Database Migration Strategies:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Online Migration:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Master-slave replication dengan lag monitoring&lt;/li&gt;
  &lt;li&gt;Database triggers untuk bidirectional sync&lt;/li&gt;
  &lt;li&gt;Read traffic routing ke cloud database gradually&lt;/li&gt;
  &lt;li&gt;Write traffic cutover setelah full sync achieved&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Application Migration Strategies:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Traffic Shifting:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;DNS-based traffic routing dengan TTL management&lt;/li&gt;
  &lt;li&gt;Load balancer weight adjustments (10%, 25%, 50%, 100%)&lt;/li&gt;
  &lt;li&gt;Feature flags untuk gradual functionality migration&lt;/li&gt;
  &lt;li&gt;Circuit breakers untuk automatic fallback&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Session Management:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Sticky session routing selama migration period&lt;/li&gt;
  &lt;li&gt;Session store migration ke shared storage (Redis/database)&lt;/li&gt;
  &lt;li&gt;Session drainage techniques untuk clean cutover&lt;/li&gt;
  &lt;li&gt;User notification dan graceful logout procedures&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;communication-management&quot;&gt;Communication Management&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Pre-Migration Communication (2-4 weeks before):&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Stakeholder notification dengan detailed timeline&lt;/li&gt;
  &lt;li&gt;User communication tentang planned maintenance&lt;/li&gt;
  &lt;li&gt;Service dependency mapping dan coordination&lt;/li&gt;
  &lt;li&gt;Rollback procedures dan decision criteria&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;During Migration Communication:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Real-time status updates via multiple channels&lt;/li&gt;
  &lt;li&gt;Escalation procedures untuk critical issues&lt;/li&gt;
  &lt;li&gt;Go/no-go decision points dengan clear criteria&lt;/li&gt;
  &lt;li&gt;Technical dan business stakeholder alignment&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Post-Migration Communication:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Success confirmation dan performance validation&lt;/li&gt;
  &lt;li&gt;Issue resolution dan lessons learned&lt;/li&gt;
  &lt;li&gt;User feedback collection dan resolution&lt;/li&gt;
  &lt;li&gt;Documentation updates dan knowledge transfer&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;business-continuity-planning&quot;&gt;Business Continuity Planning&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Critical Service Identification:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Revenue-generating applications (priority 1)&lt;/li&gt;
  &lt;li&gt;Customer-facing services (priority 2)&lt;/li&gt;
  &lt;li&gt;Internal operational tools (priority 3)&lt;/li&gt;
  &lt;li&gt;Reporting dan analytics (priority 4)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Failover Procedures:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Automatic failover mechanisms dengan health checks&lt;/li&gt;
  &lt;li&gt;Manual failover procedures dengan clear documentation&lt;/li&gt;
  &lt;li&gt;Data consistency validation post-failover&lt;/li&gt;
  &lt;li&gt;Service dependency startup sequences&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Recovery Time Objectives:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;RTO targets berdasarkan business criticality&lt;/li&gt;
  &lt;li&gt;Recovery procedures testing dan validation&lt;/li&gt;
  &lt;li&gt;Backup restoration procedures&lt;/li&gt;
  &lt;li&gt;Data integrity verification processes&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;risk-mitigation&quot;&gt;Risk Mitigation&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Pre-Migration Testing:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Full end-to-end testing dalam staging environment&lt;/li&gt;
  &lt;li&gt;Load testing dengan production-like traffic&lt;/li&gt;
  &lt;li&gt;Disaster recovery testing dengan rollback scenarios&lt;/li&gt;
  &lt;li&gt;User acceptance testing dengan business stakeholders&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;During Migration Monitoring:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Real-time performance monitoring dengan alerts&lt;/li&gt;
  &lt;li&gt;Business metrics tracking (transactions, revenue)&lt;/li&gt;
  &lt;li&gt;User experience monitoring dengan synthetic tests&lt;/li&gt;
  &lt;li&gt;Error rate monitoring dengan automatic rollback triggers&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Rollback Criteria dan Procedures:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Performance degradation &amp;gt; 25% dari baseline&lt;/li&gt;
  &lt;li&gt;Error rate increase &amp;gt; 5% dari normal levels&lt;/li&gt;
  &lt;li&gt;Business metric impact &amp;gt; acceptable thresholds&lt;/li&gt;
  &lt;li&gt;Critical functionality unavailable &amp;gt; defined time limits&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;stakeholder-management&quot;&gt;Stakeholder Management&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Executive Communication:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;High-level status updates dengan business impact&lt;/li&gt;
  &lt;li&gt;Risk assessment dan mitigation strategies&lt;/li&gt;
  &lt;li&gt;Budget impact dan resource requirements&lt;/li&gt;
  &lt;li&gt;Success metrics dan validation criteria&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Technical Team Coordination:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Cross-team communication channels (Slack, Teams)&lt;/li&gt;
  &lt;li&gt;Shared dashboards untuk real-time visibility&lt;/li&gt;
  &lt;li&gt;Decision-making protocols dengan clear authority&lt;/li&gt;
  &lt;li&gt;Resource allocation dan on-call procedures&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;User Support:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Help desk preparation dengan FAQ updates&lt;/li&gt;
  &lt;li&gt;User training materials untuk new environment&lt;/li&gt;
  &lt;li&gt;Support ticket prioritization during migration&lt;/li&gt;
  &lt;li&gt;User feedback mechanisms dan issue tracking&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;fase-perencanaan&quot;&gt;Fase Perencanaan&lt;/h2&gt;

&lt;h3 id=&quot;1-inventory-dan-assessment&quot;&gt;1. Inventory dan Assessment&lt;/h3&gt;

&lt;p&gt;Tahap ini adalah foundation dari seluruh project. Tidak ada yang lebih berbahaya daripada surprises di tengah migration. Discovery process yang incomplete akan menjadi bumerang di kemudian hari.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Yang Harus Dilakukan Secara Detail:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Application Discovery:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Inventarisasi semua aplikasi beserta versi, dependencies, dan configuration&lt;/li&gt;
  &lt;li&gt;Identifikasi service accounts dan authentication mechanisms&lt;/li&gt;
  &lt;li&gt;Mapping data flows antar aplikasi&lt;/li&gt;
  &lt;li&gt;Dokumentasi batch jobs dan scheduled tasks&lt;/li&gt;
  &lt;li&gt;Cataloging third-party integrations dan APIs&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Infrastructure Mapping:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Current server specifications (CPU, memory, storage, network)&lt;/li&gt;
  &lt;li&gt;Operating system versions dan patch levels&lt;/li&gt;
  &lt;li&gt;Database systems dan storage requirements&lt;/li&gt;
  &lt;li&gt;Network topology, firewall rules, dan load balancers&lt;/li&gt;
  &lt;li&gt;Backup systems dan disaster recovery procedures&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Compliance dan Security Assessment:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Data classification (public, internal, confidential, restricted)&lt;/li&gt;
  &lt;li&gt;Regulatory requirements (GDPR, HIPAA, SOX, PCI-DSS)&lt;/li&gt;
  &lt;li&gt;Current security controls dan audit requirements&lt;/li&gt;
  &lt;li&gt;Encryption standards dan key management&lt;/li&gt;
  &lt;li&gt;Access control policies dan privileged accounts&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Performance Baseline:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;CPU utilization patterns (peak dan average)&lt;/li&gt;
  &lt;li&gt;Memory consumption trends&lt;/li&gt;
  &lt;li&gt;Storage IOPS dan throughput requirements&lt;/li&gt;
  &lt;li&gt;Network bandwidth utilization&lt;/li&gt;
  &lt;li&gt;Application response times dan throughput&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Tools untuk Discovery (Multi-Cloud):&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AWS:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# AWS Application Discovery Service&lt;/span&gt;
aws discovery start-data-collection-by-agent-ids &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--agent-ids&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;agent-1&quot;&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;agent-2&quot;&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# AWS Config untuk compliance scanning&lt;/span&gt;
aws configservice get-compliance-details-by-config-rule &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--config-rule-name&lt;/span&gt; required-tags
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Azure Migrate assessment&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzMigrateProject&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-Assessment&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ResourceGroupName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-RG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Location&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;East US&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Azure Security Center assessment&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Get-AzSecurityAssessment&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Where-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Status&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-eq&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Unhealthy&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Google Cloud:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Cloud Asset Inventory&lt;/span&gt;
gcloud asset search-all-resources &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--scope&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;projects/PROJECT_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--asset-types&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;compute.googleapis.com/Instance

&lt;span class=&quot;c&quot;&gt;# Security Command Center findings&lt;/span&gt;
gcloud scc findings list organizations/ORG_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--filter&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;state=&lt;/span&gt;&lt;span class=&quot;se&quot;&gt;\&quot;&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;ACTIVE&lt;/span&gt;&lt;span class=&quot;se&quot;&gt;\&quot;&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Output yang Harus Dihasilkan:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Application Portfolio Matrix&lt;/strong&gt;: Business criticality vs Technical complexity&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Dependency Diagram&lt;/strong&gt;: Visual representation dari application dependencies&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Resource Sizing Report&lt;/strong&gt;: Current vs recommended cloud instance types&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Compliance Gap Analysis&lt;/strong&gt;: Delta antara current state dan cloud requirements&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Cost Model&lt;/strong&gt;: TCO comparison antara current state dan cloud options&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk Assessment&lt;/strong&gt;: Technical, business, dan security risks&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;2-strategi-migrasi&quot;&gt;2. Strategi Migrasi&lt;/h3&gt;

&lt;p&gt;Pemilihan strategi migrasi bukan hanya tentang technical feasibility, tapi juga business priority, budget constraint, dan risk tolerance. Setiap pendekatan memiliki trade-off yang harus dipahami secara mendalam.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;6R Strategy Framework (Gartner):&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Rehost (Lift and Shift)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Karakteristik&lt;/strong&gt;: Move aplikasi tanpa perubahan significant&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: 2-6 bulan untuk most applications&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Cost Impact&lt;/strong&gt;: 10-30% savings immediate, limited long-term optimization&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk Level&lt;/strong&gt;: Low to Medium&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Effort Required&lt;/strong&gt;: Minimal development work&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Cocok untuk&lt;/strong&gt;:
    &lt;ul&gt;
      &lt;li&gt;Legacy applications dengan tight coupling&lt;/li&gt;
      &lt;li&gt;Applications dengan vendor support constraints&lt;/li&gt;
      &lt;li&gt;Quick wins untuk cost reduction&lt;/li&gt;
      &lt;li&gt;Proof of concept migrations&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Contoh Implementation:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# AWS: EC2 instance migration&lt;/span&gt;
aws ec2 run-instances &lt;span class=&quot;nt&quot;&gt;--image-id&lt;/span&gt; ami-12345678 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--instance-type&lt;/span&gt; m5.large &lt;span class=&quot;nt&quot;&gt;--key-name&lt;/span&gt; migration-key

&lt;span class=&quot;c&quot;&gt;# Azure: VM migration&lt;/span&gt;
az vm create &lt;span class=&quot;nt&quot;&gt;--resource-group&lt;/span&gt; MigrationRG &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt; AppServer01 &lt;span class=&quot;nt&quot;&gt;--image&lt;/span&gt; UbuntuLTS

&lt;span class=&quot;c&quot;&gt;# GCP: Compute Engine migration&lt;/span&gt;
gcloud compute instances create app-server-01 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--machine-type&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;n1-standard-2 &lt;span class=&quot;nt&quot;&gt;--image-family&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;ubuntu-1804-lts
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;2. Replatform (Lift, Tinker, and Shift)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Karakteristik&lt;/strong&gt;: Minimal changes untuk leverage cloud capabilities&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: 3-8 bulan&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Cost Impact&lt;/strong&gt;: 20-40% savings dengan better scalability&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk Level&lt;/strong&gt;: Medium&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Effort Required&lt;/strong&gt;: Configuration changes, minor code modifications&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Contoh Changes&lt;/strong&gt;:
    &lt;ul&gt;
      &lt;li&gt;Database ke managed services (RDS, Cloud SQL, Azure Database)&lt;/li&gt;
      &lt;li&gt;Load balancers ke cloud-native (ALB, Azure Load Balancer)&lt;/li&gt;
      &lt;li&gt;File storage ke object storage (S3, Blob Storage, Cloud Storage)&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Database Replatform Examples:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# AWS RDS migration&lt;/span&gt;
aws rds create-db-instance &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--db-instance-identifier&lt;/span&gt; myapp-db &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--db-instance-class&lt;/span&gt; db.t3.medium &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--engine&lt;/span&gt; mysql &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--allocated-storage&lt;/span&gt; 100

&lt;span class=&quot;c&quot;&gt;# Azure Database for MySQL&lt;/span&gt;
az mysql server create &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--resource-group&lt;/span&gt; MigrationRG &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt; myapp-mysql-server &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--sku-name&lt;/span&gt; GP_Gen5_2

&lt;span class=&quot;c&quot;&gt;# Google Cloud SQL&lt;/span&gt;
gcloud sql instances create myapp-mysql &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--database-version&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;MYSQL_8_0 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--tier&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;db-n1-standard-2
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;3. Repurchase (Drop and Shop)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Karakteristik&lt;/strong&gt;: Move ke SaaS solution&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: 6-12 bulan (including data migration dan training)&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Cost Impact&lt;/strong&gt;: Variable, often OpEx vs CapEx shift&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk Level&lt;/strong&gt;: Medium to High&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Contoh&lt;/strong&gt;: On-premise email ke Office 365, Custom CRM ke Salesforce&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;4. Refactor/Re-architect&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Karakteristik&lt;/strong&gt;: Redesign aplikasi untuk cloud-native&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: 12-24 bulan&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Cost Impact&lt;/strong&gt;: 40-70% optimization potential&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk Level&lt;/strong&gt;: High&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Effort Required&lt;/strong&gt;: Significant development work&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Technologies&lt;/strong&gt;: Microservices, containers, serverless&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Cloud-Native Architecture Examples:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c1&quot;&gt;# Kubernetes deployment&lt;/span&gt;
&lt;span class=&quot;na&quot;&gt;apiVersion&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;apps/v1&lt;/span&gt;
&lt;span class=&quot;na&quot;&gt;kind&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Deployment&lt;/span&gt;
&lt;span class=&quot;na&quot;&gt;metadata&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;app-deployment&lt;/span&gt;
&lt;span class=&quot;na&quot;&gt;spec&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;replicas&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;m&quot;&gt;3&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;selector&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;matchLabels&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;app&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;myapp&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;template&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;metadata&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;labels&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;app&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;myapp&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;spec&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;containers&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;myapp&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;image&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;myapp:v1.0&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;ports&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;containerPort&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;m&quot;&gt;8080&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;5. Retire&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Karakteristik&lt;/strong&gt;: Shutdown applications yang tidak longer needed&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: 1-3 bulan&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Cost Impact&lt;/strong&gt;: 100% elimination&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk Level&lt;/strong&gt;: Low to Medium&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Requirements&lt;/strong&gt;: Thorough dependency analysis dan user notification&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;6. Retain&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Karakteristik&lt;/strong&gt;: Keep applications on-premise&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Reasons&lt;/strong&gt;: Compliance, latency, cost, complexity&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Review Period&lt;/strong&gt;: Annual assessment untuk future migration&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Decision Matrix untuk Strategy Selection:&lt;/strong&gt;&lt;/p&gt;

&lt;table&gt;
  &lt;thead&gt;
    &lt;tr&gt;
      &lt;th&gt;Criteria&lt;/th&gt;
      &lt;th&gt;Rehost&lt;/th&gt;
      &lt;th&gt;Replatform&lt;/th&gt;
      &lt;th&gt;Refactor&lt;/th&gt;
      &lt;th&gt;Repurchase&lt;/th&gt;
      &lt;th&gt;Retire&lt;/th&gt;
    &lt;/tr&gt;
  &lt;/thead&gt;
  &lt;tbody&gt;
    &lt;tr&gt;
      &lt;td&gt;Speed&lt;/td&gt;
      &lt;td&gt;Fast&lt;/td&gt;
      &lt;td&gt;Medium&lt;/td&gt;
      &lt;td&gt;Slow&lt;/td&gt;
      &lt;td&gt;Medium&lt;/td&gt;
      &lt;td&gt;Fast&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Cost Optimization&lt;/td&gt;
      &lt;td&gt;Low&lt;/td&gt;
      &lt;td&gt;Medium&lt;/td&gt;
      &lt;td&gt;High&lt;/td&gt;
      &lt;td&gt;Variable&lt;/td&gt;
      &lt;td&gt;Highest&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Risk&lt;/td&gt;
      &lt;td&gt;Low&lt;/td&gt;
      &lt;td&gt;Medium&lt;/td&gt;
      &lt;td&gt;High&lt;/td&gt;
      &lt;td&gt;Medium&lt;/td&gt;
      &lt;td&gt;Low&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Cloud Benefits&lt;/td&gt;
      &lt;td&gt;Minimal&lt;/td&gt;
      &lt;td&gt;Partial&lt;/td&gt;
      &lt;td&gt;Full&lt;/td&gt;
      &lt;td&gt;Full&lt;/td&gt;
      &lt;td&gt;N/A&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Effort Required&lt;/td&gt;
      &lt;td&gt;Low&lt;/td&gt;
      &lt;td&gt;Medium&lt;/td&gt;
      &lt;td&gt;High&lt;/td&gt;
      &lt;td&gt;Medium&lt;/td&gt;
      &lt;td&gt;Low&lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;

&lt;h3 id=&quot;3-timeline-dan-phasing&quot;&gt;3. Timeline dan Phasing&lt;/h3&gt;

&lt;p&gt;Migration yang sukses memerlukan pendekatan bertahap. Big bang migration adalah resep disaster. Phasing yang tepat memungkinkan learning dan course correction di setiap wave.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Detailed Wave Planning:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Wave 0: Foundation dan Pilot (Bulan 1-3)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Scope&lt;/strong&gt;: Infrastructure setup, pilot application (1-2 non-critical apps)&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Objectives&lt;/strong&gt;:
    &lt;ul&gt;
      &lt;li&gt;Validate tools dan processes&lt;/li&gt;
      &lt;li&gt;Establish operational procedures&lt;/li&gt;
      &lt;li&gt;Train team dengan cloud environment&lt;/li&gt;
      &lt;li&gt;Test rollback procedures&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Success Criteria&lt;/strong&gt;:
    &lt;ul&gt;
      &lt;li&gt;Pilot apps running dengan &amp;lt; 5% performance degradation&lt;/li&gt;
      &lt;li&gt;All tools functioning properly&lt;/li&gt;
      &lt;li&gt;Team confident dengan procedures&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Example Applications&lt;/strong&gt;: Development environments, internal tools, documentation sites&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Wave 1: Low-Risk Applications (Bulan 4-6)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Scope&lt;/strong&gt;: 10-20% of application portfolio&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Characteristics&lt;/strong&gt;:
    &lt;ul&gt;
      &lt;li&gt;Minimal dependencies&lt;/li&gt;
      &lt;li&gt;Non-customer facing&lt;/li&gt;
      &lt;li&gt;Low compliance requirements&lt;/li&gt;
      &lt;li&gt;Simple architecture&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk Mitigation&lt;/strong&gt;: Extensive testing, parallel running, quick rollback capability&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Examples&lt;/strong&gt;: Internal reporting systems, monitoring tools, HR applications&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Wave 2: Supporting Systems (Bulan 7-12)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Scope&lt;/strong&gt;: 30-40% of remaining applications&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Characteristics&lt;/strong&gt;:
    &lt;ul&gt;
      &lt;li&gt;Some interdependencies&lt;/li&gt;
      &lt;li&gt;Supporting business functions&lt;/li&gt;
      &lt;li&gt;Medium complexity&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Focus Areas&lt;/strong&gt;: Dependency management, data consistency, performance validation&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Examples&lt;/strong&gt;: CRM systems, inventory management, analytics platforms&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Wave 3: Core Business Applications (Bulan 13-18)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Scope&lt;/strong&gt;: 30-35% of remaining applications&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Characteristics&lt;/strong&gt;:
    &lt;ul&gt;
      &lt;li&gt;Customer-facing components&lt;/li&gt;
      &lt;li&gt;Revenue-generating systems&lt;/li&gt;
      &lt;li&gt;High availability requirements&lt;/li&gt;
      &lt;li&gt;Complex integrations&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Extra Precautions&lt;/strong&gt;:
    &lt;ul&gt;
      &lt;li&gt;Extended testing periods&lt;/li&gt;
      &lt;li&gt;Blue-green deployments&lt;/li&gt;
      &lt;li&gt;Real-time monitoring&lt;/li&gt;
      &lt;li&gt;Immediate rollback plans&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Wave 4: Mission-Critical Systems (Bulan 19-24)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Scope&lt;/strong&gt;: 10-15% most critical applications&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Characteristics&lt;/strong&gt;:
    &lt;ul&gt;
      &lt;li&gt;Core business functions&lt;/li&gt;
      &lt;li&gt;Highest security requirements&lt;/li&gt;
      &lt;li&gt;Maximum uptime demands&lt;/li&gt;
      &lt;li&gt;Complex compliance needs&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Special Considerations&lt;/strong&gt;:
    &lt;ul&gt;
      &lt;li&gt;Dedicated migration windows&lt;/li&gt;
      &lt;li&gt;Multiple rehearsals&lt;/li&gt;
      &lt;li&gt;Executive oversight&lt;/li&gt;
      &lt;li&gt;Disaster recovery testing&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Application Categorization Matrix:&lt;/strong&gt;&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;High Business Impact + Low Technical Complexity = Wave 2-3
High Business Impact + High Technical Complexity = Wave 4
Low Business Impact + Low Technical Complexity = Wave 1
Low Business Impact + High Technical Complexity = Wave 1-2 (atau Retire)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Timeline Dependencies:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Critical Path Factors:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Compliance Approvals&lt;/strong&gt;: 2-6 bulan untuk regulated industries&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Vendor Negotiations&lt;/strong&gt;: 1-3 bulan untuk licensing changes&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Network Connectivity&lt;/strong&gt;: 1-4 bulan untuk direct connections&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Team Training&lt;/strong&gt;: 2-3 bulan untuk comprehensive upskilling&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Security Clearances&lt;/strong&gt;: 3-6 bulan untuk government/defense contracts&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Parallel Activities Timeline:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;Month 1-2:  Infrastructure setup + Team training + Pilot planning
Month 3-4:  Pilot execution + Wave 1 planning + Tool refinement
Month 5-6:  Wave 1 execution + Wave 2 planning + Process optimization
Month 7-12: Wave 2 execution + Wave 3 planning + Continuous improvement
...
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h2 id=&quot;struktur-tim-dan-tanggung-jawab&quot;&gt;Struktur Tim dan Tanggung Jawab&lt;/h2&gt;

&lt;h3 id=&quot;migration-team-structure&quot;&gt;Migration Team Structure&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Core Migration Team:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Migration Lead / Solution Architect&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Overall technical leadership dan strategic decisions&lt;/li&gt;
  &lt;li&gt;Cross-cloud architecture design&lt;/li&gt;
  &lt;li&gt;Stakeholder communication dan escalation management&lt;/li&gt;
  &lt;li&gt;Risk assessment dan mitigation planning&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Infrastructure Engineers (2-4 orang)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Cloud environment setup dan configuration&lt;/li&gt;
  &lt;li&gt;Network connectivity dan security implementation&lt;/li&gt;
  &lt;li&gt;Monitoring dan observability setup&lt;/li&gt;
  &lt;li&gt;Infrastructure as Code development&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Application Migration Engineers (3-6 orang)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Application assessment dan migration planning&lt;/li&gt;
  &lt;li&gt;Code modifications untuk cloud compatibility&lt;/li&gt;
  &lt;li&gt;Testing dan validation procedures&lt;/li&gt;
  &lt;li&gt;Performance optimization&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Database Specialists (1-2 orang)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Database migration strategy dan execution&lt;/li&gt;
  &lt;li&gt;Data consistency dan integrity validation&lt;/li&gt;
  &lt;li&gt;Performance tuning dan optimization&lt;/li&gt;
  &lt;li&gt;Backup dan disaster recovery implementation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;DevOps Engineers (2-3 orang)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;CI/CD pipeline migration dan optimization&lt;/li&gt;
  &lt;li&gt;Container orchestration setup&lt;/li&gt;
  &lt;li&gt;Configuration management&lt;/li&gt;
  &lt;li&gt;Release management dan deployment automation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Security Engineer (1-2 orang)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Security controls implementation&lt;/li&gt;
  &lt;li&gt;Compliance validation&lt;/li&gt;
  &lt;li&gt;Identity dan access management&lt;/li&gt;
  &lt;li&gt;Security testing dan vulnerability assessment&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Project Manager&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Timeline coordination dan progress tracking&lt;/li&gt;
  &lt;li&gt;Resource allocation dan dependency management&lt;/li&gt;
  &lt;li&gt;Communication dengan business stakeholders&lt;/li&gt;
  &lt;li&gt;Risk monitoring dan issue escalation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Quality Assurance Engineers (2-3 orang)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Migration testing strategy development&lt;/li&gt;
  &lt;li&gt;Automated testing implementation&lt;/li&gt;
  &lt;li&gt;Performance dan load testing&lt;/li&gt;
  &lt;li&gt;User acceptance testing coordination&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Business Analysts/SMEs (per application)&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Business requirement validation&lt;/li&gt;
  &lt;li&gt;User story definition untuk cloud features&lt;/li&gt;
  &lt;li&gt;Training material development&lt;/li&gt;
  &lt;li&gt;Change management support&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Resource Allocation Model:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Team Composition per Wave:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Wave 0-1&lt;/strong&gt;: 2-3 engineers, 1 architect, 1 project manager, 1 QA&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Wave 2-3&lt;/strong&gt;: 4-6 engineers, 1-2 architects, 1 project manager, 2 QA, business SMEs&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Wave 4&lt;/strong&gt;: 6-8 engineers, 2 architects, 1 project manager, 3 QA, business SMEs, executive sponsor&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Budget Distribution (Typical):&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Preparation (20%)&lt;/strong&gt;: Tools, training, initial setup&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Wave 1 (15%)&lt;/strong&gt;: Pilot dan low-risk applications&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Wave 2 (25%)&lt;/strong&gt;: Supporting systems&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Wave 3 (30%)&lt;/strong&gt;: Core business applications&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Wave 4 (10%)&lt;/strong&gt;: Mission-critical systems&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Risk Mitigation Strategies:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Dependency Management:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create dependency mapping&lt;/span&gt;
dependencies &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt;
  &lt;span class=&quot;s2&quot;&gt;&quot;app_a&quot;&lt;/span&gt;: &lt;span class=&quot;o&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;database_1&quot;&lt;/span&gt;, &lt;span class=&quot;s2&quot;&gt;&quot;api_service&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;]&lt;/span&gt;,
  &lt;span class=&quot;s2&quot;&gt;&quot;app_b&quot;&lt;/span&gt;: &lt;span class=&quot;o&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;app_a&quot;&lt;/span&gt;, &lt;span class=&quot;s2&quot;&gt;&quot;storage_system&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;]&lt;/span&gt;,
  &lt;span class=&quot;s2&quot;&gt;&quot;app_c&quot;&lt;/span&gt;: &lt;span class=&quot;o&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;external_api&quot;&lt;/span&gt;, &lt;span class=&quot;s2&quot;&gt;&quot;message_queue&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;]&lt;/span&gt;
&lt;span class=&quot;o&quot;&gt;}&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# Migration order berdasarkan dependencies&lt;/span&gt;
migration_order &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; topological_sort&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;dependencies&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Rollback Planning:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Wave 1&lt;/strong&gt;: Same-day rollback capability&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Wave 2&lt;/strong&gt;: 24-hour rollback window&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Wave 3&lt;/strong&gt;: 48-hour rollback dengan business approval&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Wave 4&lt;/strong&gt;: 72-hour rollback dengan executive approval&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Communication Schedule:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Daily&lt;/strong&gt;: Engineering standup updates&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Weekly&lt;/strong&gt;: Stakeholder status reports&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Bi-weekly&lt;/strong&gt;: Executive summary dashboards&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Monthly&lt;/strong&gt;: Business review dan course corrections&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;software-engineering-team-responsibilities&quot;&gt;Software Engineering Team Responsibilities&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Backend Development Team:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Pre-Migration Code Audit:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-python highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c1&quot;&gt;# Code audit untuk cloud compatibility
&lt;/span&gt;&lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;audit_application_dependencies&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;():&lt;/span&gt;
    &lt;span class=&quot;s&quot;&gt;&quot;&quot;&quot;Audit semua dependencies untuk cloud compatibility&quot;&quot;&quot;&lt;/span&gt;
    &lt;span class=&quot;n&quot;&gt;dependencies&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;
        &lt;span class=&quot;s&quot;&gt;&quot;database_connections&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
        &lt;span class=&quot;s&quot;&gt;&quot;file_system_access&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; 
        &lt;span class=&quot;s&quot;&gt;&quot;network_dependencies&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
        &lt;span class=&quot;s&quot;&gt;&quot;third_party_integrations&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
        &lt;span class=&quot;s&quot;&gt;&quot;environment_specific_configs&quot;&lt;/span&gt;
    &lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
    
    &lt;span class=&quot;n&quot;&gt;compatibility_issues&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;[]&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;for&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;dep&lt;/span&gt; &lt;span class=&quot;ow&quot;&gt;in&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;dependencies&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;k&quot;&gt;if&lt;/span&gt; &lt;span class=&quot;ow&quot;&gt;not&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;is_cloud_compatible&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;dep&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;):&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;compatibility_issues&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;append&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;({&lt;/span&gt;
                &lt;span class=&quot;s&quot;&gt;&quot;dependency&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;dep&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
                &lt;span class=&quot;s&quot;&gt;&quot;issue&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;analyze_compatibility_issue&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;dep&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;),&lt;/span&gt;
                &lt;span class=&quot;s&quot;&gt;&quot;remediation&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;suggest_remediation&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;dep&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
            &lt;span class=&quot;p&quot;&gt;})&lt;/span&gt;
    
    &lt;span class=&quot;k&quot;&gt;return&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;compatibility_issues&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# Configuration externalization
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;DATABASE_URL&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;os&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;getenv&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&apos;DATABASE_URL&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;&apos;localhost:5432&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;API_KEY&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;os&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;getenv&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&apos;API_KEY&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;&apos;default_key&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;REDIS_HOST&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;os&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;getenv&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&apos;REDIS_HOST&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;&apos;localhost&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Health Check Implementation:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-java highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c1&quot;&gt;// Health check endpoints untuk cloud load balancers&lt;/span&gt;
&lt;span class=&quot;nd&quot;&gt;@RestController&lt;/span&gt;
&lt;span class=&quot;kd&quot;&gt;public&lt;/span&gt; &lt;span class=&quot;kd&quot;&gt;class&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;HealthController&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt;
    
    &lt;span class=&quot;nd&quot;&gt;@Autowired&lt;/span&gt;
    &lt;span class=&quot;kd&quot;&gt;private&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;DatabaseHealthIndicator&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;dbHealth&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;;&lt;/span&gt;
    
    &lt;span class=&quot;nd&quot;&gt;@GetMapping&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&quot;/health&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
    &lt;span class=&quot;kd&quot;&gt;public&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;ResponseEntity&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;Map&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;String&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;String&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;&amp;gt;&amp;gt;&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;health&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;()&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt;
        &lt;span class=&quot;nc&quot;&gt;Map&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;String&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;String&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;&amp;gt;&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;status&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;HashMap&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;&amp;lt;&amp;gt;();&lt;/span&gt;
        
        &lt;span class=&quot;k&quot;&gt;if&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;dbHealth&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;na&quot;&gt;isHealthy&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;())&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;status&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;na&quot;&gt;put&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&quot;database&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;&quot;UP&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;);&lt;/span&gt;
        &lt;span class=&quot;o&quot;&gt;}&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;else&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;status&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;na&quot;&gt;put&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&quot;database&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;&quot;DOWN&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;);&lt;/span&gt;
            &lt;span class=&quot;k&quot;&gt;return&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;ResponseEntity&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;na&quot;&gt;status&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;503&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;).&lt;/span&gt;&lt;span class=&quot;na&quot;&gt;body&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;status&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;);&lt;/span&gt;
        &lt;span class=&quot;o&quot;&gt;}&lt;/span&gt;
        
        &lt;span class=&quot;n&quot;&gt;status&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;na&quot;&gt;put&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&quot;status&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;&quot;UP&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;);&lt;/span&gt;
        &lt;span class=&quot;k&quot;&gt;return&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;ResponseEntity&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;na&quot;&gt;ok&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;status&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;);&lt;/span&gt;
    &lt;span class=&quot;o&quot;&gt;}&lt;/span&gt;
    
    &lt;span class=&quot;nd&quot;&gt;@GetMapping&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&quot;/ready&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
    &lt;span class=&quot;kd&quot;&gt;public&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;ResponseEntity&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;String&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;&amp;gt;&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;readiness&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;()&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt;
        &lt;span class=&quot;k&quot;&gt;if&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;applicationReadyForTraffic&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;())&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt;
            &lt;span class=&quot;k&quot;&gt;return&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;ResponseEntity&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;na&quot;&gt;ok&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&quot;READY&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;);&lt;/span&gt;
        &lt;span class=&quot;o&quot;&gt;}&lt;/span&gt;
        &lt;span class=&quot;k&quot;&gt;return&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;ResponseEntity&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;na&quot;&gt;status&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;503&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;).&lt;/span&gt;&lt;span class=&quot;na&quot;&gt;body&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&quot;NOT_READY&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;);&lt;/span&gt;
    &lt;span class=&quot;o&quot;&gt;}&lt;/span&gt;
&lt;span class=&quot;o&quot;&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Structured Logging:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-python highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;kn&quot;&gt;import&lt;/span&gt; &lt;span class=&quot;nn&quot;&gt;logging&lt;/span&gt;
&lt;span class=&quot;kn&quot;&gt;import&lt;/span&gt; &lt;span class=&quot;nn&quot;&gt;json&lt;/span&gt;
&lt;span class=&quot;kn&quot;&gt;from&lt;/span&gt; &lt;span class=&quot;nn&quot;&gt;datetime&lt;/span&gt; &lt;span class=&quot;kn&quot;&gt;import&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;datetime&lt;/span&gt;

&lt;span class=&quot;k&quot;&gt;class&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;CloudLogger&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;__init__&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;service_name&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;environment&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;):&lt;/span&gt;
        &lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;service_name&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;service_name&lt;/span&gt;
        &lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;environment&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;environment&lt;/span&gt;
        
    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;log_event&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;level&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;message&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;**&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;kwargs&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;):&lt;/span&gt;
        &lt;span class=&quot;n&quot;&gt;log_entry&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
            &lt;span class=&quot;s&quot;&gt;&quot;timestamp&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;datetime&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;utcnow&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;().&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;isoformat&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(),&lt;/span&gt;
            &lt;span class=&quot;s&quot;&gt;&quot;service&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;service_name&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
            &lt;span class=&quot;s&quot;&gt;&quot;environment&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;environment&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
            &lt;span class=&quot;s&quot;&gt;&quot;level&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;level&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
            &lt;span class=&quot;s&quot;&gt;&quot;message&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;message&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
            &lt;span class=&quot;s&quot;&gt;&quot;correlation_id&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;kwargs&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;get&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&apos;correlation_id&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;),&lt;/span&gt;
            &lt;span class=&quot;s&quot;&gt;&quot;additional_data&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;kwargs&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;
        
        &lt;span class=&quot;n&quot;&gt;logging&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;info&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;json&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;dumps&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;log_entry&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;))&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Frontend Development Team:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;CDN Integration:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-javascript highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c1&quot;&gt;// Multi-cloud CDN configuration&lt;/span&gt;
&lt;span class=&quot;kd&quot;&gt;const&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;CloudAssetManager&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;cdnConfig&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;aws&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;https://cloudfront-domain.amazonaws.com&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;azure&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;https://azure-cdn-endpoint.azureedge.net&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;gcp&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;https://storage.googleapis.com/cdn-bucket&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;
    &lt;span class=&quot;p&quot;&gt;},&lt;/span&gt;
    
    &lt;span class=&quot;na&quot;&gt;getAssetUrl&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;kd&quot;&gt;function&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;assetPath&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;provider&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;aws&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
        &lt;span class=&quot;kd&quot;&gt;const&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;baseUrl&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;this&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;cdnConfig&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;provider&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;];&lt;/span&gt;
        &lt;span class=&quot;k&quot;&gt;return&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;`&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;${&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;baseUrl&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;${&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;assetPath&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;`&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt;
    &lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;};&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;// Environment-specific configurations  &lt;/span&gt;
&lt;span class=&quot;kd&quot;&gt;const&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;CloudConfig&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;development&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;apiEndpoint&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;https://dev-api.company.com&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;enableDebug&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;kc&quot;&gt;true&lt;/span&gt;
    &lt;span class=&quot;p&quot;&gt;},&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;production&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;apiEndpoint&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;https://api.company.com&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;enableDebug&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;kc&quot;&gt;false&lt;/span&gt;
    &lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;};&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Performance Monitoring:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-javascript highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;kd&quot;&gt;class&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;CloudPerformanceMonitor&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
    &lt;span class=&quot;nx&quot;&gt;trackPageLoad&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
        &lt;span class=&quot;kd&quot;&gt;const&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;perfData&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;performance&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;getEntriesByType&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;navigation&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)[&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;0&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;];&lt;/span&gt;
        &lt;span class=&quot;kd&quot;&gt;const&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;metrics&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
            &lt;span class=&quot;na&quot;&gt;timestamp&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;Date&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;now&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(),&lt;/span&gt;
            &lt;span class=&quot;na&quot;&gt;pageLoadTime&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;perfData&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;loadEventEnd&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;perfData&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;navigationStart&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
            &lt;span class=&quot;na&quot;&gt;domContentLoaded&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;perfData&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;domContentLoadedEventEnd&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;perfData&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;navigationStart&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
            &lt;span class=&quot;na&quot;&gt;environment&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;this&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;environment&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;};&lt;/span&gt;
        
        &lt;span class=&quot;k&quot;&gt;this&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;sendMetrics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;metrics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;);&lt;/span&gt;
    &lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;
    
    &lt;span class=&quot;nx&quot;&gt;sendMetrics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;metrics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
        &lt;span class=&quot;nx&quot;&gt;fetch&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;`&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;${&lt;/span&gt;&lt;span class=&quot;k&quot;&gt;this&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;metricsEndpoint&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;/performance`&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
            &lt;span class=&quot;na&quot;&gt;method&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;POST&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
            &lt;span class=&quot;na&quot;&gt;headers&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;Content-Type&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;application/json&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;},&lt;/span&gt;
            &lt;span class=&quot;na&quot;&gt;body&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;JSON&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;stringify&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;metrics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;});&lt;/span&gt;
    &lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id=&quot;database-team-responsibilities&quot;&gt;Database Team Responsibilities&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Schema Compatibility Check:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-sql highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c1&quot;&gt;-- Audit stored procedures untuk cloud database compatibility&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;SELECT&lt;/span&gt; 
    &lt;span class=&quot;k&quot;&gt;routine_name&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
    &lt;span class=&quot;n&quot;&gt;routine_type&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
    &lt;span class=&quot;n&quot;&gt;routine_definition&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;FROM&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;information_schema&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;routines&lt;/span&gt; 
&lt;span class=&quot;k&quot;&gt;WHERE&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;routine_schema&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;your_database&apos;&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;AND&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;routine_type&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;PROCEDURE&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;-- Check triggers yang mungkin tidak supported&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;SELECT&lt;/span&gt; 
    &lt;span class=&quot;k&quot;&gt;trigger_name&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
    &lt;span class=&quot;n&quot;&gt;event_manipulation&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
    &lt;span class=&quot;n&quot;&gt;event_object_table&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
    &lt;span class=&quot;n&quot;&gt;action_statement&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;FROM&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;information_schema&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;triggers&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;WHERE&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;trigger_schema&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;your_database&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Migration Execution:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;#!/bin/bash&lt;/span&gt;
&lt;span class=&quot;c&quot;&gt;# Database migration dengan minimal downtime&lt;/span&gt;

&lt;span class=&quot;nb&quot;&gt;echo&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;Pre-migration validation...&quot;&lt;/span&gt;
mysql &lt;span class=&quot;nt&quot;&gt;-h&lt;/span&gt; source-db &lt;span class=&quot;nt&quot;&gt;-u&lt;/span&gt; migration_user &lt;span class=&quot;nt&quot;&gt;-p&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;-e&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;SELECT COUNT(*) FROM critical_table;&quot;&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;&amp;gt;&lt;/span&gt; pre_count.txt

&lt;span class=&quot;nb&quot;&gt;echo&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;Schema migration...&quot;&lt;/span&gt;
mysqldump &lt;span class=&quot;nt&quot;&gt;-h&lt;/span&gt; source-db &lt;span class=&quot;nt&quot;&gt;-u&lt;/span&gt; migration_user &lt;span class=&quot;nt&quot;&gt;-p&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;--no-data&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;--routines&lt;/span&gt; your_database &lt;span class=&quot;o&quot;&gt;&amp;gt;&lt;/span&gt; schema.sql
mysql &lt;span class=&quot;nt&quot;&gt;-h&lt;/span&gt; target-db &lt;span class=&quot;nt&quot;&gt;-u&lt;/span&gt; admin_user &lt;span class=&quot;nt&quot;&gt;-p&lt;/span&gt; your_database &amp;lt; schema.sql

&lt;span class=&quot;nb&quot;&gt;echo&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;Data validation...&quot;&lt;/span&gt;
python3 validate_migration.py &lt;span class=&quot;nt&quot;&gt;--source&lt;/span&gt; source-db &lt;span class=&quot;nt&quot;&gt;--target&lt;/span&gt; target-db
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id=&quot;message-queue-team-responsibilities&quot;&gt;Message Queue Team Responsibilities&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Kafka Migration:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-python highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;kn&quot;&gt;from&lt;/span&gt; &lt;span class=&quot;nn&quot;&gt;kafka&lt;/span&gt; &lt;span class=&quot;kn&quot;&gt;import&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;KafkaProducer&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;KafkaConsumer&lt;/span&gt;
&lt;span class=&quot;kn&quot;&gt;from&lt;/span&gt; &lt;span class=&quot;nn&quot;&gt;kafka.admin&lt;/span&gt; &lt;span class=&quot;kn&quot;&gt;import&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;KafkaAdminClient&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;NewTopic&lt;/span&gt;

&lt;span class=&quot;k&quot;&gt;class&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;KafkaMigrator&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;__init__&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;source_config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;target_config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;):&lt;/span&gt;
        &lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;source_config&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;source_config&lt;/span&gt;
        &lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;target_config&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;target_config&lt;/span&gt;
        
    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;migrate_topics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;topic_list&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;):&lt;/span&gt;
        &lt;span class=&quot;c1&quot;&gt;# Create topics di target cluster
&lt;/span&gt;        &lt;span class=&quot;n&quot;&gt;admin_client&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;KafkaAdminClient&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;bootstrap_servers&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;target_config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&apos;bootstrap_servers&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        
        &lt;span class=&quot;n&quot;&gt;new_topics&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;[]&lt;/span&gt;
        &lt;span class=&quot;k&quot;&gt;for&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;topic_name&lt;/span&gt; &lt;span class=&quot;ow&quot;&gt;in&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;topic_list&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;new_topic&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;NewTopic&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;
                &lt;span class=&quot;n&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;topic_name&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
                &lt;span class=&quot;n&quot;&gt;num_partitions&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;3&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
                &lt;span class=&quot;n&quot;&gt;replication_factor&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;2&lt;/span&gt;
            &lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;new_topics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;append&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;new_topic&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        
        &lt;span class=&quot;n&quot;&gt;admin_client&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;create_topics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;new_topics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        
        &lt;span class=&quot;c1&quot;&gt;# Migrate data
&lt;/span&gt;        &lt;span class=&quot;k&quot;&gt;for&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;topic_name&lt;/span&gt; &lt;span class=&quot;ow&quot;&gt;in&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;topic_list&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;
            &lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;migrate_topic_data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;topic_name&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
    
    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;migrate_topic_data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;topic_name&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;):&lt;/span&gt;
        &lt;span class=&quot;n&quot;&gt;consumer&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;KafkaConsumer&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;topic_name&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;bootstrap_servers&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;source_config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&apos;bootstrap_servers&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;],&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;auto_offset_reset&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&apos;earliest&apos;&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        
        &lt;span class=&quot;n&quot;&gt;producer&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;KafkaProducer&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;bootstrap_servers&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;target_config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&apos;bootstrap_servers&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        
        &lt;span class=&quot;k&quot;&gt;for&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;message&lt;/span&gt; &lt;span class=&quot;ow&quot;&gt;in&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;consumer&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;
            &lt;span class=&quot;n&quot;&gt;producer&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;send&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;topic_name&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;value&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;message&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;value&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;key&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;message&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;key&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        
        &lt;span class=&quot;n&quot;&gt;producer&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;flush&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;
        &lt;span class=&quot;n&quot;&gt;producer&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;close&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;
        &lt;span class=&quot;n&quot;&gt;consumer&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;close&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Cloud-Managed Services:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# AWS MSK&lt;/span&gt;
aws kafka create-cluster &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--cluster-name&lt;/span&gt; migration-kafka &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--broker-node-group-info&lt;/span&gt; file://broker-info.json &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--kafka-version&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;2.8.0&quot;&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# Azure Event Hubs  &lt;/span&gt;
az eventhubs namespace create &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--resource-group&lt;/span&gt; Migration-RG &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt; migration-eventhubs

&lt;span class=&quot;c&quot;&gt;# Google Pub/Sub&lt;/span&gt;
gcloud pubsub topics create migration-topic
gcloud pubsub subscriptions create migration-sub &lt;span class=&quot;nt&quot;&gt;--topic&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;migration-topic
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h2 id=&quot;persiapan-teknis&quot;&gt;Persiapan Teknis&lt;/h2&gt;

&lt;h3 id=&quot;1-cloud-environment-setup&quot;&gt;1. Cloud Environment Setup&lt;/h3&gt;

&lt;p&gt;Foundation yang solid adalah kunci sukses migration. Semua cloud provider memiliki pendekatan berbeda, tapi principles yang sama: security first, scalability by design, dan observability from day one.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Network Foundation (Multi-Cloud):&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AWS VPC Setup:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create VPC&lt;/span&gt;
aws ec2 create-vpc &lt;span class=&quot;nt&quot;&gt;--cidr-block&lt;/span&gt; 10.0.0.0/16 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--tag-specifications&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;ResourceType=vpc,Tags=[{Key=Name,Value=Migration-VPC}]&apos;&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# Create subnets&lt;/span&gt;
aws ec2 create-subnet &lt;span class=&quot;nt&quot;&gt;--vpc-id&lt;/span&gt; vpc-12345678 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--cidr-block&lt;/span&gt; 10.0.1.0/24 &lt;span class=&quot;nt&quot;&gt;--availability-zone&lt;/span&gt; us-east-1a &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--tag-specifications&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;ResourceType=subnet,Tags=[{Key=Name,Value=Private-Subnet-1}]&apos;&lt;/span&gt;

aws ec2 create-subnet &lt;span class=&quot;nt&quot;&gt;--vpc-id&lt;/span&gt; vpc-12345678 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--cidr-block&lt;/span&gt; 10.0.2.0/24 &lt;span class=&quot;nt&quot;&gt;--availability-zone&lt;/span&gt; us-east-1b &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--tag-specifications&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;ResourceType=subnet,Tags=[{Key=Name,Value=Public-Subnet-1}]&apos;&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# Internet Gateway&lt;/span&gt;
aws ec2 create-internet-gateway
aws ec2 attach-internet-gateway &lt;span class=&quot;nt&quot;&gt;--vpc-id&lt;/span&gt; vpc-12345678 &lt;span class=&quot;nt&quot;&gt;--internet-gateway-id&lt;/span&gt; igw-87654321

&lt;span class=&quot;c&quot;&gt;# NAT Gateway untuk private subnet internet access&lt;/span&gt;
aws ec2 create-nat-gateway &lt;span class=&quot;nt&quot;&gt;--subnet-id&lt;/span&gt; subnet-12345678 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--allocation-id&lt;/span&gt; eipalloc-87654321
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure Virtual Network Setup:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create Resource Group&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzResourceGroup&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-RG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Location&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;East US&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Create Virtual Network&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$virtualNetwork&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzVirtualNetwork&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ResourceGroupName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-RG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Location&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;East US&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-VNet&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-AddressPrefix&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;10.0.0.0/16&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Create subnets&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$subnetConfig1&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Add-AzVirtualNetworkSubnetConfig&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Private-Subnet&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-AddressPrefix&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;10.0.1.0/24&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-VirtualNetwork&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$virtualNetwork&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$subnetConfig2&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Add-AzVirtualNetworkSubnetConfig&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Public-Subnet&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-AddressPrefix&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;10.0.2.0/24&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-VirtualNetwork&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$virtualNetwork&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Apply configuration&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$virtualNetwork&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Set-AzVirtualNetwork&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Network Security Group&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzNetworkSecurityGroup&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ResourceGroupName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-RG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Location&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;East US&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-NSG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Google Cloud VPC Setup:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create VPC&lt;/span&gt;
gcloud compute networks create migration-vpc &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--project&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;PROJECT_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--subnet-mode&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;custom &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--mtu&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;1460 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--bgp-routing-mode&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;regional

&lt;span class=&quot;c&quot;&gt;# Create subnets&lt;/span&gt;
gcloud compute networks subnets create private-subnet &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--project&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;PROJECT_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--range&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;10.0.1.0/24 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--network&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;migration-vpc &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--region&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;us-central1

gcloud compute networks subnets create public-subnet &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--project&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;PROJECT_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--range&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;10.0.2.0/24 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--network&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;migration-vpc &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--region&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;us-central1

&lt;span class=&quot;c&quot;&gt;# Firewall rules&lt;/span&gt;
gcloud compute firewall-rules create allow-internal &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--project&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;PROJECT_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--network&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;migration-vpc &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--allow&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;tcp,udp,icmp &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--source-ranges&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;10.0.0.0/16
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Security Baseline (Multi-Cloud):&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Identity and Access Management:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AWS IAM Policy Example:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-json highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Version&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;2012-10-17&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Statement&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Effect&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Allow&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Action&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;ec2:DescribeInstances&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;ec2:StartInstances&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;ec2:StopInstances&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;],&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Resource&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;*&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Condition&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;StringEquals&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
          &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;aws:RequestedRegion&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;us-east-1&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;us-west-2&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure RBAC Assignment:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create custom role&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Get-AzRoleDefinition&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Virtual Machine Contributor&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$null&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration VM Operator&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Description&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Can manage VMs for migration project&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Actions&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;RemoveRange&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;0&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Actions&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Count&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Actions&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Add&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Microsoft.Compute/virtualMachines/*&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Actions&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Add&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Microsoft.Network/networkInterfaces/read&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;AssignableScopes&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Clear&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;AssignableScopes&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Add&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;/subscriptions/SUBSCRIPTION_ID&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzRoleDefinition&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Role&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$role&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Assign role&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzRoleAssignment&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-SignInName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;user&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;@&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;domain.com&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-RoleDefinitionName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration VM Operator&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Scope&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;/subscriptions/SUBSCRIPTION_ID&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Google Cloud IAM:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create custom role&lt;/span&gt;
gcloud iam roles create migrationVmOperator &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--project&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;PROJECT_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--title&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration VM Operator&quot;&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--description&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Custom role for migration project&quot;&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--permissions&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;compute.instances.get,compute.instances.start,compute.instances.stop&quot;&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# Bind user to role&lt;/span&gt;
gcloud projects add-iam-policy-binding PROJECT_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--member&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;user:user@domain.com&quot;&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--role&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;projects/PROJECT_ID/roles/migrationVmOperator&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Encryption Configuration:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AWS Encryption:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# S3 bucket encryption&lt;/span&gt;
aws s3api create-bucket &lt;span class=&quot;nt&quot;&gt;--bucket&lt;/span&gt; migration-data-bucket &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--create-bucket-configuration&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;LocationConstraint&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;us-west-2

aws s3api put-bucket-encryption &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--bucket&lt;/span&gt; migration-data-bucket &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--server-side-encryption-configuration&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;s1&quot;&gt;&apos;{&quot;Rules&quot;:[{&quot;ApplyServerSideEncryptionByDefault&quot;:{&quot;SSEAlgorithm&quot;:&quot;AES256&quot;}}]}&apos;&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# EBS encryption&lt;/span&gt;
aws ec2 modify-ebs-default-kms-key-id &lt;span class=&quot;nt&quot;&gt;--kms-key-id&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;alias&lt;/span&gt;/migration-key
aws ec2 enable-ebs-encryption-by-default
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure Encryption:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Storage account encryption&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$storageAccount&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzStorageAccount&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ResourceGroupName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-RG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;migrationstorageacct&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Location&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;East US&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-SkuName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Standard_LRS&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Kind&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;StorageV2&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-EnableHttpsTrafficOnly&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$true&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Enable encryption&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Set-AzStorageAccount&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ResourceGroupName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-RG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-AccountName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;migrationstorageacct&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-EnableBlobEncryption&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$true&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-EnableFileEncryption&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$true&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Google Cloud Encryption:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create Cloud KMS key&lt;/span&gt;
gcloud kms keyrings create migration-keyring &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--location&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;global

gcloud kms keys create migration-key &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--location&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;global &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--keyring&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;migration-keyring &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--purpose&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;encryption

&lt;span class=&quot;c&quot;&gt;# Cloud Storage encryption&lt;/span&gt;
gsutil mb &lt;span class=&quot;nt&quot;&gt;-p&lt;/span&gt; PROJECT_ID &lt;span class=&quot;nt&quot;&gt;-c&lt;/span&gt; STANDARD &lt;span class=&quot;nt&quot;&gt;-l&lt;/span&gt; US gs://migration-data-bucket
gsutil kms encryption &lt;span class=&quot;nt&quot;&gt;-k&lt;/span&gt; projects/PROJECT_ID/locations/global/keyRings/migration-keyring/cryptoKeys/migration-key gs://migration-data-bucket
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Connectivity Setup:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Hybrid Connectivity Options:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AWS Direct Connect:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create Virtual Interface&lt;/span&gt;
aws directconnect create-private-virtual-interface &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--connection-id&lt;/span&gt; dxcon-123456789 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--new-private-virtual-interface&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nv&quot;&gt;vlan&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;100,bgpAsn&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;65000,virtualInterfaceName&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;Migration-VIF,virtualGatewayId&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;vgw-12345678
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure ExpressRoute:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create ExpressRoute circuit&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzExpressRouteCircuit&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-Circuit&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ResourceGroupName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-RG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Location&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;East US&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-SkuTier&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Standard&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-SkuFamily&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;MeteredData&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ServiceProviderName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Provider Name&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-PeeringLocation&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Washington DC&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-BandwidthInMbps&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;1000&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Google Cloud Interconnect:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create VLAN attachment&lt;/span&gt;
gcloud compute interconnects attachments create migration-attachment &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--region&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;us-central1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--router&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;migration-router &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--interconnect&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;migration-interconnect &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--vlan&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;100
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;DNS Strategy:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Multi-Cloud DNS Management:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# AWS Route53&lt;/span&gt;
aws route53 create-hosted-zone &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt; migration.company.com &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--caller-reference&lt;/span&gt; migration-&lt;span class=&quot;si&quot;&gt;$(&lt;/span&gt;&lt;span class=&quot;nb&quot;&gt;date&lt;/span&gt; +%s&lt;span class=&quot;si&quot;&gt;)&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# Azure DNS&lt;/span&gt;
az network dns zone create &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--resource-group&lt;/span&gt; Migration-RG &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt; migration.company.com

&lt;span class=&quot;c&quot;&gt;# Google Cloud DNS&lt;/span&gt;
gcloud dns managed-zones create migration-zone &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--dns-name&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;migration.company.com. &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--description&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration project DNS zone&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id=&quot;2-landing-zone-preparation&quot;&gt;2. Landing Zone Preparation&lt;/h3&gt;

&lt;p&gt;Landing zone adalah foundational setup yang akan menentukan scalability, security, dan manageability dari cloud environment. Ini bukan hanya tentang account structure, tapi entire governance framework.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Multi-Account/Subscription Strategy:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AWS Organizations Structure:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create organization&lt;/span&gt;
aws organizations create-organization &lt;span class=&quot;nt&quot;&gt;--feature-set&lt;/span&gt; ALL

&lt;span class=&quot;c&quot;&gt;# Create accounts&lt;/span&gt;
aws organizations create-account &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--email&lt;/span&gt; migration-prod@company.com &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--account-name&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;Migration-Production&quot;&lt;/span&gt;

aws organizations create-account &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--email&lt;/span&gt; migration-dev@company.com &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--account-name&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;Migration-Development&quot;&lt;/span&gt;

aws organizations create-account &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--email&lt;/span&gt; migration-security@company.com &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--account-name&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;Migration-Security&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure Management Groups:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create management group&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzManagementGroup&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-GroupName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-MG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-DisplayName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration Management Group&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Create subscriptions under management group&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzSubscription&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-Production&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ManagementGroupId&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-MG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzSubscription&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-Development&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ManagementGroupId&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-MG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Google Cloud Organization:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Set organization policy&lt;/span&gt;
gcloud organizations set-policy ORGANIZATION_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--policy-file&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;policy.yaml

&lt;span class=&quot;c&quot;&gt;# Create projects&lt;/span&gt;
gcloud projects create migration-prod-PROJECT_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--organization&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;ORGANIZATION_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration Production&quot;&lt;/span&gt;

gcloud projects create migration-dev-PROJECT_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--organization&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;ORGANIZATION_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration Development&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Account/Subscription Purpose:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Core Accounts:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Production&lt;/strong&gt;: Live production workloads&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Staging&lt;/strong&gt;: Pre-production testing dan UAT&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Development&lt;/strong&gt;: Development dan integration testing&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Security&lt;/strong&gt;: Central security services (logging, monitoring, compliance)&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Shared Services&lt;/strong&gt;: DNS, Active Directory, backup services&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Network&lt;/strong&gt;: Network connectivity hub (VPN, Direct Connect)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Governance Framework:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Tagging Strategy (Consistent across clouds):&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;na&quot;&gt;Required_Tags&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;Environment&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;Production&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Staging&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Development&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;Application&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;App-Name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;Owner&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;Team-Name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;CostCenter&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;Cost-Center-Code&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;Project&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;Migration-Project-Code&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;Backup&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;Daily&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Weekly&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;None&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;Compliance&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;PCI&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;HIPAA&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;SOX&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;None&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;Optional_Tags&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;Schedule&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;Business-Hours&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;24x7&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Weekend-Off&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;DataClassification&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;Public&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Internal&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Confidential&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Restricted&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;MaintenanceWindow&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;Weekend&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Weeknight&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Anytime&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;AWS Tagging Enforcement:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-json highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Version&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;2012-10-17&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Statement&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Effect&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Deny&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Action&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;ec2:RunInstances&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;rds:CreateDBInstance&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;],&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Resource&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;*&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Condition&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;Null&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
          &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;aws:RequestTag/Environment&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;true&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
          &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;aws:RequestTag/Application&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;true&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
          &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;aws:RequestTag/Owner&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;true&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure Policy Definition:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-json highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;mode&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;All&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;policyRule&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;if&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;anyOf&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
          &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;field&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;tags[&apos;Environment&apos;]&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
          &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;exists&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;false&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;},&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
          &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;field&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;tags[&apos;Application&apos;]&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
          &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;exists&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;false&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;},&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;then&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nl&quot;&gt;&quot;effect&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;deny&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Resource Naming Conventions:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Standard Pattern:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;{company}-{environment}-{application}-{resource-type}-{region}-{instance}

Examples:
company-prod-webapp-vm-useast1-001
company-dev-api-db-uswest2-001
company-staging-cache-redis-euwest1-001
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Multi-Cloud Implementation:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# AWS&lt;/span&gt;
aws ec2 run-instances &lt;span class=&quot;nt&quot;&gt;--image-id&lt;/span&gt; ami-12345678 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--instance-type&lt;/span&gt; t3.medium &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--tag-specifications&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;ResourceType=instance,Tags=[{Key=Name,Value=company-prod-webapp-vm-useast1-001}]&apos;&lt;/span&gt;

&lt;span class=&quot;c&quot;&gt;# Azure&lt;/span&gt;
az vm create &lt;span class=&quot;nt&quot;&gt;--resource-group&lt;/span&gt; Migration-RG &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--name&lt;/span&gt; company-prod-webapp-vm-useast-001 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--image&lt;/span&gt; UbuntuLTS &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--tags&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Environment&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;Production &lt;span class=&quot;nv&quot;&gt;Application&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;WebApp

&lt;span class=&quot;c&quot;&gt;# GCP&lt;/span&gt;
gcloud compute instances create company-prod-webapp-vm-uscentral1-001 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--machine-type&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;n1-standard-2 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--labels&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;environment&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;production,application&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;webapp
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Cost Management Setup:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Budget Alerts (Multi-Cloud):&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AWS Budgets:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws budgets create-budget &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--account-id&lt;/span&gt; 123456789012 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--budget&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;{
    &quot;BudgetName&quot;: &quot;Migration-Monthly-Budget&quot;,
    &quot;BudgetLimit&quot;: {
      &quot;Amount&quot;: &quot;10000&quot;,
      &quot;Unit&quot;: &quot;USD&quot;
    },
    &quot;TimeUnit&quot;: &quot;MONTHLY&quot;,
    &quot;BudgetType&quot;: &quot;COST&quot;
  }&apos;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure Budgets:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;n&quot;&gt;New-AzConsumptionBudget&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-Budget&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Amount&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;10000&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Category&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Cost&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-TimeGrain&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Monthly&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-StartDate&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;2025-01-01&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-EndDate&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;2025-12-31&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Google Cloud Budgets:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;gcloud billing budgets create &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--billing-account&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;BILLING_ACCOUNT_ID &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--display-name&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration Budget&quot;&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--budget-amount&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;10000USD
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Backup Policies:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Cross-Cloud Backup Strategy:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;na&quot;&gt;Backup_Tiers&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;Tier_1_Critical&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Frequency&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;4&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;times&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;daily&quot;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Retention&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;30&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;days&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;local,&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;365&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;days&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;archive&quot;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;RTO&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;1&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;hour&quot;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;RPO&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;15&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;minutes&quot;&lt;/span&gt;
    
  &lt;span class=&quot;na&quot;&gt;Tier_2_Important&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Frequency&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;Daily&quot;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Retention&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;14&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;days&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;local,&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;90&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;days&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;archive&quot;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;RTO&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;4&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;hours&quot;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;RPO&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;1&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;hour&quot;&lt;/span&gt;
    
  &lt;span class=&quot;na&quot;&gt;Tier_3_Standard&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Frequency&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;Weekly&quot;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Retention&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;4&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;weeks&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;local,&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;52&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;weeks&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;archive&quot;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;RTO&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;24&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;hours&quot;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;RPO&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;24&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;hours&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Compliance Framework:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Multi-Cloud Compliance Monitoring:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AWS Config Rules:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;aws configservice put-config-rule &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--config-rule&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;{
    &quot;ConfigRuleName&quot;: &quot;required-tags&quot;,
    &quot;Source&quot;: {
      &quot;Owner&quot;: &quot;AWS&quot;,
      &quot;SourceIdentifier&quot;: &quot;REQUIRED_TAGS&quot;
    },
    &quot;InputParameters&quot;: &quot;{\&quot;tag1Key\&quot;:\&quot;Environment\&quot;,\&quot;tag1Value\&quot;:\&quot;Production,Staging,Development\&quot;}&quot;
  }&apos;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure Policy Assignment:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;n&quot;&gt;New-AzPolicyAssignment&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Require-Tags-Policy&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-PolicyDefinition&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$policyDef&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Scope&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;/subscriptions/SUBSCRIPTION_ID&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Google Cloud Organization Policies:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;na&quot;&gt;constraint&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;constraints/compute.requireLabels&lt;/span&gt;
&lt;span class=&quot;na&quot;&gt;listPolicy&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;requiredValues&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;environment&quot;&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;application&quot;&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;owner&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id=&quot;3-tools-dan-automation&quot;&gt;3. Tools dan Automation&lt;/h3&gt;

&lt;p&gt;Automation adalah kunci untuk migration yang consistent, repeatable, dan scalable. Manual migration processes tidak sustainable untuk enterprise-scale projects.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Migration Tools (Multi-Cloud):&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Database Migration Tools:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AWS Database Migration Service (DMS):&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create replication instance&lt;/span&gt;
aws dms create-replication-instance &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--replication-instance-identifier&lt;/span&gt; migration-instance &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--replication-instance-class&lt;/span&gt; dms.t3.medium &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--allocated-storage&lt;/span&gt; 100 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--vpc-security-group-ids&lt;/span&gt; sg-12345678

&lt;span class=&quot;c&quot;&gt;# Create source endpoint&lt;/span&gt;
aws dms create-endpoint &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--endpoint-identifier&lt;/span&gt; source-mysql &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--endpoint-type&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;source&lt;/span&gt; &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--engine-name&lt;/span&gt; mysql &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--server-name&lt;/span&gt; source.mysql.com &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--port&lt;/span&gt; 3306 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--username&lt;/span&gt; migration_user &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--password&lt;/span&gt; migration_password

&lt;span class=&quot;c&quot;&gt;# Create target endpoint&lt;/span&gt;
aws dms create-endpoint &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--endpoint-identifier&lt;/span&gt; target-rds &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--endpoint-type&lt;/span&gt; target &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--engine-name&lt;/span&gt; mysql &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--server-name&lt;/span&gt; target.rds.amazonaws.com &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--port&lt;/span&gt; 3306 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--username&lt;/span&gt; admin &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--password&lt;/span&gt; admin_password
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure Database Migration Service:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create migration service&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzDataMigrationService&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ResourceGroupName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-RG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;MigrationService&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Location&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;East US&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Sku&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Premium_4vCores&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Create migration project&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;New-AzDataMigrationProject&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ResourceGroupName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-RG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ServiceName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;MigrationService&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ProjectName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;DatabaseMigration&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Location&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;East US&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-SourcePlatform&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;SQL&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-TargetPlatform&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;SQLMI&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Google Cloud Database Migration Service:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create migration job&lt;/span&gt;
gcloud database migration migration-jobs create mysql-migration &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--region&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;us-central1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--destination-connection-profile&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;target-cloudsql &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--source-connection-profile&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;source-mysql &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--vm-instance-machine-type&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;n1-standard-2
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Server Migration Tools:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AWS Application Migration Service (MGN):&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Install replication agent&lt;/span&gt;
wget &lt;span class=&quot;nt&quot;&gt;-O&lt;/span&gt; ./aws-replication-installer-init.py https://aws-application-migration-service-us-east-1.s3.amazonaws.com/latest/linux/aws-replication-installer-init.py

&lt;span class=&quot;nb&quot;&gt;sudo &lt;/span&gt;python3 aws-replication-installer-init.py &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--region&lt;/span&gt; us-east-1 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--aws-access-key-id&lt;/span&gt; AKIA... &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--aws-secret-access-key&lt;/span&gt; ...
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Azure Migrate:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Download Azure Migrate appliance&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Invoke-WebRequest&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Uri&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;https://aka.ms/migrate/appliance/vmware&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-OutFile&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;AzureMigrateAppliance.ova&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Register appliance&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;Register-AzMigrateProject&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ResourceGroupName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Migration-RG&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;n&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ProjectName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;AzureMigrateProject&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;\&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Location&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;East US&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Google Cloud Migrate for Compute Engine:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Create migration source&lt;/span&gt;
gcloud compute os-config guest-policies create migration-policy &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--file&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;migration-policy.yaml

&lt;span class=&quot;c&quot;&gt;# Start migration wave&lt;/span&gt;
gcloud compute sole-tenancy node-groups create migration-nodes &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--node-template&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;migration-template &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--target-size&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;3 &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--zone&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;us-central1-a
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Infrastructure as Code (Multi-Cloud):&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Terraform Multi-Cloud Example:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-hcl highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c1&quot;&gt;# Provider configurations&lt;/span&gt;
&lt;span class=&quot;nx&quot;&gt;provider&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;aws&quot;&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;region&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;us-east-1&quot;&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;

&lt;span class=&quot;nx&quot;&gt;provider&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;azurerm&quot;&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;features&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{}&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;

&lt;span class=&quot;nx&quot;&gt;provider&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;google&quot;&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;project&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;var&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;gcp_project_id&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;region&lt;/span&gt;  &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;us-central1&quot;&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# AWS VPC&lt;/span&gt;
&lt;span class=&quot;nx&quot;&gt;resource&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;aws_vpc&quot;&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;migration_vpc&quot;&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;cidr_block&lt;/span&gt;           &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;10.0.0.0/16&quot;&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;enable_dns_hostnames&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;kc&quot;&gt;true&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;enable_dns_support&lt;/span&gt;   &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;kc&quot;&gt;true&lt;/span&gt;

  &lt;span class=&quot;nx&quot;&gt;tags&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
    &lt;span class=&quot;nx&quot;&gt;Name&lt;/span&gt;        &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;Migration-VPC&quot;&lt;/span&gt;
    &lt;span class=&quot;nx&quot;&gt;Environment&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;Production&quot;&lt;/span&gt;
    &lt;span class=&quot;nx&quot;&gt;Project&lt;/span&gt;     &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;CloudMigration&quot;&lt;/span&gt;
  &lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# Azure Virtual Network&lt;/span&gt;
&lt;span class=&quot;nx&quot;&gt;resource&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;azurerm_virtual_network&quot;&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;migration_vnet&quot;&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;name&lt;/span&gt;                &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;migration-vnet&quot;&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;address_space&lt;/span&gt;       &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;10.1.0.0/16&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;location&lt;/span&gt;            &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;azurerm_resource_group&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;migration&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;location&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;resource_group_name&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;azurerm_resource_group&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;migration&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;name&lt;/span&gt;

  &lt;span class=&quot;nx&quot;&gt;tags&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
    &lt;span class=&quot;nx&quot;&gt;Environment&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;Production&quot;&lt;/span&gt;
    &lt;span class=&quot;nx&quot;&gt;Project&lt;/span&gt;     &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;CloudMigration&quot;&lt;/span&gt;
  &lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# Google Cloud VPC&lt;/span&gt;
&lt;span class=&quot;nx&quot;&gt;resource&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;google_compute_network&quot;&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;migration_vpc&quot;&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;name&lt;/span&gt;                    &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;migration-vpc&quot;&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;auto_create_subnetworks&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;kc&quot;&gt;false&lt;/span&gt;
  &lt;span class=&quot;nx&quot;&gt;mtu&lt;/span&gt;                     &lt;span class=&quot;p&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;mi&quot;&gt;1460&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;AWS CloudFormation Template:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;na&quot;&gt;AWSTemplateFormatVersion&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;2010-09-09&apos;&lt;/span&gt;
&lt;span class=&quot;na&quot;&gt;Description&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;Migration&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;infrastructure&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;template&apos;&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;Parameters&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;Environment&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Type&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;String&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Default&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Production&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;AllowedValues&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;Production&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Staging&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nv&quot;&gt;Development&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;Resources&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;MigrationVPC&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Type&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;AWS::EC2::VPC&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Properties&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;CidrBlock&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;10.0.0.0/16&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;EnableDnsHostnames&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;true&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;EnableDnsSupport&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;true&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;Tags&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;Key&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Name&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;Value&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;kt&quot;&gt;!Sub&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;${Environment}-Migration-VPC&quot;&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;Key&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Environment&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;Value&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;kt&quot;&gt;!Ref&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Environment&lt;/span&gt;

  &lt;span class=&quot;na&quot;&gt;PrivateSubnet&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Type&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;AWS::EC2::Subnet&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;Properties&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;VpcId&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;kt&quot;&gt;!Ref&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;MigrationVPC&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;CidrBlock&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;10.0.1.0/24&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;AvailabilityZone&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;kt&quot;&gt;!Select&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;0&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;kt&quot;&gt;!GetAZs&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;Tags&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;Key&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Name&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;Value&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;kt&quot;&gt;!Sub&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;${Environment}-Private-Subnet&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Configuration Management:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Ansible Playbook for Multi-Cloud:&lt;/strong&gt;&lt;/p&gt;

&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;nn&quot;&gt;---&lt;/span&gt;
&lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Configure migrated servers&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;hosts&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;all&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;become&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;yes&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;vars&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;environment&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;{{&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;env&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;default(&apos;production&apos;)&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;}}&quot;&lt;/span&gt;
    
  &lt;span class=&quot;na&quot;&gt;tasks&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Update system packages&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;package&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;*&quot;&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;state&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;latest&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;when&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;ansible_os_family == &quot;RedHat&quot;&lt;/span&gt;

    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Install monitoring agent&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;script&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;install_monitoring_agent.sh&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;args&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;creates&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;/opt/monitoring/agent&lt;/span&gt;

    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Configure application&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;template&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;src&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;app.conf.j2&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;dest&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;/etc/app/config.conf&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;backup&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;yes&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;notify&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;restart application&lt;/span&gt;

    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Configure cloud-specific settings&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;include_tasks&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;{{&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;ansible_cloud_provider&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;}}_config.yml&quot;&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;when&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;ansible_cloud_provider is defined&lt;/span&gt;

  &lt;span class=&quot;na&quot;&gt;handlers&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;restart application&lt;/span&gt;
      &lt;span class=&quot;na&quot;&gt;service&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;myapp&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;state&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;restarted&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;CI/CD Pipeline for Migration:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GitLab CI Pipeline:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;na&quot;&gt;stages&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;validate&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;plan&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;deploy&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;test&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;cleanup&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;variables&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;TF_ROOT&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;${CI_PROJECT_DIR}/terraform&quot;&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;TF_STATE_NAME&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;${CI_ENVIRONMENT_NAME}&quot;&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;before_script&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;cd ${TF_ROOT}&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;terraform init -backend-config=&quot;key=${TF_STATE_NAME}.tfstate&quot;&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;validate&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;stage&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;validate&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;script&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;terraform validate&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;terraform fmt -check&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;only&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;merge_requests&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;main&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;plan&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;stage&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;plan&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;script&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;terraform plan -out=plan.cache&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;artifacts&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;paths&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;${TF_ROOT}/plan.cache&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;expire_in&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;7 days&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;only&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;main&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;deploy&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;stage&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;deploy&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;script&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;terraform apply plan.cache&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;dependencies&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;plan&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;when&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;manual&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;only&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;main&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;migration_test&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;stage&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;test&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;script&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;python3 migration_tests.py&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;ansible-playbook -i inventory/production test_connectivity.yml&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;only&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;main&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;cleanup&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;stage&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;cleanup&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;script&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;terraform destroy -auto-approve&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;when&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;manual&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;only&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;main&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Monitoring dan Observability Setup:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Multi-Cloud Monitoring Stack:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Prometheus Configuration:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;na&quot;&gt;global&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;scrape_interval&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;15s&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;evaluation_interval&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;15s&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;rule_files&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;migration_rules.yml&quot;&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;alerting&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;na&quot;&gt;alertmanagers&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
    &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;static_configs&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;targets&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
          &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;alertmanager:9093&lt;/span&gt;

&lt;span class=&quot;na&quot;&gt;scrape_configs&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;job_name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;aws-instances&apos;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;ec2_sd_configs&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;region&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;us-east-1&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;port&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;m&quot;&gt;9100&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;relabel_configs&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;source_labels&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;__meta_ec2_tag_Environment&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;target_label&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;environment&lt;/span&gt;
      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;source_labels&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;__meta_ec2_tag_Application&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;]&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;target_label&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;application&lt;/span&gt;

  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;job_name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;azure-instances&apos;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;azure_sd_configs&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;subscription_id&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;subscription-id&quot;&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;tenant_id&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;tenant-id&quot;&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;client_id&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;client-id&quot;&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;client_secret&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;client-secret&quot;&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;port&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;m&quot;&gt;9100&lt;/span&gt;

  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;job_name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;gcp-instances&apos;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;gce_sd_configs&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;project&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;project-id&apos;&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;zone&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;us-central1-a&apos;&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;port&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;m&quot;&gt;9100&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Migration-Specific Alerts:&lt;/strong&gt;&lt;/p&gt;

&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;na&quot;&gt;groups&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;migration_alerts&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;rules&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;alert&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;MigrationHighLatency&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;expr&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;http_request_duration_seconds{quantile=&quot;0.95&quot;} &amp;gt; &lt;/span&gt;&lt;span class=&quot;m&quot;&gt;0.5&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;for&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;5m&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;labels&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;severity&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;warning&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;annotations&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;summary&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;High&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;latency&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;detected&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;during&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;migration&quot;&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;description&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;Application&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;{{&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;$labels.application&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;}}&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;has&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;high&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;latency&quot;&lt;/span&gt;

      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;alert&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;MigrationErrorRate&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;expr&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;rate(http_requests_total{status=~&quot;5..&quot;}[5m]) &amp;gt; &lt;/span&gt;&lt;span class=&quot;m&quot;&gt;0.1&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;for&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;2m&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;labels&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;severity&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;critical&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;annotations&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;summary&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;High&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;error&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;rate&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;during&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;migration&quot;&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;description&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;Error&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;rate&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;is&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;{{&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;$value&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;}}&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;for&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;{{&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;$labels.application&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;}}&quot;&lt;/span&gt;

      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;alert&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;DatabaseConnectionFailure&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;expr&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;up{job=&quot;database&quot;} == &lt;/span&gt;&lt;span class=&quot;m&quot;&gt;0&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;for&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;1m&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;labels&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;severity&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;critical&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;annotations&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;summary&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;Database&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;connection&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;failure&quot;&lt;/span&gt;
          &lt;span class=&quot;na&quot;&gt;description&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;Database&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;{{&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;$labels.instance&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;}}&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;is&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;unreachable&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h2 id=&quot;fase-eksekusi&quot;&gt;Fase Eksekusi&lt;/h2&gt;

&lt;h3 id=&quot;1-pilot-migration&quot;&gt;1. Pilot Migration&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Scope Terbatas:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Pilih 1-2 aplikasi non-critical&lt;/li&gt;
  &lt;li&gt;Test semua processes dan tools&lt;/li&gt;
  &lt;li&gt;Validate performance dan functionality&lt;/li&gt;
  &lt;li&gt;Measure timeline accuracy&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Checklist Pilot:&lt;/strong&gt;&lt;/p&gt;
&lt;ul class=&quot;task-list&quot;&gt;
  &lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;task-list-item-checkbox&quot; disabled=&quot;disabled&quot; /&gt;Application functionality testing&lt;/li&gt;
  &lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;task-list-item-checkbox&quot; disabled=&quot;disabled&quot; /&gt;Performance benchmark&lt;/li&gt;
  &lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;task-list-item-checkbox&quot; disabled=&quot;disabled&quot; /&gt;Security validation&lt;/li&gt;
  &lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;task-list-item-checkbox&quot; disabled=&quot;disabled&quot; /&gt;Backup/restore testing&lt;/li&gt;
  &lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;task-list-item-checkbox&quot; disabled=&quot;disabled&quot; /&gt;Rollback procedure testing&lt;/li&gt;
  &lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;task-list-item-checkbox&quot; disabled=&quot;disabled&quot; /&gt;Monitoring setup verification&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;2-production-migration&quot;&gt;2. Production Migration&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Pre-Migration:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# Database backup&lt;/span&gt;
mysqldump &lt;span class=&quot;nt&quot;&gt;-u&lt;/span&gt; root &lt;span class=&quot;nt&quot;&gt;-p&lt;/span&gt; database_name &lt;span class=&quot;o&quot;&gt;&amp;gt;&lt;/span&gt; backup.sql

&lt;span class=&quot;c&quot;&gt;# Application state backup&lt;/span&gt;
&lt;span class=&quot;nb&quot;&gt;tar&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;-czf&lt;/span&gt; app_backup.tar.gz /path/to/application

&lt;span class=&quot;c&quot;&gt;# Configuration backup&lt;/span&gt;
&lt;span class=&quot;nb&quot;&gt;cp&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;-r&lt;/span&gt; /etc/app-config /backup/config
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Migration Execution:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
  &lt;li&gt;&lt;strong&gt;Maintenance window communication&lt;/strong&gt;&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Final data sync&lt;/strong&gt;&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Application cutover&lt;/strong&gt;&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;DNS switchover&lt;/strong&gt;&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Functionality validation&lt;/strong&gt;&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Performance monitoring&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Post-Migration:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Immediate functionality testing&lt;/li&gt;
  &lt;li&gt;Performance monitoring&lt;/li&gt;
  &lt;li&gt;Error log analysis&lt;/li&gt;
  &lt;li&gt;User acceptance testing&lt;/li&gt;
  &lt;li&gt;Documentation update&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;3-data-migration-strategies&quot;&gt;3. Data Migration Strategies&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Database Migration:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;For Large Databases:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# AWS DMS example&lt;/span&gt;
aws dms create-replication-instance &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--replication-instance-identifier&lt;/span&gt; myrepinstance &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
  &lt;span class=&quot;nt&quot;&gt;--replication-instance-class&lt;/span&gt; dms.t2.micro
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;For Application Data:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Rsync untuk file systems&lt;/li&gt;
  &lt;li&gt;Storage gateway untuk gradual migration&lt;/li&gt;
  &lt;li&gt;Application-level replication&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;monitoring-dan-validasi&quot;&gt;Monitoring dan Validasi&lt;/h2&gt;

&lt;h3 id=&quot;1-key-metrics&quot;&gt;1. Key Metrics&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Performance Metrics:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Response time&lt;/li&gt;
  &lt;li&gt;Throughput&lt;/li&gt;
  &lt;li&gt;Error rates&lt;/li&gt;
  &lt;li&gt;Resource utilization&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Business Metrics:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;User satisfaction&lt;/li&gt;
  &lt;li&gt;Availability&lt;/li&gt;
  &lt;li&gt;Transaction volume&lt;/li&gt;
  &lt;li&gt;Revenue impact&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Cost Metrics:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Monthly spend&lt;/li&gt;
  &lt;li&gt;Resource efficiency&lt;/li&gt;
  &lt;li&gt;ROI tracking&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;2-monitoring-setup&quot;&gt;2. Monitoring Setup&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Infrastructure Monitoring:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c1&quot;&gt;# CloudWatch example&lt;/span&gt;
&lt;span class=&quot;na&quot;&gt;MetricFilters&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
  &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;FilterName&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;ErrorCount&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;FilterPattern&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;[timestamp,&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;request_id,&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s&quot;&gt;level=&lt;/span&gt;&lt;span class=&quot;se&quot;&gt;\&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;ERROR&lt;/span&gt;&lt;span class=&quot;se&quot;&gt;\&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;]&quot;&lt;/span&gt;
    &lt;span class=&quot;na&quot;&gt;MetricTransformations&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;MetricNamespace&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;Application/Logs&quot;&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;MetricName&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;ErrorCount&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Application Monitoring:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;APM tools (New Relic, Datadog, AppDynamics)&lt;/li&gt;
  &lt;li&gt;Custom metrics&lt;/li&gt;
  &lt;li&gt;Log aggregation&lt;/li&gt;
  &lt;li&gt;Distributed tracing&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;skenario-khusus&quot;&gt;Skenario Khusus&lt;/h2&gt;

&lt;h3 id=&quot;cloud-to-cloud-migration&quot;&gt;Cloud-to-Cloud Migration&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Tambahan Considerations:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Cross-cloud networking (peering, transit gateway)&lt;/li&gt;
  &lt;li&gt;Data transfer costs&lt;/li&gt;
  &lt;li&gt;Service mapping antar providers&lt;/li&gt;
  &lt;li&gt;Vendor lock-in assessment&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Tools Khusus:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Rclone untuk storage migration&lt;/li&gt;
  &lt;li&gt;Cloud-native migration services&lt;/li&gt;
  &lt;li&gt;Third-party migration platforms&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;on-premise-to-cloud&quot;&gt;On-Premise to Cloud&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Network Considerations:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Bandwidth requirements untuk data transfer&lt;/li&gt;
  &lt;li&gt;Hybrid connectivity planning&lt;/li&gt;
  &lt;li&gt;Latency impact assessment&lt;/li&gt;
  &lt;li&gt;Security compliance untuk data in transit&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Legacy Application Challenges:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;OS compatibility&lt;/li&gt;
  &lt;li&gt;License portability&lt;/li&gt;
  &lt;li&gt;Hardware dependency&lt;/li&gt;
  &lt;li&gt;Integration points&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;common-pitfalls-dan-mitigasi&quot;&gt;Common Pitfalls dan Mitigasi&lt;/h2&gt;

&lt;h3 id=&quot;1-underestimating-complexity&quot;&gt;1. Underestimating Complexity&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Masalah:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Dependencies tidak teridentifikasi&lt;/li&gt;
  &lt;li&gt;Performance degradation&lt;/li&gt;
  &lt;li&gt;Security gaps&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Mitigasi:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Thorough discovery process&lt;/li&gt;
  &lt;li&gt;Proof of concept untuk critical applications&lt;/li&gt;
  &lt;li&gt;Security assessment di setiap phase&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;2-inadequate-testing&quot;&gt;2. Inadequate Testing&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Masalah:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Functionality breaks di production&lt;/li&gt;
  &lt;li&gt;Performance issues&lt;/li&gt;
  &lt;li&gt;Data corruption&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Mitigasi:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Comprehensive testing strategy&lt;/li&gt;
  &lt;li&gt;Load testing di cloud environment&lt;/li&gt;
  &lt;li&gt;Data validation procedures&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;3-poor-change-management&quot;&gt;3. Poor Change Management&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Masalah:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;User resistance&lt;/li&gt;
  &lt;li&gt;Process disruption&lt;/li&gt;
  &lt;li&gt;Knowledge gaps&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Mitigasi:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Training programs&lt;/li&gt;
  &lt;li&gt;Clear communication&lt;/li&gt;
  &lt;li&gt;Phased rollout&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;fokus-area-kritis&quot;&gt;Fokus Area Kritis&lt;/h2&gt;

&lt;h3 id=&quot;1-security&quot;&gt;1. Security&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Non-Negotiable:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Data encryption&lt;/li&gt;
  &lt;li&gt;Access controls&lt;/li&gt;
  &lt;li&gt;Network security&lt;/li&gt;
  &lt;li&gt;Compliance requirements&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;2-performance&quot;&gt;2. Performance&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Monitoring Kontinyu:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Baseline comparison&lt;/li&gt;
  &lt;li&gt;Bottleneck identification&lt;/li&gt;
  &lt;li&gt;Capacity planning&lt;/li&gt;
  &lt;li&gt;Optimization opportunities&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;3-cost-management&quot;&gt;3. Cost Management&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Ongoing Activities:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Resource right-sizing&lt;/li&gt;
  &lt;li&gt;Reserved instance planning&lt;/li&gt;
  &lt;li&gt;Cost allocation tracking&lt;/li&gt;
  &lt;li&gt;Waste identification&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;metrics-keberhasilan&quot;&gt;Metrics Keberhasilan&lt;/h2&gt;

&lt;h3 id=&quot;technical-success-metrics&quot;&gt;Technical Success Metrics&lt;/h3&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Availability&lt;/strong&gt;: Target 99.9% atau sesuai SLA&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Performance&lt;/strong&gt;: Tidak lebih dari 10% degradation&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Security&lt;/strong&gt;: Zero security incidents&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Data Integrity&lt;/strong&gt;: 100% data consistency&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;business-success-metrics&quot;&gt;Business Success Metrics&lt;/h3&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: Sesuai dengan project timeline&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Budget&lt;/strong&gt;: Dalam budget allocation&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;User Satisfaction&lt;/strong&gt;: Minimal impact pada user experience&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;ROI&lt;/strong&gt;: Positive return dalam 12-18 bulan&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;post-migration-activities&quot;&gt;Post-Migration Activities&lt;/h2&gt;

&lt;h3 id=&quot;1-optimization&quot;&gt;1. Optimization&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cost Optimization:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Right-sizing instances&lt;/li&gt;
  &lt;li&gt;Reserved capacity planning&lt;/li&gt;
  &lt;li&gt;Lifecycle policies&lt;/li&gt;
  &lt;li&gt;Resource scheduling&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Performance Optimization:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Auto-scaling configuration&lt;/li&gt;
  &lt;li&gt;Caching strategies&lt;/li&gt;
  &lt;li&gt;Database optimization&lt;/li&gt;
  &lt;li&gt;Network optimization&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;2-governance&quot;&gt;2. Governance&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Ongoing Processes:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Cost reviews&lt;/li&gt;
  &lt;li&gt;Security assessments&lt;/li&gt;
  &lt;li&gt;Performance reviews&lt;/li&gt;
  &lt;li&gt;Capacity planning&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;kesimpulan&quot;&gt;Kesimpulan&lt;/h2&gt;

&lt;p&gt;Migrasi cloud yang sukses memerlukan pendekatan sistematis dengan fokus pada perencanaan detail, eksekusi bertahap, dan monitoring berkelanjutan. Kunci utamanya adalah:&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;&lt;strong&gt;Assessment yang menyeluruh&lt;/strong&gt; - Pahami sepenuhnya apa yang akan dimigrasikan&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Planning yang realistis&lt;/strong&gt; - Buat timeline dan budget yang reasonable&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Testing yang comprehensive&lt;/strong&gt; - Test everything, trust nothing&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Execution yang bertahap&lt;/strong&gt; - Migrate in waves, not big bang&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Monitoring yang berkelanjutan&lt;/strong&gt; - Keep watching everything&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Ingat, migrasi cloud bukan project yang berakhir setelah go-live. Ini adalah beginning dari cloud journey yang memerlukan continuous improvement dan optimization. Yang terpenting, jangan terburu-buru dan selalu prepare untuk rollback scenario jika something goes wrong.&lt;/p&gt;

&lt;h2 id=&quot;troubleshooting-common-issues&quot;&gt;Troubleshooting Common Issues&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Performance Degradation Post-Migration:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Root Cause&lt;/strong&gt;: Incorrect instance sizing, network latency, storage IOPS limitations&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Solution&lt;/strong&gt;: Performance baseline comparison, right-sizing analysis, storage optimization&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Prevention&lt;/strong&gt;: Thorough performance testing in staging environment&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Data Consistency Issues:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Root Cause&lt;/strong&gt;: Replication lag, incomplete synchronization, application-level inconsistencies&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Solution&lt;/strong&gt;: Data validation scripts, checksum verification, transaction log analysis&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Prevention&lt;/strong&gt;: Zero-downtime migration strategies, database migration best practices&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Network Connectivity Problems:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Root Cause&lt;/strong&gt;: Security group misconfigurations, DNS resolution issues, routing problems&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Solution&lt;/strong&gt;: Network path analysis, security group audit, DNS propagation verification&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Prevention&lt;/strong&gt;: Network testing in isolated environments, gradual traffic shifting&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Application Integration Failures:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Root Cause&lt;/strong&gt;: API endpoint changes, authentication issues, dependency version conflicts&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Solution&lt;/strong&gt;: Integration testing suites, API compatibility checks, dependency mapping&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Prevention&lt;/strong&gt;: Comprehensive integration testing, API versioning strategies&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;key-success-factors&quot;&gt;Key Success Factors&lt;/h2&gt;

&lt;h3 id=&quot;technical-excellence&quot;&gt;Technical Excellence&lt;/h3&gt;
&lt;ol&gt;
  &lt;li&gt;&lt;strong&gt;Comprehensive Planning&lt;/strong&gt;: 60% of migration success depends on upfront planning&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Automation First&lt;/strong&gt;: Manual processes don’t scale and introduce human errors&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Testing Everything&lt;/strong&gt;: If it’s not tested, it will fail in production&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Monitoring from Day Zero&lt;/strong&gt;: Observability must be built-in, not bolted-on&lt;/li&gt;
&lt;/ol&gt;

&lt;h3 id=&quot;organizational-readiness&quot;&gt;Organizational Readiness&lt;/h3&gt;
&lt;ol&gt;
  &lt;li&gt;&lt;strong&gt;Executive Sponsorship&lt;/strong&gt;: Migration needs strong leadership support&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Cross-functional Teams&lt;/strong&gt;: Include business stakeholders, not just technical teams&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Change Management&lt;/strong&gt;: User training and communication are critical&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Risk Management&lt;/strong&gt;: Have contingency plans for every major component&lt;/li&gt;
&lt;/ol&gt;

&lt;h3 id=&quot;process-discipline&quot;&gt;Process Discipline&lt;/h3&gt;
&lt;ol&gt;
  &lt;li&gt;&lt;strong&gt;Wave-based Approach&lt;/strong&gt;: Never attempt big-bang migrations&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Documentation Standards&lt;/strong&gt;: Every decision and configuration must be documented&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Communication Cadence&lt;/strong&gt;: Regular updates to all stakeholders&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Continuous Improvement&lt;/strong&gt;: Learn from each wave and improve the next&lt;/li&gt;
&lt;/ol&gt;

&lt;h2 id=&quot;final-reality-check&quot;&gt;Final Reality Check&lt;/h2&gt;

&lt;p&gt;Migrasi cloud yang sukses memerlukan:&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;12-24 bulan&lt;/strong&gt; untuk enterprise-scale migrations&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;20-30% budget buffer&lt;/strong&gt; untuk unexpected issues&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Dedicated team&lt;/strong&gt; dengan cloud expertise&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Executive patience&lt;/strong&gt; untuk proper execution&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Yang tidak boleh dikompromi:&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Security dan compliance requirements&lt;/li&gt;
  &lt;li&gt;Data integrity dan business continuity&lt;/li&gt;
  &lt;li&gt;Performance benchmarks&lt;/li&gt;
  &lt;li&gt;Rollback capabilities&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Yang bisa difleksibel:&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Timeline (better safe than sorry)&lt;/li&gt;
  &lt;li&gt;Scope (prioritize based on business value)&lt;/li&gt;
  &lt;li&gt;Technology choices (use what works, not what’s trendy)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Ingat: Migration adalah marathon, bukan sprint. Success diukur tidak hanya dari technical metrics, tapi juga business outcomes dan user satisfaction. Plan carefully, execute methodically, monitor continuously.&lt;/p&gt;

&lt;p&gt;Tidak ada silver bullet dalam migrasi cloud. Yang ada adalah hard work, proper planning, execution yang disciplined, dan team yang committed untuk success jangka panjang.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Cuti Panjang</title>
   <link href="https://robee.id/2021/11/15/cuti-panjang"/>
   <updated>2021-11-15T00:00:00+07:00</updated>
   <id>https://robee.id/2021/11/15/cuti-panjang</id>
   <content type="html">&lt;p&gt;&lt;img src=&quot;https://images.unsplash.com/photo-1496438164591-c1fdd6e4b8cf?ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&amp;amp;ixlib=rb-1.2.1&amp;amp;auto=format&amp;amp;fit=crop&amp;amp;w=720&amp;amp;q=80&quot; alt=&quot;Leyehan&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Bekerja super keras tanpa henti selama hampir 17 tahun membuat saya cukup lelah. Selain mental yang sudah tidak lagi sama, keinginan untuk maju yang seharusnya persisten sudah tidak berada pada level terbaik. Yang saya pahami selama ini, determinasi dalam bekerja seharusnya ada pada level terbaik.&lt;/p&gt;

&lt;p&gt;Dalam kondisi lelah, duduk dan beristirahatlah.&lt;/p&gt;

&lt;p&gt;Kredit Gambar : &lt;a href=&quot;https://unsplash.com/@janpadilla&quot;&gt;Jan Padila&lt;/a&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Continuous Testing Kafka with Xinfra Monitor in Kubernetes</title>
   <link href="https://robee.id/2021/10/06/kafka-monitor"/>
   <updated>2021-10-06T00:00:00+07:00</updated>
   <id>https://robee.id/2021/10/06/kafka-monitor</id>
   <content type="html">&lt;p&gt;Monitors kafka as part of continuously cheking how the cluster performs. The challenge with this is to create script to produce and consume
with some ludicrous amount of works. Instead of creating stuff in house, a mate refering a fancy tool called Kafka Monitor.&lt;/p&gt;

&lt;p&gt;Kafka monitor, or now known as &lt;a href=&quot;https://github.com/linkedin/kafka-monitor&quot;&gt;Xinfra Monitor&lt;/a&gt; is an open source software created by folks in Linkedin. 
This tools provide the produce, consume and offset test and measurement.&lt;br /&gt;
The fun part here, is Jolokia. So, Xinfra Monitor (Kafka Monitor), expose mbeans through Jolokia, so it can be accessed easily by any monitoring tools like Prometheus (plus Jolokia Exporter) or paid one like Datadog.&lt;/p&gt;

&lt;h1 id=&quot;kafka-xinfra-monitor-deployment&quot;&gt;Kafka Xinfra Monitor Deployment&lt;/h1&gt;
&lt;p&gt;In this case I would use kubernetes cluster to host the xinfra monitor, and also use strimzi as kafka and zookeeper operator. For the sake of simplicity, I will host everything on the kubernetes, minikube -in this example.&lt;/p&gt;

&lt;p&gt;Prerequisites :&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;
    &lt;table&gt;
      &lt;tbody&gt;
        &lt;tr&gt;
          &lt;td&gt;Minikube&lt;/td&gt;
          &lt;td&gt;&lt;a href=&quot;https://minikube.sigs.k8s.io/docs/start/&quot;&gt;ref&lt;/a&gt;&lt;/td&gt;
        &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;table&gt;
      &lt;tbody&gt;
        &lt;tr&gt;
          &lt;td&gt;Kafka and Zookeeper&lt;/td&gt;
          &lt;td&gt;&lt;a href=&quot;https://strimzi.io/docs/operators/in-development/quickstart.html#proc-kafka-cluster-str&quot;&gt;ref&lt;/a&gt;&lt;/td&gt;
        &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Nice to have locally :&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;jq&lt;/li&gt;
  &lt;li&gt;curl&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Base assumption :&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;kafka cluster endpoint : &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;my-cluster-kafka-bootstrap&lt;/code&gt;, Port : &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;9092&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;zookeeper cluster endpoint : &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;my-cluster-zookeeper-client&lt;/code&gt;, Port : &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;2181&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;Run xinfra monitor in single cluster monitoring mode&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;deploy-the-kafka-monitor--xinfra-monitor&quot;&gt;Deploy the Kafka Monitor / Xinfra Monitor&lt;/h2&gt;

&lt;h3 id=&quot;initial-steps-&quot;&gt;Initial steps :&lt;/h3&gt;
&lt;ul&gt;
  &lt;li&gt;
    &lt;p&gt;Clone source code&lt;/p&gt;

    &lt;p&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;git clone git@github.com:linkedin/kafka-monitor.git&lt;/code&gt;&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;Checkout to latest release tag. e.g&lt;/p&gt;

    &lt;p&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;git checkout 2.5.10&lt;/code&gt;&lt;/p&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;modify-the-dockerfile&quot;&gt;Modify the Dockerfile&lt;/h3&gt;
&lt;p&gt;If you can see. There is Dockerfile &lt;a href=&quot;https://github.com/linkedin/kafka-monitor/blob/2.5.10/docker/Dockerfile&quot;&gt;here&lt;/a&gt;.&lt;/p&gt;

&lt;div class=&quot;language-Dockerfile highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;k&quot;&gt;FROM&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; anapsix/alpine-java&lt;/span&gt;

&lt;span class=&quot;k&quot;&gt;MAINTAINER&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; coffeepac@gmail.com&lt;/span&gt;

&lt;span class=&quot;k&quot;&gt;WORKDIR&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; /opt/kafka-monitor&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; build/ build/&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; bin/xinfra-monitor-start.sh bin/xinfra-monitor-start.sh&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; bin/kmf-run-class.sh bin/kmf-run-class.sh&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; config/xinfra-monitor.properties config/xinfra-monitor.properties&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; config/log4j2.properties config/log4j2.properties&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; docker/kafka-monitor-docker-entry.sh kafka-monitor-docker-entry.sh&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; webapp/ webapp/&lt;/span&gt;

&lt;span class=&quot;k&quot;&gt;CMD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; [&quot;/opt/kafka-monitor/kafka-monitor-docker-entry.sh&quot;]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;blockquote&gt;
  &lt;p&gt;&lt;strong&gt;Side note&lt;/strong&gt; : in the Dockerfile above, you will find out that the container will use the properties which can be configured in &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;config/xinfra-monitor.properties&lt;/code&gt;. With this config, you can set the configuration in granular way, also possible for you to monitor multiple kafka cluster - which I don’t really need in this case. Much better way to do this approach, is to convert the config file to kubernetes configmap.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;In my case, I will not use the default Dockerfile approach, since I only want to monitor a single Kafka Cluster. So I modified the Dockerfile to this :&lt;/p&gt;

&lt;div class=&quot;language-Dockerfile highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;k&quot;&gt;FROM&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; anapsix/alpine-java&lt;/span&gt;

&lt;span class=&quot;k&quot;&gt;WORKDIR&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; /opt/kafka-monitor&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; build/ build/&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; bin/single-cluster-monitor.sh bin/single-cluster-monitor.sh&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; bin/kmf-run-class.sh bin/kmf-run-class.sh&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;ADD&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; config/log4j2.properties config/log4j2.properties&lt;/span&gt;

&lt;span class=&quot;k&quot;&gt;ENTRYPOINT&lt;/span&gt;&lt;span class=&quot;s&quot;&gt; [&quot;/opt/kafka-monitor/bin/single-cluster-monitor.sh&quot;]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id=&quot;build-docker-image&quot;&gt;Build Docker image&lt;/h3&gt;

&lt;ul&gt;
  &lt;li&gt;
    &lt;p&gt;Build the docker image using existing makefile (yea you can use a vanilla docker build command too)&lt;/p&gt;

    &lt;pre&gt;&lt;code class=&quot;language-Bash&quot;&gt;# Go to the docker folder - inside the kafka-monitor repo
cd docker
PREFIX=robeevanjava/kafka-monitor TAG=v2.5.10 make container
&lt;/code&gt;&lt;/pre&gt;

    &lt;p&gt;You can change the &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;PREFIX&lt;/code&gt; environment variable with your docker hub username or even to quay.io. Change the tag to any version you want.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;Push the docker image to docker registry&lt;/p&gt;

    &lt;pre&gt;&lt;code class=&quot;language-Bash&quot;&gt;  docker push robeevanjava/kafka-monitor:v2.5.10
&lt;/code&gt;&lt;/pre&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;deploying-the-kubernetes-objects&quot;&gt;Deploying the Kubernetes Objects&lt;/h3&gt;

&lt;p&gt;I have create the kubernetes manifest here: &lt;a href=&quot;https://gist.githubusercontent.com/robertusnegoro/b2a029811ee63725212dabaab38b4fa4/raw/479c86d04291c044feb92d50e78cf73fa80268a1/xinfra-monitor-k8s.yaml&quot;&gt;xinfra-monitor-manifest.yaml&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you want to use exactly that manifest mentioned above, just do&lt;/p&gt;

&lt;pre&gt;&lt;code class=&quot;language-Bash&quot;&gt;kubectl apply -f https://git.io/JwLDr -n kafka-monitor
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;If you need to change the kafka and zookeeper cluster, please change the argument lines here :&lt;/p&gt;

&lt;div class=&quot;language-yaml highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;      &lt;span class=&quot;na&quot;&gt;containers&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
      &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;kafka-monitor&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;image&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;robeevanjava/kafka-monitor:v2.5.10&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;imagePullPolicy&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;Always&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;env&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;pi&quot;&gt;[]&lt;/span&gt;
        &lt;span class=&quot;na&quot;&gt;args&lt;/span&gt;&lt;span class=&quot;pi&quot;&gt;:&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;--topic&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;kafkamonitor-topic-test&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;--broker-list&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;my-cluster-kafka-bootstrap.kafka.svc.cluster.local:9092&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;--zookeeper&lt;/span&gt;
        &lt;span class=&quot;pi&quot;&gt;-&lt;/span&gt; &lt;span class=&quot;s&quot;&gt;my-cluster-zookeeper-client.kafka.svc.cluster.local:2181&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;em&gt;Change the topic, broker-list and zookeeper parameter accordingly.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;In the manifest I only expose 1 port on the kubernetes service, and that is for Jolokia &lt;a href=&quot;https://jolokia.org/documentation.html&quot;&gt;ref&lt;/a&gt;, a software that exposing mbeans to http. So it enable us to query the mbeans metric through http request, with json returning value.&lt;/p&gt;

&lt;p&gt;To find the available metric, try to do these steps :&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;
    &lt;p&gt;Do port-forwarding to jolokia service port&lt;/p&gt;

    &lt;pre&gt;&lt;code class=&quot;language-Bash&quot;&gt;  kubectl port-forward svc/kafka-monitor 8778:8778 -n kafka-monitor
&lt;/code&gt;&lt;/pre&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;Make request to jolokia port&lt;/p&gt;

    &lt;pre&gt;&lt;code class=&quot;language-Bash&quot;&gt;  # Get list of available metric
  curl &quot;http://localhost:8778/jolokia/list&quot;
  # Json pretty print 
   curl &quot;http://localhost:8778/jolokia/list&quot; | jq .
  # Read to a sample metric
  curl &quot;http://localhost:8778/jolokia/read/kafka.consumer:client-id=kmf-consumer,type=consumer-metrics&quot;
&lt;/code&gt;&lt;/pre&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now you have kafka monitor run on your kubernetes cluster.&lt;/p&gt;

&lt;h2 id=&quot;optional-steps&quot;&gt;Optional Steps&lt;/h2&gt;

&lt;p&gt;Some of the organization uses prometheus as “default” observability toolings. We can use &lt;a href=&quot;https://github.com/Scalify/jolokia_exporter&quot;&gt;jolokia-exporter&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;You can clone the repo and build your very own Jolokia docker image and push it to your favourite container registry, but I will use the prebuilt one :)&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I have kubernetes manifest &lt;a href=&quot;https://gist.githubusercontent.com/robertusnegoro/68afab1983e8cbeeb8a1b936f2362821/raw/f5c28949096d25aa2521c4b442229408f1071fe9/jolokia-exporter.yaml&quot;&gt;here&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;So to apply it, run&lt;/p&gt;

&lt;pre&gt;&lt;code class=&quot;language-Bash&quot;&gt;kubectl apply -f https://git.io/JwLim -n kafka-monitor
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Then you can just do either &lt;a href=&quot;https://github.com/prometheus-operator/prometheus-operator/blob/master/Documentation/user-guides/getting-started.md#include-servicemonitors&quot;&gt;ServiceMonitor&lt;/a&gt; or write a prometheus scrape config like explained in the example &lt;a href=&quot;https://github.com/Scalify/jolokia_exporter#readme&quot;&gt;here&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;PS : If the git.io URL is broken, please refer to each linked gist file above :D&lt;/p&gt;
&lt;/blockquote&gt;
</content>
 </entry>
 
 <entry>
   <title>TIL : 2020-07-19</title>
   <link href="https://robee.id/2021/07/19/til-2020-07-19"/>
   <updated>2021-07-19T04:41:13+07:00</updated>
   <id>https://robee.id/2021/07/19/til-2020-07-19</id>
   <content type="html">&lt;p&gt;Mencoba untuk pasang gitlab runner menggunakan helm chart seperti tutorialnya di sini : &lt;a href=&quot;https://docs.gitlab.com/runner/install/kubernetes.html&quot;&gt;https://docs.gitlab.com/runner/install/kubernetes.html&lt;/a&gt;&lt;br /&gt;
Saya baru sadar jika kita butuh menambahkan role cluster-admin untuk service account default gitlab (jika kita tidak mendefinisikannya di values.yaml)&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
  name: cluster-admin
  namespace: gitlab
subjects:
  - kind: ServiceAccount
    name: default
    namespace: gitlab
roleRef:
  apiGroup: rbac.authorization.k8s.io
  kind: ClusterRole
  name: cluster-admin
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

</content>
 </entry>
 
 <entry>
   <title>Euro 2020, Inggris dan Downtime</title>
   <link href="https://robee.id/2021/06/15/euro-2021-inggris-dan-downtime"/>
   <updated>2021-06-15T04:35:24+07:00</updated>
   <id>https://robee.id/2021/06/15/euro-2021-inggris-dan-downtime</id>
   <content type="html">&lt;p&gt;Bagi para pecinta sepakbola, selama beberapa pekan ke depan, kita semua akan dimanjakan dengan tontonan olahraga populer nan berkualitas dari dua kompetisi antar negara. Yang pertama Copa America 2021 - turnamen yang digelar oleh CONMEBOL dengan peserta negara - negara Amerika Selatan. Turnamen ini disiarkan secara daring oleh vidio.com dan sudah dibuka dengan kemenangan Brasil sebagai juara bertahan. Yang satu lagi, Euro 2020 - turnamen yang digelar oleh UEFA, diikuti oleh negara benua eropa termasuk Rusia. Sebagai episentrum liga - liga terbaik dunia, pagelaran ini ditunggu oleh masyarakat. Euro 2020 yang digelar di tahun 2021 ini, disiarkan oleh mola.tv, sebuah platform OTT daring yang masih cukup muda, dan didukung oleh pabrikan besar ternama, yaitu Polytron. Euro 2020 sudah dimulai terlebih dahulu dan dibuka dengan kemenangan Italia atas Turki, pada tanggal 12 Juni 2021 lalu.&lt;/p&gt;

&lt;p&gt;Euro sebagai turnamen dengan sejarah panjang ini, belum genap berjalan sepekan, namun sudah banyak hal terjadi di beberapa hari kebelakang ini. Mulai dari kemenangan telak Italia, insiden terjatuhnya Christian Eriksen di lapangan (get well soon, Eriksen!), laga dramatis Belanda melawan Ukraina, selebrasi rasial dari Arnautovic sampai gol indah Patrick Schick. Yang paling epik dan dirasakan sangat mengesalkan (termasuk saya), adalah insiden pada saat laga perdana Inggris di kompetisi Euro 2020 ini. Laga tersebut sangat ditunggu dan diantisipasi warga pecinta bola, telaknya lagi, laga itu jatuh di akhir pekan. Bukan insiden di dalam lapangan, melainkan, terjadinya gangguan yang membuat para pelanggan Mola.tv tidak bisa menyaksikan pasukan Gareth Southgate. Saya berulang kali mencoba untuk masuk melalui web dan android app, namun hasilnya saya tetap mendapatkan gangguan yang sama.&lt;/p&gt;

&lt;p&gt;Akhir pekan, Inggris dan waktu primer (prime time) adalah kombinasi cukup mematikan untuk platform streaming semacam Mola.tv . Seperti yang kita tahu, Inggris dan Liga Primer-nya adalah liga terpopuler di negara kita. Hal yang sama juga pernah terjadi ketika laga Malaysia melawan Indonesia, Persija melawan Persib di platform saingannya, vidio.com. Bedanya, vidio.com tidak mengalami insiden seburuk mola.tv. Sebagai orang di luar organisasi Mola, tentu saya tidak tahu penyebab utama dari insiden di hari itu. Yang bisa saya bayangkan, saat itu Mola sedang mengumpulkan tim teknis terkait dan berusaha “memadamkan” api yang sudah terlanjur menjalar.&lt;/p&gt;

&lt;p&gt;Sebenarnya untuk pengguna yang sudah terlanjur membuka atau mungkin para pengakses awal halaman Ingriss melawan Kroasia saat itu, akan dapat menikmati tayangan tersebut, asalkan tidak dimuat ulang lamannya. Sehingga ada beberapa pengguna Mola yang merasa tidak ada insiden atau hambatan seperti pengguna kebanyakan. Sekali lagi, ini bukanlah penyebab sesungguhnya, atau bahkan bukan hipotesa, namun sering kali pada kejadian lumpuhnya halaman streaming yang disertai dengan melonjaknya trafik, jarang terjadi bottleneck pada “streaming” nya itu sendiri. Biasanya live streaming sudah ditangani oleh CDN sebagai komponen utama yang sanggup menangani trafik besar sekalipun.&lt;/p&gt;

&lt;p&gt;Lonjakan trafik ini biasanya berakibat cukup fatal terhadap service backend seperti API endpoint yang menangani proses bisnis dan fitur lain. Misalkan endpoint untuk mengecek legitimasi user, paket user, menyediakan umpan balik sebuah URL live stream yang tepat, sampai pada fitur live chat. Pada kasus mola.tv, tidak terdapat fitur live chat seperti di youtube atau vidio.com. Jika pada saat kejadian, anda membuka mola lewat web dan membuka developer tools, maka dapat dilihat ada beberapa API endpoint yang mengembalikan respon dengan kode error.&lt;/p&gt;

&lt;p&gt;Tanpa mengetahui apa detil yang terjadi di tim teknis mola.tv, penulis merasa bahwa pada setiap even besar, penting dilakukan beberapa persiapan, termasuk melibatkan tim bisnis dan produk. Biasanya tim tersebut mampu memprediksi seberapa besar trafik yang akan masuk dan menonton tayangan tersebut. Kemudian persiapan teknis apa yang bisa dilakukan tim infrastruktur bersama pemrogram?&lt;/p&gt;

&lt;h3 id=&quot;mempersiapkan-war-room&quot;&gt;Mempersiapkan &lt;em&gt;War Room&lt;/em&gt;&lt;/h3&gt;

&lt;p&gt;Pada tim teknis, sebaiknya mempersiapkan tim untuk bersiap (on-call standby) pada saat waktu berlangsungnya even besar tersebut. Dalam kasus super ideal, organisasi mempunyai tim &lt;em&gt;techops&lt;/em&gt; yang dapat mengumpulkan pihak - pihak terkait ke dalam sebuah &lt;em&gt;war room&lt;/em&gt;. Sehingga ketika terjadi insiden, semua pihak yang berkompeten, dapat dipanggil di satu tempat saja. Ini juga dapat memperpendek MTTR (mean time to resolve) pada insiden.&lt;/p&gt;

&lt;h3 id=&quot;autoscaling-tak-bisa-diandalkan&quot;&gt;Autoscaling Tak Bisa Diandalkan&lt;/h3&gt;

&lt;p&gt;Menurut pengalaman, kita tak lagi sanggup mengandalkan fitur autoscaling yang umumnya tersedia di platform - plaform orkestrasi atau cloud. Fitur autoscaling tak lagi handal untuk mengatasi gelombang kerusakan eksponensial akibat lonjakan trafik yang secara ekstrim sangat drastis. &lt;br /&gt;
Sebelum terjadinya even, hendaknya tim teknis mulai mempersiapkan peladen yang sudah &lt;em&gt;hot standby&lt;/em&gt; untuk melayani jumlah trafik yang melonjak tinggi. Selain itu, penting pula untuk menggarisbawahi metrik - metrik yang penting untuk dipantau, termasuk oleh pemrogram.&lt;/p&gt;

&lt;h3 id=&quot;memprediksi-bottleneck-pada-dependensi&quot;&gt;Memprediksi Bottleneck pada Dependensi&lt;/h3&gt;

&lt;p&gt;Setelah mengetahui bahwa &lt;em&gt;autoscaling&lt;/em&gt; tidak dapat diandalkan. Tim teknis juga harus dapat memprediksi limitasi dari sistem - sistem lain yang menjadi dependensi dari services yang akan diakses oleh pengguna. Entah itu database, atau sistem lain, bisa saja tidak mampu melayani trafik masuk sesuai ekspektasi, sehingga membutuhkan perubahan konfigurasi sebelum even besar dimulai. Biasanya tak mudah menambah kapasitas (&lt;em&gt;scaling up&lt;/em&gt;) dependensi, terutama &lt;em&gt;stateful dependency.&lt;/em&gt;  &lt;/p&gt;

&lt;p&gt;Beberapa hari setelah terjadi insiden tersebut, saya pribadi melihat Mola melakukan &lt;em&gt;crisis management&lt;/em&gt; dengan sangat baik, yaitu memberikan layanan gratis (liga primer Inggris) sebagai kompensasi atas insiden Inggris vs Kroasia.&lt;/p&gt;

&lt;p&gt;Dari persiapan di atas, mungkin ada yang kurang. Sila ditambahkan jika ada yang kurang dengan merespon laman ini ke kontak[at]robee.id&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>TIL : 2020-05-30</title>
   <link href="https://robee.id/2021/05/29/til-2020-05-30"/>
   <updated>2021-05-29T17:09:55+07:00</updated>
   <id>https://robee.id/2021/05/29/til-2020-05-30</id>
   <content type="html">&lt;p&gt;Sebagai bekal untuk siniar baru berbahasa Jawa Timur nanti, yang mana saya yakin akan banyak &lt;em&gt;pisuhan - pisuhan&lt;/em&gt; , penulis mempersiapkan cara untuk menyensor hal tersebut menggunakan kakas suara bernama Audacity.&lt;/p&gt;

&lt;figure class=&quot;kg-card kg-embed-card&quot;&gt;&lt;iframe width=&quot;200&quot; height=&quot;113&quot; src=&quot;https://www.youtube.com/embed/erA5KhPfy5Q?feature=oembed&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;&lt;/figure&gt;

&lt;p&gt;&lt;em&gt;nek pisuhan kabeh isine yok opo iki, rek!&lt;/em&gt;&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Tentang Replikasi Eksternal dari dan ke MySQL Google CloudSQL</title>
   <link href="https://robee.id/2021/05/29/tentang-replikasi-mysql-google-cloudsql"/>
   <updated>2021-05-29T16:33:11+07:00</updated>
   <id>https://robee.id/2021/05/29/tentang-replikasi-mysql-google-cloudsql</id>
   <content type="html">&lt;p&gt;Penulis ingin mengawali catatan kali ini dengan kisah jenaka, betapa lucunya peraturan negeri ini mengenai pusat data untuk industri finansial, tapi takut dan mungkin nirfaedah. Semoga seseorang yang bekerja di bidang yang sama, nanti, akan mampu menuliskan betapa jenakanya peraturan tersebut.&lt;/p&gt;

&lt;p&gt;Ya, meski kita tahu di Google CloudSQL (baik postgresql maupun mysql) kita dapat membuat replika, namun oleh karena aturan bahwa sebuah perusahaan yang bergerak di bidang finansial, harus membuat pusat data untuk pemulihan bencana (&lt;em&gt;Disaster Recovery Data Center),&lt;/em&gt; maka pada kasus ini, penulis dan tim infrastruktur, ditugaskan untuk mempersiapkan sebuah set komplit pada pusat data lain. Karena pusat data DR, maka harus selain Google Cloud Platform (sudah dipakai sebagai pusat data utama), bisa saja di sebuah VM di penyedia lain, seperti Alibaba Cloud, Biznet Gio/Neo atau merek lain. Pada aktivitas ini, komponen yang paling menjadi sorotan adalah klaster basis data, dalam hal ini MySQL Database Cluster.&lt;/p&gt;

&lt;p&gt;Tulisan ini tidak akan menjelaskan langkah per langkah, namun hanya merekam hal penting yang mungkin nanti akan membantu penulis kembali, jika menemui hal yang sama ke depannya. Pada tulisan ini, versi MySQL yang penulis gunakan adalah versi 8.0. Untuk detail petunjuk, akan penulis lampirkan tautan referensi di akhir artikel. Pada aspek yang lebih detil, penulis berkonsultasi dengan rekan ahli lainnya, yaitu &lt;a href=&quot;https://id.linkedin.com/in/hofid&quot;&gt;Hofid Mashudi&lt;/a&gt; dan &lt;a href=&quot;https://id.linkedin.com/in/agsyafaat&quot;&gt;Agus Syafaat&lt;/a&gt; (terima kasih teman temanku) * &lt;em&gt;gestur saranghaeyo&lt;/em&gt; *.&lt;/p&gt;

&lt;h3 id=&quot;replikasi-ke-replika-eksternal&quot;&gt;Replikasi ke Replika Eksternal&lt;/h3&gt;

&lt;p&gt;Pada skenario ini, kita akan mempunyai MySQL &lt;em&gt;primary instance&lt;/em&gt; di Google CloudSQL sedangkan untuk &lt;em&gt;replica instances&lt;/em&gt; ada di CloudSQL sendiri dan sebuah VM (sebuah VM berisi MySQL yang dipasang dan dikonfigurasi sendiri tanpa &lt;em&gt;managed service&lt;/em&gt;).&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;mysql vm replica ---- mysql cloudsql primary 
                         -- cloudsql replica
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Selain membuat MySQL di Google CloudSQL dan VM, langkah - langkahnya secara garis besar adalah sebagai berikut :&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;Membuat 1 &lt;em&gt;user&lt;/em&gt; untuk replikasi dengan &lt;em&gt;permission&lt;/em&gt; &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;REPLICATION SLAVE&lt;/code&gt; atau &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;REPLICATION CLIENT&lt;/code&gt; pada &lt;em&gt;primary instance&lt;/em&gt; di CloudSQL&lt;/li&gt;
  &lt;li&gt;Memastikan antara VM &lt;em&gt;replica&lt;/em&gt; dan CloudSQL dapat berkomunikasi di port 3306&lt;/li&gt;
  &lt;li&gt;Ekpor data dari &lt;em&gt;primary instance&lt;/em&gt; (CloudSQL) dengan mempertahankan GTID&lt;/li&gt;
  &lt;li&gt;Impor data dari hasil ekspor di atas ke replika di VM&lt;/li&gt;
  &lt;li&gt;Menyalin &lt;em&gt;server certificate&lt;/em&gt; dari &lt;em&gt;primary instance&lt;/em&gt; di CloudSQL ke VM &lt;em&gt;replica&lt;/em&gt;.&lt;/li&gt;
  &lt;li&gt;Set master di VM &lt;em&gt;replica&lt;/em&gt; dengan contoh &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;CHANGE MASTER TO MASTER_HOST = &apos;&apos;, MASTER_PORT = 3306, MASTER_USER = &apos;&apos;, MASTER_PASSWORD = &apos;&amp;lt;replica user&apos;s password&amp;gt;, MASTER_AUTO_POSITION = 1, MASTER_SSL = 1, MASTER_SSL_CA = &apos;/path/to/server-ca.pem&apos;;&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;START REPLICA&lt;/code&gt; dijalankan di VM &lt;em&gt;replica&lt;/em&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Cukup simpel dan tidak berbelit. Namun ada beberapa hal yang perlu diperhatikan pula. Pada kasus ini, kita harus memastikan &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;replication-ignore-db&lt;/code&gt; pada replika eksternal harus dapat diset dan dipasang &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;mysql&lt;/code&gt; sebagai nilainya. &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;replication-ignore-db = mysql&lt;/code&gt;. Sehingga, jika kita ingin melakukan replikasi misalkan antara mysql di cloudsql dan amazon RDS, kita harus pastikan dulu RDS support setup parameter ini atau tidak, jika tidak, maka replikasi tak dapat dilakukan. [1]&lt;/p&gt;

&lt;p&gt;Hal lain, adalah memastikan parameter &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;read_only&lt;/code&gt; di set ke &lt;strong&gt;ON&lt;/strong&gt; , pada replika. Jika perlu, setelah setup selesai, kita set &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;super_read_only&lt;/code&gt; untuk menghindari “&lt;em&gt;errant transaction&lt;/em&gt;” [2]&lt;/p&gt;

&lt;h3 id=&quot;replikasi-dari-eksternal-external-masterprimary&quot;&gt;Replikasi dari Eksternal (&lt;em&gt;External Master/Primary&lt;/em&gt;)&lt;/h3&gt;

&lt;p&gt;Salah satu aspek penilaian auditor terhadap kesiapan sistem, pada produk - produk teknologi finansial (tekfin / &lt;em&gt;fintech&lt;/em&gt;) salah satunya adalah &lt;em&gt;data center swing&lt;/em&gt; atau secara sederhana, melakukan simulasi jika terjadi bencana, dan pusat data cadangan akan menjadi yang utama. Dari sisi &lt;em&gt;database&lt;/em&gt;, maka hal ini sesederhana membalik skenario di atas dari cloudsql sebagai &lt;em&gt;primary instance&lt;/em&gt; dan VM sebagai replika. Sehingga VM sekarang sebagai &lt;em&gt;primary instance&lt;/em&gt; sedangkan mysql di CloudSQL menjadi replika. Prosedur lengkap ada di referensi bawah [3], namun secara ringkas dapat ditulis sebagai berikut :&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;Membuat 1 &lt;em&gt;user&lt;/em&gt; untuk replikasi dengan &lt;em&gt;permission&lt;/em&gt; &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;REPLICATION SLAVE&lt;/code&gt; atau &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;REPLICATION CLIENT&lt;/code&gt; pada VM mysql replika&lt;/li&gt;
  &lt;li&gt;Membuat “_ &lt;strong&gt;source representation&lt;/strong&gt; _” pada Google CloudSQL [4]&lt;/li&gt;
  &lt;li&gt;Melakukan prosedur &lt;em&gt;demote&lt;/em&gt; pada mysql instance di CloudSQL (yang tadinya adalah primary)&lt;/li&gt;
  &lt;li&gt;eksekusi &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;STOP REPLICA&lt;/code&gt; dan &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;RESET REPLICA ALL&lt;/code&gt; pada mysql di VM (yang saat ini jadi master)&lt;/li&gt;
  &lt;li&gt;set parameter &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;read_only&lt;/code&gt; (dan &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;super_read_only&lt;/code&gt;) menjadi &lt;strong&gt;OFF&lt;/strong&gt; pada mysql di VM&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Sesederhana itu. Pada aktivitas ini, yang paling harus diperhatikan adalah pada saat pembuatan &lt;em&gt;source representation&lt;/em&gt; dan prosedur &lt;em&gt;demotion&lt;/em&gt; , untuk :&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;memastikan memasukkan &lt;em&gt;server certificate&lt;/em&gt; milik mysql di VM dengan tepat&lt;/li&gt;
  &lt;li&gt;memastikan mysql di CloudSQL tidak punya CLoudSQL &lt;em&gt;replica&lt;/em&gt; lagi. [5]&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Jika terdapat replika pada sisi CloudSQL, maka yang terjadi, akan ada &lt;em&gt;return error&lt;/em&gt; seperti ini :&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;{
  &quot;error&quot;: {
    &quot;code&quot;: 400,
    &quot;message&quot;: &quot;The requested operation is not valid for an instance that has a replica.&quot;,
    &quot;errors&quot;: [
      {
        &quot;message&quot;: &quot;The requested operation is not valid for an instance that has a replica.&quot;,
        &quot;domain&quot;: &quot;global&quot;,
        &quot;reason&quot;: &quot;badRequest&quot;
      }
    ]
  }
}
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id=&quot;monitoring&quot;&gt;Monitoring&lt;/h3&gt;

&lt;p&gt;Pada kedua aktivitas di atas, pastikan kondisi replikasi selalu dalam pantauan.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Tetap memantau &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Second Behind Source&lt;/code&gt; tetap 0 di hasil output dari perintah &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;SHOW REPLICA STATUS\G&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;Cek kondisi replika dari sisi &lt;em&gt;primary instance&lt;/em&gt; &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;SHOW SLAVE HOSTS&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;Cek GTID di &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;SHOW MASTER STATUS&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;Jika memungkinkan, pantau metrik ini pada kakas pemantauan (&lt;em&gt;monitoring tools&lt;/em&gt;) seperti Grafana + Prometheus atau Stackdriver Monitoring atau AWS Cloudwatch atau Datadog dll.&lt;/li&gt;
  &lt;li&gt;Pastikan retensi binlog pada &lt;em&gt;primary instance&lt;/em&gt; dihitung dengan benar disesuaikan kebutuhan replikasi dan kondisi &lt;em&gt;network&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Jika ada yang pertanyaan atau masukan, dengan senang hati dapat berdikusi di kontak[at]robee.id.&lt;/p&gt;

&lt;p&gt;* &lt;em&gt;nonton drakor lagi&lt;/em&gt; *&lt;/p&gt;

&lt;h3 id=&quot;referensi&quot;&gt;Referensi:&lt;/h3&gt;

&lt;ol&gt;
  &lt;li&gt;&lt;a href=&quot;https://cloud.google.com/sql/docs/mysql/replication/configure-external-replica&quot;&gt;https://cloud.google.com/sql/docs/mysql/replication/configure-external-replica&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://cloud.google.com/sql/docs/mysql/replication/replication-from-external&quot;&gt;https://cloud.google.com/sql/docs/mysql/replication/replication-from-external&lt;/a&gt; [3], [4], [5]&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://cloud.google.com/sql/docs/mysql/replication&quot;&gt;https://cloud.google.com/sql/docs/mysql/replication&lt;/a&gt; [1]&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://cloud.google.com/sql/docs/mysql/import-export/exporting&quot;&gt;https://cloud.google.com/sql/docs/mysql/import-export/exporting&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://dzone.com/articles/mysql-replication-errant-transactions-in-gtid-base&quot;&gt;https://dzone.com/articles/mysql-replication-errant-transactions-in-gtid-base&lt;/a&gt; [2]&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Post image by &lt;a href=&quot;https://unsplash.com/@kellysikkema?utm_source=unsplash&amp;amp;utm_medium=referral&amp;amp;utm_content=creditCopyText&quot;&gt;Kelly Sikkema&lt;/a&gt; on &lt;a href=&quot;https://unsplash.com/s/photos/note?utm_source=unsplash&amp;amp;utm_medium=referral&amp;amp;utm_content=creditCopyText&quot;&gt;Unsplash&lt;/a&gt;&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Hal Kontraproduktif Ketika Migrasi ke Cloud</title>
   <link href="https://robee.id/2021/01/14/hal-kontraproduktif-ketika-migrasi-ke-cloud"/>
   <updated>2021-01-14T06:49:48+07:00</updated>
   <id>https://robee.id/2021/01/14/hal-kontraproduktif-ketika-migrasi-ke-cloud</id>
   <content type="html">&lt;p&gt;Pada medio 2020 lalu, Bukalapak Engineering telah berhasil menyelesaikan proyek yang sangat penting dalam pendewasaan tim, baik secara teknologi, maupun secara organisasi. Proyek penting itu adalah migrasi infrastruktur dari data center on-premise ke cloud provider bernama Google Cloud Platform (GCP). Sebenarnya sudah ada 3 artikel yang lebih dahulu membahas proyek yang secara internal dinamakan Gatotkaca ini, 1 artikel di linkedin yang membahas hal yang &lt;a href=&quot;https://www.linkedin.com/pulse/what-i-learned-out-bukalapaks-cloud-migration-ichsan-rahardianto/&quot;&gt;dipelajari oleh seorang TPM saat itu - Ichsan Rahardianto&lt;/a&gt;, 2 artikel lain di GCP Blog, yang pertama soal cloud migration 101 yang &lt;a href=&quot;https://cloud.google.com/blog/products/cloud-migration/guide-to-all-google-cloud-migration-guides&quot;&gt;dijabarkan dengan sangat baik oleh Mohan Krishnan&lt;/a&gt;, dan terakhir soal pencapaian penting pada proyek Gatotkaca ini dari &lt;a href=&quot;https://cloud.google.com/blog/products/databases/migrating-databases-kubernetes-clusters-and-developers-to-cloud&quot;&gt;sudut pandang seorang Alabsi&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Karena sudah ada 3 artikel dan mungkin masih banyak artikel lain yang bersifat positif, maka artikel yang saya tulis kali ini hanya akan memuat hal yang perlu dihindari, pola pikir yang salah atau hal bersifat kontraproduktif lainnya.&lt;/p&gt;

&lt;h3 id=&quot;sumber-daya-cloud-adalah-tidak-terbatas&quot;&gt;Sumber Daya Cloud adalah Tidak Terbatas&lt;/h3&gt;

&lt;p&gt;Seperti kesabaran, sumber daya (resources) pada Cloud infrastructure dan provider, akan selalu terbatas. Meski kita melihatnya dalam bentuk virtual machines atau container, pada dasarnya semua berjalan di atas mesin fisik seperti pada on-premise. Karena kemudahan antar muka dan skala yang lebih besar saja, kita melihatnya seperti tak ada batasannya. Kealpaan pada perencanaan dapat membuat proses migrasi jadi terganggu, atau minimal cost efficiency jadi tidak tercapai.&lt;/p&gt;

&lt;p&gt;Sebuah kesalahan besar ketika kita tidak melakukan inventory dan capacity sizing (pengukuran kapasitas) pada saat memindahkan infrastruktur kita ke cloud provider. Selain untuk dapat mengetahui apakah provider dapat menyerap kebutuhan kita, kesiapan kita dalam pengukuran kapasitas juga akan berguna untuk mendapatkan harga yang lebih terjangkau. Misalkan kita sudah tahu machine size yang kita butuhkan, kita dapat membeli reserved instance atau CUD pada provider. Intinya kita komitmen akan menggunakan dengan kapasitas tertentu, maka in-return, kita mendapatkan harga yang lebih baik.&lt;/p&gt;

&lt;h3 id=&quot;pakai-cloud-langsung-auto-hemat&quot;&gt;Pakai Cloud Langsung Auto Hemat&lt;/h3&gt;

&lt;p&gt;Meskipun pada beberapa cloud provider seperti AWS dengan reserved instance dan GCP dengan CUD-nya, tidak berarti memindahkan infrastruktur ke cloud provider secara otomatis billing kita akan lebih murah daripada ongkos (baik capex maupun opex) di on-premise. Jika ada anggapan pada cloud kita cenderung akan melupakan capex, anggapan itu tidak sepenuhnya benar, karena kita tetap harus memperhitungkan kapasitas untuk mendapatkan biaya yang kita keluarkan untuk membeli CUD / reserved instances. Mendapatkan harga terbaik dengan cara seperti ini, adalah salah satu cara mendapatkan harga yang lebih baik dan menghemat pengeluaran juga.&lt;/p&gt;

&lt;p&gt;Pada migrasi yang dilakukan secara lift and shift, tanpa ada optimasi dan efisiensi, atau melakukan hal yang esensial untuk membuat service lebih “cloud native”, juga tidak akan mereduksi tagihan di akhir bulan. Namun pendekatan migrasi adalah pilihan. Akan sulit untuk mendapatkan akselerasi dari segi waktu migrasi dengan cost efficiency dalam waktu bersamaan, namun kedua hal tersebut dapat dicapai secara berimbang dengan pengaturan prioritas, keep the joyful stuff ala Marie Kondo dan manajemen resiko yang baik.&lt;/p&gt;

&lt;h3 id=&quot;network-di-cloud-akan-selalu-stabil&quot;&gt;Network di Cloud Akan Selalu Stabil&lt;/h3&gt;

&lt;p&gt;Hal ini adalah mitos yang setara dengan keberadaan kuda unicorn, virus corona itu tidak ada konspirasi elit global, atau nama asli Gajah Mada sebenarnya Gaj Ahmad a. Tidak ada penjelasan lebih jauh lagi soal ini. Walau bagaimanapun, ini adalah mitos yang tidak hanya terjadi di cloud namun juga di on-premise. Sebaiknya saat menyusun SLA service sendiri, hal yang paling penting diperhatikan adalah SLA dari dependency yang dimaintain / managed oleh cloud provider. Kemudian secara disiplin menerapkan pendekatan mitigasi network failure seperti circuit breaker, exponential backoff dan sebagainya.&lt;/p&gt;

&lt;h3 id=&quot;performa-aplikasi-otomatis-meningkat-atau-minimal-sama-seperti-on-premise&quot;&gt;Performa Aplikasi Otomatis Meningkat (atau Minimal Sama Seperti On-Premise)&lt;/h3&gt;

&lt;p&gt;Pada beberapa kasus, performa cloud resource seperti disk mempunyai constraint tertentu. Misalkan pada GCP, performa disk dibatasi oleh beberapa hal, misalkan jumlah vCPU, besaran disk sampai dibatasi oleh network throughput. Pada aplikasi atau service yang sangat sensitif terhadap latensi, maka hal - hal kecil seperti ini harus diperhatikan.&lt;/p&gt;

&lt;p&gt;Naik atau turunnya performa sebuah service atau aplikasi tidak datang dengan tiba - tiba. Justru dengan migrasi ke cloud, akan ada beberapa hal yang berubah, misalkan constraint pada resource yang disebutkan di atas, latency antar service dan dependency serta faktor - faktor lainnya. Maka dari itu, sebelum melakukan cutover ke cloud, sebaiknya perlu dilakukan load testing pada environment non production (staging atau pre-production) untuk dapat dilihat apakah service yang dipasang di cloud dapat memenuhi target pada metrik - metrik sesuai dengan SLO. Jika terdapat bottleneck di suatu bagian pada service, ada baiknya diselesaikan terlebih dahulu masalahnya sebelum dipindahkan ke cloud.&lt;/p&gt;

&lt;h3 id=&quot;migrasi-wajib-menggunakan-certified-engineer&quot;&gt;Migrasi Wajib Menggunakan Certified Engineer&lt;/h3&gt;

&lt;p&gt;Tidak mengatakan bahwa pendekatan ini salah, namun sertifikasi memang bukan penentu utama sukses atau tidaknya sebuah proyek migrasi ke cloud. Walau bagaimanapun, cloud provider pada dasarnya menyuguhkan produk dan solusi, yang mana akan selalu dimutakhirkan sesuai dengan roadmap perusahaan, atau kebutuhan pelanggan. Kebolehan suatu organisasi mendapatkan engineer dengan pengetahuan spesifik ke cloud provider yang akan dipakai, jelas akan mengakselerasi kemajuan atau progres dari proyek migrasi. Produk dari cloud provider bukanlah hal yang rumit untuk dipelajari. Memberikan waktu untuk engineer yang sudah ada, untuk melakukan PoC atau eksperimen dengan resource dan biaya yang terkontrol adalah salah satu cara membantu tim untuk lebih familiar dengan teknologi dan produk cloud provider.&lt;/p&gt;

&lt;h3 id=&quot;data-di-cloud-tidak-aman&quot;&gt;Data di Cloud Tidak Aman&lt;/h3&gt;

&lt;p&gt;Hal ini sering didengar dari seseorang yang entah awam, atau memang tidak punya pengalaman hidup yang bersinggungan dengan cloud provider. Mulai dari “Data di cloud itu kan seperti taruh data kita di tempat orang, jadi nanti mereka bisa baca data kita” sampai “Data di Cloud itu tidak aman, kan cloud itu publik, nanti bisa dilihat orang”. Jika dinalar ada sebagian pernyataan yang benar, misalkan data kita ada di infrastruktur pihak ke tiga, yang mana kita tidak punya kontrol. Hal ini dapat diselesaikan dengan perjanjian NDA atau penyesuaian layanan dengan peraturan (compliance) yang relevan dengan jenis bisnis. Secara umum, kita dapat bercakap dan berkonsultasi dengan Account Manager dari cloud provider.&lt;/p&gt;

&lt;p&gt;Untuk pasal keamanan data, tentu saja sangat bergantung bagaimana kita mencegah hal tersebut terjadi terlepas dari bentuk infrastruktur, entah di on-premise atau di cloud. Pada sebagian kasus data breach, umumnya hal tersebut diakibatkan hal - hal yang tidak secara spesifik berkaitan dengan kapabilitas cloud secara khusus, atau kapabilitas infra secara umum, dan lebih sering berkaitan erat dengan prosedur internal penyimpanan data pengguna - seperti menggunakan dump database dan tidak memperhatikan storage tempat penyimpanan tersebut, hingga keteledoran manusia.&lt;/p&gt;

&lt;p&gt;Selain hal tersebut di atas, masih banyak hal yang kontraproduktif lainnya, misalkan menghabiskan waktu untuk berdebat mengenai standarisasi atau konvensi tanpa mempunyai dasar data yang kuat, berpikir bahwa best practice itu overrated, dan berbagai hal picik lain soal cloud dan ihwal lainnya.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Gimana, udah siap pindah ke cloud?&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Bird migration Photo by &lt;a href=&quot;https://unsplash.com/@jcraice?utm_source=unsplash&amp;amp;utm_medium=referral&amp;amp;utm_content=creditCopyText&quot;&gt;Julia Craice&lt;/a&gt; on &lt;a href=&quot;https://unsplash.com/s/photos/migration?utm_source=unsplash&amp;amp;utm_medium=referral&amp;amp;utm_content=creditCopyText&quot;&gt;Unsplash&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Ideologi Ultra Konservatif pada Operasional Apache Cassandra</title>
   <link href="https://robee.id/2020/04/17/ideologi-ultra-konservatif-pada-operasional-apache-cassandra"/>
   <updated>2020-04-17T07:56:02+07:00</updated>
   <id>https://robee.id/2020/04/17/ideologi-ultra-konservatif-pada-operasional-apache-cassandra</id>
   <content type="html">&lt;blockquote&gt;
  &lt;p&gt;&lt;em&gt;konservatif/kon·ser·va·tif/ /konsérvatif/ a 1 kolot; 2 bersikap mempertahankan keadaan, kebiasaan, dan tradisi yang berlaku&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2 id=&quot;konservatif-pada-token-range&quot;&gt;Konservatif pada Token Range&lt;/h2&gt;

&lt;p&gt;Saat pertama kali saya dan tim menggunakan cassandra, saat itu versi paling lama yang kami pergunakan adalah 2.0.x , versi di mana sebenarnya cassandra sudah mengenal konsep vnodes. Sebuah konsep yang mengijinkan alokasi jumlah partisi dan pembagian letak partisi, secara otomatis diatur oleh cassandra itu sendiri. Namun, atas alasan yang cukup konservatif, saat itu, salah satu engineer di tim menolak gagasan penggunaan vnodes.&lt;/p&gt;

&lt;p&gt;Meski kami sudah menguji gabungan multi DC cassandra dengan fixed token dan properti file snitch, dengan DC lain yang menggunakan vnodes. Alasannya sederhana, kita membutuhkan sebuah database cluster yang mudah untuk ditebak perilaku penyimpanannya. Hal ini masuk akal. Kami membutuhkan prediksi yang tepat, akan partisi dalam 1 token range atau gabungannya dengan replication factor, sehingga saat nanti kami harus melakukan rolling restart untuk keperluan patch atau update, kami tahu node mana yang harus kami maintain terlebih dahulu, dan mana node berikutnya.&lt;/p&gt;

&lt;p&gt;Selain itu, tim akan terbantu ketika ingin melakukan repair data. Karena, tentu saja, kita tahu kemana kita akan mereferensi data. Kita juga akan dapat dengan mudah melakukan repair pada token range tertentu saja. Dengan pembagian yang jelas, ini memang akan mempermudah maintenance pada Cassandra.&lt;/p&gt;

&lt;p&gt;Hal lain yaitu jaminan lebih baik pada keseimbangan data yang tersebar di antara nodes dalam 1 Data Center. Meski ini bergantung kembali kepada seberapa seimbang kita membagi sebuah token range utuh kepada jumlah nodes yang kita punya dalam 1 Data Center, namun hal ini setidaknya mengurangi resiko penumpukan token pada titik / node tertentu.&lt;/p&gt;

&lt;h2 id=&quot;konservatif-pada-cara-scaling&quot;&gt;Konservatif pada cara Scaling&lt;/h2&gt;

&lt;p&gt;Pada 2 perusahaan yang berbeda, saya tetap terus menghindari penggunaan vnodes dan hal itu juga berimplikasi pada keputusan untuk melakukan scaling cluster. Metode scaling cluster cassandra yang saya lebih sukai adalah dengan cara membuat data center baru dengan jumlah node yang lebih banyak, untuk kemudian menggantikan data center existing atau lama yang lebih kecil.&lt;/p&gt;

&lt;p&gt;Kemudian data center lama ini akan di decommision setelah service atau aplikasi sudah mengarahkan query request ke data center baru. Untuk dapat melakukan ini, kita harus mengimplementasikan consistency level pada service atau driver aplikasi yang bersifat local, entah itu local one, local quorum dan seterusnya. Selain consistency level, kita juga harus membatasi query hanya terisolasi pada 1 data center.&lt;/p&gt;

&lt;p&gt;Implementasi isolasi ini dapat dilakukan dengan mengenable opsi semacam DCAware kemudian mengunci query pada localDc, yaitu data center yang lama - pada saat data center baru sedang disiapkan atau di-rebuild dan kemudian kepada data center baru, setelah data center baru siap. Hal ini sangat memudahkan scaling dan terminasi pada cluster.&lt;/p&gt;

&lt;p&gt;Pada vnodes, scaling dapat dilakukan dengan menambah node dan mengubah token. Hal ini berimbas pada pergeseran data yang akan terjadi secara live, karena kepemilikan token berubah. Pada konsep static token juga sangat dihindari metode serupa, yaitu dengan cara menambah node dan menggeser atau mengatur ulang partisi. Jika cluster hanya mempunya 1 data center saja, maka 1 data center yang kemungkinan sedang dipakai oleh service di production, juga akan terbebani dengan operasi internal saat menggeser data di berbagai node ini.&lt;/p&gt;

&lt;p&gt;Photo by &lt;a href=&quot;https://unsplash.com/@lcs_vgt?utm_source=unsplash&amp;amp;utm_medium=referral&amp;amp;utm_content=creditCopyText&quot;&gt;lcs _vgt&lt;/a&gt; on &lt;a href=&quot;https://unsplash.com/s/photos/ultra?utm_source=unsplash&amp;amp;utm_medium=referral&amp;amp;utm_content=creditCopyText&quot;&gt;Unsplash&lt;/a&gt;&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Catatan Kafka : Replikasi</title>
   <link href="https://robee.id/2020/04/06/catatan-kafka-bagian-1-replikasi"/>
   <updated>2020-04-06T09:39:27+07:00</updated>
   <id>https://robee.id/2020/04/06/catatan-kafka-bagian-1-replikasi</id>
   <content type="html">&lt;p&gt;Apache Kafka adalah salah satu sistem yang sering dipergunakan untuk membangun data pipeline dan / atau sistem streaming data. Saya sengaja mencatat beberapa bagian penting sebagai sarana untuk mempelajari dan mulai familiar dengan sistem ini.&lt;/p&gt;

&lt;p&gt;Salah satu bagian penting dari Kafka adalah Sistem &lt;strong&gt;Replikasi&lt;/strong&gt;. Sistem replikasi pada Kafka adalah bagian penting untuk menjamin durabilitas dan reliabilitas dari Kafka itu sendiri. Setiap topic dan partition pada Kafka direplikasi di 2 jenis replika : &lt;strong&gt;Leader Replica, Follower Replica&lt;/strong&gt;. Kafka menggunakan Leader Replica untuk menjamin konsistensi pada setiap replica partitions karena leader replica (atau Leader saja), akan menerima request producer dan consumer serta memastikan para follower terus ter-update terhadap leader.&lt;/p&gt;

&lt;p&gt;Pada skema produce, maka ada 2 macam request berkaitan dengan produce ini : Produce request dan Fetch Request. Produce request adalah request dari client berupa message untuk di “antri” kan ke kafka brokers, sedangkan fetch request, adalah request consume dan produce dari followers kepada leader.Dari sisi client, set konfigurasi acks untuk memastikan konsistensi. Ack bisa 1, -1 atau 0. 1, semua atau fire and forget. Pada beberapa blog berisikan benchmark, sering digunakan ack 0, yang mana pastinya akan menghasilkan grafik yang “indah” pula.&lt;/p&gt;

&lt;p&gt;Bicara soal replikasi di kafka, ada istilah ISR atau In-Sync Replica, istilah untuk kafka brokers yang mempunyai data yang sama pada sebuah partisi topik tertentu. Misalkan pada sebuah topik ditetapkan replication factornya 3, maka akan ada 1 leader replica dan 2 follower replica yang mempunyai data yang sama per partisi pada topik tersebut.Jumlah minimal in-sync replica dapat dikonfigurasi untuk menentukan seberapa reliable cluster kafka tersebut. Secara default, min-insync-replica adalah 1, artinya dengan replication factor 3, kita masih dapat melakukan consume dan produce jika ada 2 node yang mati pada partisi tersebut. Hal ini diluar pembahasan konsistensi dan hubungannya dengan ack.&lt;/p&gt;

&lt;p&gt;Replica dapat dikatakan dalam status “in-sync” jika memenuhi 3 hal ini :&lt;/p&gt;
&lt;ol&gt;
  &lt;li&gt;tetap mempunyai sesi aktif ke zookeeper. broker tetap mengirimkan signal heartbeat ke zookeeper dalam waktu 6 detik (dapat dikonfigurasi pada zookeeper.session.timeout.ms )&lt;/li&gt;
  &lt;li&gt;melakukan fetch request yang berhasil ke leader dalam kurun waktu 10 detik ( tergantung konfigurasi replica.lag.time.max.ms)&lt;/li&gt;
  &lt;li&gt;menerima message terakhir dalam rentang 10 detik (poin nomor 2) dari leader.&lt;/li&gt;
&lt;/ol&gt;

&lt;blockquote&gt;
  &lt;p&gt;Dalam skema ack all, maka sebuah request produce baru dikatakan sukses (committed), jika semua replica telah mengkonfirmasi telah menerima message. Untuk lebih jelasnya dapat dilihat pada thread ini di situs stackoverflow : &lt;a href=&quot;https://stackoverflow.com/questions/50689177/kafka-ack-all-and-min-isr&quot;&gt;https://stackoverflow.com/questions/50689177/kafka-ack-all-and-min-isr&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Konfigurasi semacam replication factor, min insync replica akan menentukan seberapa reliable sebuah kafka cluster. Dengan replication factor yang semakin banyak, tentu meningkatkan availability dari kafka tersebut, semakin lengkap jika ack nya di set ke all, sehingga memastikan semua replika mendapatkan message tersebut. Namun konfigurasi ini juga akan berdampak pada kecepatan / latency request yang semakin meningkat. Berikut konfigurasi broker yang berimplikasi terhadap replikasi dan hubungannya dengan reliabilitas serta kecepatan :&lt;/p&gt;

&lt;h3 id=&quot;replication-factor&quot;&gt;Replication Factor&lt;/h3&gt;

&lt;p&gt;Pada kafka, sebuah topic dapat dibagi menjadi beberapa partition. dan replikasi terjadi di level partition bukan di topic nya. Jika partition di atur pada parameter num.partitions, maka untuk replication per partition dikenal dengan istilah replication factor, sebuah istilah yang kerap digunakan pada database yang mempunyai sistem replikasi misalkan Cassandra.Replication Factor menentukan seberapa banyak sebuah partition pada topic direplikasi. Misalkan pada topic bernama topic_a , mempunyai 3 partisi. Dan replication factor di set ke angka 3, itu artinya topic_a - partition 0 akan disimpan di 3 broker yang berbeda, begitu juga partition 1 dan seterusnya. Sebuah replication factor X, akan mengijinkan cluster kafka untuk kehilangan X-1 brokers dan tetap dapat menerima request produce dan consume (read / write). Selain memastika setiap replica partition ada di broker yang berbeda, sebaiknya juga pastikan partition tersebut disebar juga di broker yang berada di rak server yang berbeda. Hal ini dapat diterjemahkan juga menjadi multiple Availability Zone pada cloud platform.&lt;/p&gt;

&lt;h3 id=&quot;unclean-leader-election&quot;&gt;Unclean Leader Election&lt;/h3&gt;

&lt;p&gt;Jika sebuah leader replica kemudian tidak dapat dikontak atau mati, salah satu dari ISR akan segera menggantikannya sebagai leader replica baru. Cara pemilihan (election) ini disebut “clean” election, karena menggaransi tidak ada data yang hilang. Tapi apa yang terjadi ketika tidak ada lagi ISR yang tersisa?Partition akan tetap offline sampai replica - replica tadi kembali hidup atau online. Jika kita mengijinkan replica yang out-of-sync untuk jadi leader, maka kita akan kehilangan beberapa message yang dikirim di interval waktu saat ISR tadi bertumbangan.Mengeset unclean.leader.election.enable menjadi true - di mana ini adalah default value-nya, akan mengijinkan out-of-sync replica menjadi leader (unclean election), namun beresiko pada kehilangan message seperti yang dipaparkan sebelumnya.Namun tanpa adanya konfigurasi ini (set ke false), maka availability jadi lebih rendah karena kita harus menunggu leader replica lama kembali online. Sebaliknya jika kita membahas kualitas data dan konsistensi, maka ada baiknya mengubah konfigurasi unclean leader election ini menjadi false.&lt;/p&gt;

&lt;h3 id=&quot;min-in-sync-replica&quot;&gt;Min In-Sync Replica&lt;/h3&gt;

&lt;p&gt;Pada contoh di atas, kita menetapkan RF (Replication Factor) menjadi 3, maka ada kemungkinan kita hanya mempunyai 1 ISR di cluster. Kita bisa saja menggunakan ack all namun tetap saja akan menunggu sisa ISR untuk kembali online sehingga produce yang kita kirimkan dapat di commit. Pada kasus ini, kita diminta untuk memilih consistency dan availability. Jika kita mengeset min.insync.replicas menjadi 2, maka kita hanya dapat menulis ke topic partition tersebut jika 2 dari 3 replica sedang online. Artinya jika ada 1 mesin mati, kita masih bisa menuliskan message. Namun jika 2 mesin mati / offline, maka yang terjadi client / producer tidak dapat mengirimkan produce request (mendapat error &lt;em&gt;NotEnoughReplicasException&lt;/em&gt; ).&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Right Application for Right Purpose</title>
   <link href="https://robee.id/2020/01/02/right-app-for-right-purpose"/>
   <updated>2020-01-02T03:39:13+07:00</updated>
   <id>https://robee.id/2020/01/02/right-app-for-right-purpose</id>
   <content type="html">&lt;p&gt;Sebenarnya penulis ingin membuat tulisan yang membahas tahun lalu dan apa yang telah terjadi, dilanjutkan dengan cita - cita dan target di tahun ini, mengingat itu hal normal yang mungkin setiap penulis atau orang lain lakukan di awal tahun. Tapi mungkin ada baiknya saya menulis refleksi mendasar tentang teknologi yang tidak terlalu teknis, tapi tetap menarik untuk dibahas.&lt;/p&gt;

&lt;p&gt;Mengawali tahun ini dengan berbagai target yang sudah ditentukan di dokumen OKR (&lt;em&gt;Objectives and Key Results&lt;/em&gt;), pada organisasi masing - masing. Biasanya semua dibuat di akhir masa OKR sebelumnya, dalam hal ini Q4 2019. Di kantor saya yang sekarang ini, ada banyak misi yang harus diselesaikan oleh tim teknologi. Misi tersebut sudah dituangkan dan diperjelas dalam dokumen, presentasi dan berbagai bentuk pesan lain, dari pemimpin organisasi hingga pemimpin bagian masing - masing. Untuk mengejar target misi tersebut, kami bukan hanya berlari dengan mengerjakan tugas, namun membawa bertumpuk - tumpuk pengalaman yang sudah didapatkan di masa sebelumnya.&lt;/p&gt;

&lt;p&gt;Salah satu pengalaman yang paling saya ingat adalah bagaimana, di masa lalu, organisasi dan bagian di dalamnya melakukan beberapa kesalahan yang fundamental, hingga pada akhirnya ada harga yang harus dibayar di kemudian hari. Kesalahan tersebut bisa berupa kesalahan metode, kesalahan prosedur hingga kesalahan arsitektural. Dan hal paling mendasar adalah kesalahan arsitektural.&lt;/p&gt;

&lt;p&gt;Kesalahan arsitektural dalam membangun perangkat lunak yang melayani trafik yang sangat tinggi, memerlukan pendalaman masalah yang sangat intens. Karena banyak akibat yang harus dihadapi, termasuk akibat yang tidak diantisipasi dari awal. Dalam kesalahan arsitektural, sering kali ditemui kecerobohan dalam memilih aplikasi perangkat lunak tertentu untuk menyelesaikan masalah spesifik.&lt;/p&gt;

&lt;p&gt;Misalkan saja memilih menggunakan aplikasi &lt;em&gt;batch stream&lt;/em&gt; untuk penyimpanan semi permanen, atau bahkan permanen. Memilih menggunakan aplikasi penyimpanan pada memori &lt;em&gt;volatile&lt;/em&gt; sebagai kakas basis data. Hal ini terjadi bahkan kerap terjadi karena berpikir segala macam permasalahan performa, dapat diatasi dengan mengoptimalkan aplikasi dari sisi penunjang atau dari sisi infrastruktur. Berpikir bahwa sumber daya tidak terbatas. Tentunya pemikiran ini tidak sepenuhnya benar, karena jika hal ini terjadi di ekosistem yang dibangun di &lt;em&gt;cloud infrastructure&lt;/em&gt;, maka segalanya menjadi amat terbatas.&lt;/p&gt;

&lt;p&gt;Pemilihan aplikasi penunjang seperti &lt;em&gt;database system, caching system, queue system&lt;/em&gt; dan sebagainya, memerlukan pengetahuan akan kinerja aplikasi yang dibuat, cara kerja aplikasi penjunjang tersebut dan operasional dibalik aplikasi penjunjang itu semua. Hal ini juga tetap diperlukan bila aplikasi penjunjang tersebut disediakan oleh pihak lain atau yang kerap disebut &lt;em&gt;managed service&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;Kesalahan pemilihan &lt;em&gt;tech stack&lt;/em&gt; ini selain setumpuk &lt;em&gt;technical debt&lt;/em&gt; tapi juga permasalahan performa yang pada akhirnya dikonversi menjadi pemborosan biaya secara langsung. Bukan lagi biaya manusia lagi, tapi biaya sumber daya seperti ongkos server atau bahkan server dan bandwidth. Tidak selamanya kita dapat menambal kekurangan aplikasi dengan menambahkan CPU atau alokasi memori ke mesin. Seperti tidak selamanya uang akan menyelamatkan performa aplikasi.&lt;/p&gt;

&lt;p&gt;Sebuah organisasi yang mencari profit dengan teknologi sebagai tulang punggung, tidak harus memiliki seorang dengan titel Arsitek, entah itu &lt;em&gt;software architect, infrastructure architect&lt;/em&gt; dan lain sebagainya. Namun ada baiknya mempunyai tim ad-hoc yang dapat dibentuk jika dibutuhkan, untuk membahas arsitektur sebuah &lt;em&gt;service&lt;/em&gt; baru atau merombak arsitektur &lt;em&gt;service&lt;/em&gt; lama yang bermasalah. Seperti dalam sebuah pemerintahan, Presiden terkadang membentuk tim pencari fakta yang sifatnya tidak permanen. Tentunya tim tersebut harus berisikan insinyur - insinyur teknologi yang berkompeten serta jika memungkinkan, mempunyai pengalaman yang sangat bervariasi.&lt;/p&gt;

&lt;p&gt;Setelah mengetahui bahwa kesalahan arsitektural adalah kesalahan yang sangat mendasar, semoga di tahun ini (2020) ke depan, tidak ada lagi yang menggunakan &lt;em&gt;&lt;a href=&quot;https://redis.io/&quot;&gt;Redis&lt;/a&gt;&lt;/em&gt; sebagai &lt;em&gt;database system&lt;/em&gt; (yang &lt;em&gt;persistent&lt;/em&gt; dan dalam jumlah data yang besar) lagi.&lt;/p&gt;

&lt;p&gt;…. Aamiin ….&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Ekspansi Prometheus Storage dengan TimescaleDB</title>
   <link href="https://robee.id/2019/08/29/ekspansi-prometheus-storage-dengan-timescaledb"/>
   <updated>2019-08-29T07:07:55+07:00</updated>
   <id>https://robee.id/2019/08/29/ekspansi-prometheus-storage-dengan-timescaledb</id>
   <content type="html">&lt;blockquote&gt;
  &lt;p&gt;Prometheus adalah monitoring tools yang hampir tidak pernah saya lihat, sampai suatu ketika saya harus bersinggungan dengan Kubernetes.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Prometheus, secara “mutlak” dipakai oleh Kubernetes dan lingkungannya, termasuk Istio yang masyhur itu, sebagai monitoring tools atau sederhananya pengepul angka dari metrics perkakas - perkakas kubernetes. Dalam konfigurasi yang ringkas, maka prometheus akan dipasang sebagai sidecar dari pod atau sebagai statefulset yang mengambil metrics dari pod, Istio atau metrics yang diekspose oleh exporter. Misalkan redis exporter.&lt;/p&gt;

&lt;p&gt;Jika di zoom ke bagian monitoring saja, maka rute nya akan jadi begini :&lt;/p&gt;

&lt;!--kg-card-begin: markdown--&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;Exporter / Istio Telemetry -&amp;gt; Prometheus -&amp;gt; (Optional) Stackdriver
                                         -&amp;gt; Grafana
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;!--kg-card-end: markdown--&gt;

&lt;p&gt;Pada prakteknya, prometheus sering kewalahan dipakai sebagai database timeseries baik ingest dari metrics source maupun untuk diplot dalam bentuk grafik di kakas semacam Grafana. Prometheus akan menggunakan sumber daya, seperti beban memori yang terlalu besar. Dan penumpukan data pada file yang diambil dari persistent disk juga membuat Prometheus semakin hari semakin bloated, gemuk - tanpa nada atau niatan body shaming. Sifatnya yang cenderung stateful ini membuat Prometheus sulit untuk di-scale. Adapun solusi scaling up Prometheus adalah dengan dua solusi, yang pertama adalah mode federated. Yang artinya akan ada lebih dari 1 prometheus dengan konsep DC dan sebagainya, namun kelemahan mode ini adalah tingkat kerumitan dalam pengaturan distribusi node prometheus dan ketika di-query tetap menuju ke 1 node prometheus, maka kebuntuan penggunaan sumber daya memori tetap terjadi. Karena tetap saja tidak terdistribusi pembagian bebannya. Solusi ke-dua adalah dengan cara sharding, alias membagi job scrape ke dalam beberapa prometheus yang berdiri secara terpisah.&lt;/p&gt;

&lt;p&gt;Dalam permasalahan tersebut, akhirnya muncul beberapa solusi untuk mengatasi kebuntuan sumber daya, misalkan yang paling populer saat tulisan ini dibuat adalah &lt;a href=&quot;https://thanos.io&quot;&gt;Thanos&lt;/a&gt;. Thanos menjanjikan pemetaan fungsi yang tadinya dibebankan semua pada prometheus menjadi lebih terbagi-bagi berdasarkan fungsinya. Thanos mempunyai thanos sidecar sebagai shipper, ada thanos query yang nanti akan menerima user request, ada thanos compactor untuk memelihara file yang dihantarkan shipper ke penyimpanan pihak ketiga (third party storage, seperti GCS, S3 atau Ceph backed storage). Dengan banyaknya komponen ini, Thanos mempunyai kelemahan yaitu tingkat kerumitan yang cukup tinggi. Belum tentu juga menjamin komponen Thanos Query ini tidak mengalami kebuntuan dari segi penggunaan memori.&lt;/p&gt;

&lt;p&gt;Untuk itu saya berpikir sedikit lebih sederhana. Mengapa tidak menghantarkan data dari Prometheus ke penyimpanan secara remote (remote write dan remote read), kemudian Grafana tinggal melakukan query ke penyimpanan tersebut. Penyimpanan di sini diartikan sebagai basis data (database), yang didukung oleh Grafana sebagai datasource, misalkan InfluxDB atau PostgreSQL.&lt;/p&gt;

&lt;p&gt;Pilihan percobaan jatuh kepada PostgreSQL gara - gara saya hanya menginginkan teknologi yang lebih familiar buat saya pribadi. Namun ternyata PostgreSQL tidak dapat berdiri sendiri, jika kita ingin menjadikannya sebagai timeseries database. PostgreSQL butuh plugin Timescale yang menjadikan kombinasi ini sebagai TimescaleDB.&lt;/p&gt;

&lt;p&gt;Tulisan ini tidak akan menjelaskan langkah perlangkah untuk mengonfigurasi sebuah server atau banyak server menjadi tempat penyimpanan metrics dari Prometheus. Karena langkah tersebut dapat ditemukan di sini : “ &lt;strong&gt;Getting started with Prometheus and TimescaleDB&lt;/strong&gt;” (&lt;a href=&quot;https://docs.timescale.com/v0.10/tutorials/prometheus-adapter&quot;&gt;https://docs.timescale.com/v0.10/tutorials/prometheus-adapter&lt;/a&gt;). Saya hanya akan membahasnya secara konseptual dan membagikan pengalaman saat mengimplementasikannya.&lt;/p&gt;

&lt;p&gt;Dengan menggunakan TimescaleDB, maka rutenya menjadi seperti ini :&lt;/p&gt;

&lt;!--kg-card-begin: markdown--&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;Exporter / Istio Telemetry -&amp;gt; Prometheus -&amp;gt; Prometheus PostgreSQL Adapter -&amp;gt; PostgreSQL server + Timescale + Pg_prometheus -&amp;gt; Grafana
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;!--kg-card-end: markdown--&gt;

&lt;p&gt;Jika dibandingkan dengan Thanos, saya rasa solusi ini lebih sederhana dan masuk akal jika ditilik dari segi kesederhanaan. Hal ini sedikit berbeda dengan Thanos yang menyebutkan bahwa solusi mereka didesain dengan konsep KISS (Keep It Simple, Stupid), menurut saya sih Thanos tidak simple.&lt;/p&gt;

&lt;p&gt;Pada solusi TimescaleDB sebagai “long term database for Prometheus” ini, maka kita perlu mempersiapkan (selain Prometheus dan Grafana):&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;PostgreSQL&lt;br /&gt;
PostgreSQL yang dipersiapkan bisa pakai versi stabil terakhir (saat ini 11) dengan tambahan library timescaledb dan Pg_prometheus.&lt;/li&gt;
  &lt;li&gt;Prometheus PostgreSQL adapter&lt;br /&gt;
Adapter yang akan berbicara di protokol http dan menerima ingest dari Prometheus&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Kedua hal di atas dapat disatukan pada satu server atau dipisah. Sesederhana bumbu kacang pada sate, dipisah atau dicampur. Pada prometheus akan ditambahkan baris konfigurasi untuk melakukan remote write dan remote read ke Prometheus PostgreSQL Adapter.&lt;/p&gt;

&lt;p&gt;Saya kira dengan diaktifkannya remote write, prometheus akan berhenti menulis ke penyimpanan permanennya, namun ternyata tidak. Prometheus tetap menulis file TSDB yang dipakainya sebagai simpanan lokal. Nah, berarti solusi ini tidak akan berdampak pada membeludaknya ukuran database di Prometheus. Namun setidaknya dapat mencapai tujuan untuk menyelamatkan data prometheus jika memang terjadi apa-apa terhadap Prometheus-nya.&lt;/p&gt;

&lt;p&gt;Yang perlu diperhatikan juga adalah penggunaan query timeseries pada grafana yang pada praktiknya adalah query PostgreSQL dengan tambahan makro time series atau time bucket di sana. Query tidak sesederhana PromQL yang dengan mudahnya melakukan perhitungan aritmatika hanya dengan 1 line query. Bahkan sampai tulisan ini saya buat, saya belum dapat menemukan semua pengganti sepadan syntax PromQL misalkan irate. Namun hal ini dapat diatasi dengan riset pada metrics tertentu yang membutuhkan query yang (mungkin) kompleks. Dengan ‘kemudahan’ dan ‘popularitas’ SQL, seharusnya ini tidak menjadi masalah di kemudian hari.&lt;/p&gt;

&lt;p&gt;Referensi :&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;&lt;a href=&quot;https://blog.timescale.com/blog/sql-nosql-data-storage-for-prometheus-devops-monitoring-postgresql-timescaledb-time-series-3cde27fd1e07/&quot;&gt;https://blog.timescale.com/blog/sql-nosql-data-storage-for-prometheus-devops-monitoring-postgresql-timescaledb-time-series-3cde27fd1e07/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://docs.timescale.com/v0.10/tutorials/prometheus-adapter&quot;&gt;https://docs.timescale.com/v0.10/tutorials/prometheus-adapter&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;
</content>
 </entry>
 
 <entry>
   <title>Flash Lineage OS ke Oneplus 3 dengan Ubuntu 18.04 Desktop LTS</title>
   <link href="https://robee.id/2019/04/22/flash-lineage-os-ke-oneplus-3"/>
   <updated>2019-04-22T17:21:03+07:00</updated>
   <id>https://robee.id/2019/04/22/flash-lineage-os-ke-oneplus-3</id>
   <content type="html">&lt;p&gt;[Do it with your own risk.] Berikut ini dokumentasi yang saya lakukan saat flashing Lineage OS ke Oneplus 3. Mungkin juga berlaku untuk Oneplus 3T. Hal ini worth untuk dilakukan mengingat Oneplus 3 sudah di ambang masa obsolete support nya untuk mendapatkan update Oxygen OS.&lt;/p&gt;

&lt;p&gt;Yang perlu dipersiapkan :&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;Ubuntu 18.04 Desktop LTS&lt;/li&gt;
  &lt;li&gt;Lineage OS yang dapat diunduh di sini : &lt;a href=&quot;https://download.lineageos.org/oneplus3&quot;&gt;https://download.lineageos.org/oneplus3&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;TWRP image dari sini : &lt;a href=&quot;https://dl.twrp.me/oneplus3/twrp-3.3.0-1-oneplus3.img.html&quot;&gt;https://dl.twrp.me/oneplus3/twrp-3.3.0-1-oneplus3.img.html&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;GApps. kecuali seorang pemboikot Google :) dapat diperoleh dari sini : &lt;a href=&quot;https://opengapps.org/&quot;&gt;https://opengapps.org/&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h3 id=&quot;persiapan&quot;&gt;Persiapan&lt;/h3&gt;

&lt;p&gt;Sebelum semuanya dilakukan, backup data penting ke cloud. Skenario yang saya lakukan adalah dengan mem-format internal storage tanpa menyisakan data.&lt;/p&gt;

&lt;p&gt;Pada Ubuntu 18.04 tersebut, pasang android tools yang nanti akan dibutuhkan&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;sudo apt update
sudo apt install android-tools-adb android-tools-fastboot
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id=&quot;unlock-bootloader&quot;&gt;Unlock Bootloader&lt;/h3&gt;

&lt;p&gt;Pada Oneplus 3, buka Setting. Kemudian pada About Phone, tap di Build Number sampai keluar pesan semacam “You are now a Developer”.&lt;/p&gt;

&lt;p&gt;Pada Developer menu, aktifkan hal berikut:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Enable USB Debugging&lt;/li&gt;
  &lt;li&gt;Enable OEM Unlock / Allow Bootloader Unlock&lt;/li&gt;
  &lt;li&gt;Enable Advance Reboot&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Matikan Oneplus 3, lalu nyalakan kembali dengan menekan Volume Up + Power Button secara bersama. Setelah masuk mode fastboot, hubungkan Oneplus 3 dengan komputer dengan Ubuntu tadi.&lt;/p&gt;

&lt;p&gt;Bukalah aplikasi Terminal atau Terminator, lalu gunakan perintah ini untuk mendeteksi apakah device sudah dikenali &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;fastboot devices&lt;/code&gt; .&lt;/p&gt;

&lt;p&gt;Untuk meng-unlock bootloader, gunakan perintah ini &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;fastboot oem unlock&lt;/code&gt; pada step ini saja, data anda akan hilang.&lt;/p&gt;

&lt;h3 id=&quot;flash-twrp&quot;&gt;Flash TWRP&lt;/h3&gt;

&lt;p&gt;Kemudian flash TWRP yang tadi didapatkan dari sini : &lt;a href=&quot;https://dl.twrp.me/oneplus3/twrp-3.3.0-1-oneplus3.img.html&quot;&gt;https://dl.twrp.me/oneplus3/twrp-3.3.0-1-oneplus3.img.html&lt;/a&gt;&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;fastboot flash recovery &amp;lt;namafile_TWRP_disini&amp;gt;.img
fastboot boot &amp;lt;namafile_TWRP_disini&amp;gt;.img
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id=&quot;hapus-ini-hapus-itu&quot;&gt;Hapus ini Hapus itu&lt;/h3&gt;

&lt;p&gt;[Achtung! Data akan diformat!]&lt;/p&gt;

&lt;p&gt;Jika TWRP menanyakan password untuk decrypt, lewati saja (tekan cancel). Kemudian pada menu &lt;strong&gt;Wipe&lt;/strong&gt; - Format Data. Sebelum dilakukan, ada baiknya dibackup sendiri datanya. Ingat, saya memang berencana untuk menghapus partisi agar tidak diributkan dengan urusan decrypt partition nantinya. Hapus Cache juga jika perlu.&lt;/p&gt;

&lt;h3 id=&quot;flash-rom&quot;&gt;Flash ROM&lt;/h3&gt;

&lt;p&gt;Masih di TWRP, tap back dan masuk menu Advanced. Kemudian pilih ADB Sideload.&lt;/p&gt;

&lt;p&gt;Dengan posisi Oneplus 3 terhubung ke Ubuntu, buka terminator, dan lakukan sideload 2 image file yaitu image Lineage OS yang diunduh dari sini &lt;a href=&quot;https://download.lineageos.org/oneplus3&quot;&gt;https://download.lineageos.org/oneplus3&lt;/a&gt; dan GApps dari sini &lt;a href=&quot;https://opengapps.org/&quot;&gt;https://opengapps.org/&lt;/a&gt;&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;adb sideload lineage-16.0-20190420-nightly-oneplus3-signed.zip
adb sideload open_gapps-arm64-9.0-stock-20190420.zip
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;setelah terpasang, jangan lupa untuk mengunci / lock boot loader dengan masuk kembali ke fastboot pada Oneplus 3 dan kirim perintah ini &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;fastboot oem lock&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Saya sendiri mengulang - ulang beberapa perintah di atas dan menemui permasalahan seperti ini :&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Lineage terpasang, boot, tapi tidak dapat melakukan decrypt storage (maka saya format habis saja)&lt;/li&gt;
  &lt;li&gt;Lineage terpasang, tapi somehow stuck (maka akhirnya saya coba untuk lock kembali bootloader)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Saya pun baru tahu bahwa Android 9 punya masalah pada decrypt data yang kita encrypt di Android versi sebelumnya. &lt;a href=&quot;https://forum.xda-developers.com/oneplus-3/oneplus-3--3t-cross-device-development/rom-lineageos-16-0-oneplus-3-3t-t3866517&quot;&gt;https://forum.xda-developers.com/oneplus-3/oneplus-3–3t-cross-device-development/rom-lineageos-16-0-oneplus-3-3t-t3866517&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Selamat datang Lineage!&lt;/p&gt;

&lt;p&gt;[Update 6 April 2020]&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Untuk upgrade perlu install firmware modem baru : &lt;a href=&quot;https://www.androidexplained.com/oneplus-3-upgrade-modem/&quot;&gt;https://www.androidexplained.com/oneplus-3-upgrade-modem/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;Install firmware sebelum sideload lineageos&lt;/li&gt;
&lt;/ul&gt;
</content>
 </entry>
 
 <entry>
   <title>Django, Gunicorn and Nginx</title>
   <link href="https://robee.id/2019/04/14/django-gunicorn-and-nginx"/>
   <updated>2019-04-14T15:34:25+07:00</updated>
   <id>https://robee.id/2019/04/14/django-gunicorn-and-nginx</id>
   <content type="html">&lt;p&gt;Sebenarnya postingan pertamax dengan judul “Silo atau Limbo” itu post yang sudah ada dari jaman domain vanjava.web.id. Harusnya ini postingan pertamax yang sesungguhnya. Pertamax pertamax mulu kek masih main Kaskus aja.&lt;/p&gt;

&lt;p&gt;Postingan kali ini saya mau mendokumentasikan bagaimana konfigurasi &lt;a href=&quot;https://docs.djangoproject.com/en/2.2/&quot;&gt;Django Framework&lt;/a&gt; (yang pada saat tulisan ini dibuat, versi stable terakhir adalah 2.2) di sistem Operasi Linux &lt;a href=&quot;https://www.ubuntu.com/download&quot;&gt;Ubuntu&lt;/a&gt; versi 18.04 LTS dengan &lt;a href=&quot;https://gunicorn.org/&quot;&gt;Gunicorn&lt;/a&gt; sebagai WSGI server dan &lt;a href=&quot;https://docs.nginx.com/&quot;&gt;Nginx&lt;/a&gt; sebagai garda terdepan.&lt;/p&gt;

&lt;p&gt;Sebenarnya dokumentasi ini tidak hanya berlaku untuk Django Framework saja, tapi (mungkin) juga masih applicable untuk python based web framework lainnya seperti Flask, CherryPy dan lain sebagainya.&lt;/p&gt;

&lt;h3 id=&quot;instalasi-django&quot;&gt;Instalasi Django&lt;/h3&gt;

&lt;p&gt;Untuk memasang django, dapat dimulai memasang beberapa dependensi&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;sudo apt update
sudo apt install python3 python3-venv
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Kemudian buatlah python3 virtual environment. Mengapa harus virtual environment? Baca ini saja. &lt;a href=&quot;https://www.geeksforgeeks.org/python-virtual-environment/&quot;&gt;Python Virtual environment&lt;/a&gt;.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;python3 -m venv /path/to/virtualenv
# contoh
python3 -m venv /opt/robee-env/
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Setelah virtual environment dibuat, aktifkan dan pasang django &lt;strong&gt;di dalam virtual environment&lt;/strong&gt;&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;source /path/to/virtualenv/bin/activate
pip install django
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Mengapa ditebalkan bagian “di dalam virtual environment”, sekali lagi baca url ini &lt;a href=&quot;https://www.geeksforgeeks.org/python-virtual-environment/&quot;&gt;Python Virtual environment&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Masih di dalam virtual environment, pastikan django terpasang dengan baik&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&amp;gt;&amp;gt;&amp;gt; import django
&amp;gt;&amp;gt;&amp;gt; print(django.get_version())
2.2
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Dengan asumsi source code project django kita letakkan di &lt;em&gt;/path/to/mydjangoproject/&lt;/em&gt; maka :&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;cd /path/to
django-admin startproject mydjangoproject
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;maka nanti akan ada django project baru pada &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;/path/to/mydjangoproject/&lt;/code&gt; bersama dengan struktur django di dalamnya. Untuk menguji apakah django sudah dapat serve :&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;cd /path/to/mydjangoproject/
python manage.py runserver 0.0.0.0:8080
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;kemudian cobalah untuk mengakses &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;http://localhost:8080&lt;/code&gt; dan akan didapati lama seperti ini&lt;/p&gt;

&lt;figure class=&quot;kg-card kg-image-card&quot;&gt;&lt;img src=&quot;/content/images/2019/04/image.png&quot; class=&quot;kg-image&quot; alt=&quot;&quot; loading=&quot;lazy&quot; /&gt;&lt;/figure&gt;

&lt;p&gt;Untuk membuat sebuah aplikasi django dan berbagai fungsi atau fitur lainnya, silakan dilanjutkan untuk mempelajarinya di sini : &lt;a href=&quot;https://docs.djangoproject.com&quot;&gt;Django Framework&lt;/a&gt;&lt;/p&gt;

&lt;h3 id=&quot;gunicorn&quot;&gt;Gunicorn&lt;/h3&gt;

&lt;p&gt;Gunicorn sendiri merupakan sebuah WSGI HTTP Server yang dapat berfungsi meneruskan client request ke python. Laman resminya bisa dipantau di sini : &lt;a href=&quot;https://gunicorn.org/&quot;&gt;https://gunicorn.org/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Mengapa harus WSGI Server?&lt;/p&gt;

&lt;p&gt;Sebenarnya setiap python web frameworks punya built-in http server sendiri, misalkan Django dengan &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;manage.py runserver&lt;/code&gt; atau Flask dengan &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;flask run&lt;/code&gt; . Tapi secara general, built in http server tersebut hanya diperuntukkan pada level development saja. Sedangkan untuk production, WSGI server lebih diutamakan karena kemampuannya untuk spawn multi proses untuk kemudian diteruskan ke multi CPU, kemudian mempunyai fitur logging yang lebih baik (meski ini juga masih &lt;em&gt;debatable&lt;/em&gt;), lebih dapat dioptimasi untuk performa yang lebih baik lagi. Khususnya untuk Gunicorn, WSGI HTTP Server ini juga mudah sekali dikonfigurasi.&lt;/p&gt;

&lt;p&gt;Untuk memasang gunicorn, pastikan kita masih di python virtual environment yang tadi sudah kita buat.&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;source /path/to/virtualenv/bin/activate
pip install gunicorn
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;masih di virtualenv, kita juga bisa menjalankan django di atas gunicorn&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;cd /path/to/mydjangoproject/
gunicorn mydjangoproject.wsgi -b 0.0.0.0:8081

[2019-04-14 22:01:54 +0700] [18174] [INFO] Starting gunicorn 19.9.0
[2019-04-14 22:01:54 +0700] [18174] [INFO] Listening at: http://0.0.0.0:8081 (18174)
[2019-04-14 22:01:54 +0700] [18174] [INFO] Using worker: sync
[2019-04-14 22:01:54 +0700] [18177] [INFO] Booting worker with pid: 18177
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;kemudian kita dapat mengakses django yang dijalankan di atas gunicorn di http://localhost:8081&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Nah&lt;/em&gt; untuk men-_daemonize_ gunicorn pada systemd Ubuntu, maka kita bisa melakukan ini&lt;/p&gt;

&lt;p&gt;Tulis socket file baru di sini &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;sudo vim /etc/systemd/system/gunicorn.socket&lt;/code&gt;&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;[Unit]
Description=gunicorn socket

[Socket]
ListenStream=/run/gunicorn.sock

[Install]
WantedBy=sockets.target
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Kemudian buat file untuk service nya &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;sudo vim /etc/systemd/system/gunicorn.service&lt;/code&gt;&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;[Unit]
Description=gunicorn daemon
Requires=gunicorn.socket
After=network.target

[Service]
User=namauser
Group=namavalidgroup
WorkingDirectory=/path/to/mydjangoproject
EnvironmentFile=/path/to/virtualenv
ExecStart=/path/to/virtualenv/bin/gunicorn \
          --access-logfile /path/to/logfile \
          --workers 3 \
          --bind unix:/run/gunicorn.sock \
          mydjangoproject.wsgi:application

[Install]
WantedBy=multi-user.target
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Untuk namauser, namavalidgroup dan path ke logfile dapat diubah sesuai dengan kondisi masing-masing.&lt;/p&gt;

&lt;p&gt;Untuk menyalakan service gunicorn&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;sudo systemctl daemon-reload
# start gunicorn with mydjangoproject
sudo systemctl start gunicorn.service
# mematikan gunicorn
sudo systemctl stop gunicorn.service
# melihat status gunicorn
sudo systemctl status gunicorn.service
# merestart service gunicorn
sudo systemctl restart gunicorn.service
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id=&quot;nginx-reverse-proxy&quot;&gt;Nginx Reverse Proxy&lt;/h3&gt;

&lt;p&gt;Menggunakan Nginx (engine x, bukan &lt;em&gt;nging&lt;/em&gt;) sebagai reverse proxy, bukan hanya untuk reverse proxy saja. Namun karena beberapa kebutuhan seperti terminasi SSL Certificate, menerapkan limit burst, melakukan load balancing jika memiliki lebih dari 1 backend gunicorn dan fitur nginx lainnya. Dalam skala yang lebih besar, tentu saja nginx saja tidak cukup. Jika diperlukan application load balancer seperti AWS ELB atau ALB atau HTTPS Proxy di GCP dan lain sebagainya, maka hal tersebut juga bisa jadi pilihan. Terutama jika membicarakan sistem microservice yang kompleks, maka solusinya bisa saja menggunakan Envoy proxy, Finagle, Proxygen atau Linkerd. Tapi kali ini mengesampingkan kompleksitas itu, penulis hanya ingin menggunakan nginx saja.&lt;/p&gt;

&lt;p&gt;Pemasangan dan konfigurasi dasar nginx sudah banyak dibahas di lain tempat. Maka pada bagian ini penulis hanya berfokus pada vhost config yang menerapkan konsep reverse proxy dari nginx ke gunicorn. Maka buat file vhost baru &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;sudo vim /etc/nginx/sites-available/mydjangoproject&lt;/code&gt;&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;server {
    listen 80;
    server_name namaserver;

    location = /favicon.ico { access_log off; log_not_found off; }
    location / {
        include proxy_params;
        proxy_pass http://unix:/run/gunicorn.sock;
    }
}
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Demi menghindari log favicon yang deras, biasanya saya pribadi membuang log akses favicon. Untuk namaserver dapat diganti dengan IP server kita atau nama domain yang diarahkan record-nya ke IP server kita.&lt;/p&gt;

&lt;p&gt;Konfigurasi sudah selesai, dan django dapat bekerja di port 80 dan diserve oleh Nginx yang melakukan reverse proxy terhadap gunicorn. Pada kesempatan lain akan dibahas juga bagaimana pengelolaan file media upload, asset static pada Django Framework (baca: &lt;em&gt;jika ada waktu&lt;/em&gt;).&lt;/p&gt;

&lt;p&gt;Good bye now, be nice!&lt;/p&gt;

</content>
 </entry>
 
 <entry>
   <title>Silo atau Limbo</title>
   <link href="https://robee.id/2019/04/06/silo-atau-limbo"/>
   <updated>2019-04-06T17:54:31+07:00</updated>
   <id>https://robee.id/2019/04/06/silo-atau-limbo</id>
   <content type="html">&lt;p&gt;Pada organisasi teknologi kontemporer, sangat lumrah jika ada sebuah tim yang dikhususkan untuk memelihara infrastruktur baik itu pada &lt;em&gt;cloud platform&lt;/em&gt; atau yang berbentuk fisik di &lt;em&gt;datacenter&lt;/em&gt; alias &lt;em&gt;on-premise&lt;/em&gt;. Meskipun banyak organisasi, yang bertahap menuju mode &lt;em&gt;no-ops&lt;/em&gt;, tapi setidaknya, ada satu atau sekelompok manusia yang berurusan dengan infrastruktur. Pengingkaran pada pekerjaan infrastruktur adalah halusinasi belaka.&lt;/p&gt;

&lt;p&gt;Seiring organisasi berkembang, entah skala bisnis, karyawan maupun produk tim &lt;em&gt;software engineering&lt;/em&gt;, maka biasanya semakin banyak hal yang mesti ditangani oleh tim infrastruktur. Bisa jadi pada bagian &lt;em&gt;logging&lt;/em&gt;, tadinya cukup 1 &lt;em&gt;log server&lt;/em&gt;, kini ada kebutuhan untuk mengembangkan sebuah perkakas untuk menganalisa log yang mempermudah pekerjaan berkaitan dengan penanganan insiden. Atau perkakas untuk &lt;em&gt;continuous integration&lt;/em&gt; yang tadinya hanya dipakai untuk 10 &lt;em&gt;jobs_sekarang dipakai ribuan _jobs&lt;/em&gt;. Dan masih banyak lagi.&lt;/p&gt;

&lt;p&gt;Ada beberapa hal di ruang lingkup tanggung jawab tim infrastruktur yang ikut &lt;em&gt;scale&lt;/em&gt; bersamaan dengan berkembangnya perusahaan. Beberapa di antaranya dapat &lt;em&gt;diserahkan&lt;/em&gt; ke pihak ke-tiga, namun atas berbagai pertimbangan, organisasi dan manajemen memutuskan untuk dipelihara oleh tim itu sendiri. Berbagai hal tersebut bisa jadi menyangkut kompleksitas antara biaya dan kebutuhan spesifik, atau komplikasi antara aturan dan ketersediaan opsi di luar sana, atau bisa apa saja. Keputusan menangani pengembangan tanggung jawab di berbagai sisi tanggung jawab tim infrastruktur ini mengarahkan pemisahan bagian kerja atau spesialisasi kerja.&lt;/p&gt;

&lt;p&gt;Normalnya manusia adalah keterbatasan. Entah terbatas akal – pikiran, waktu – ruang, atau uang – etos kerja. Sebuah tim yang tadinya &lt;em&gt;fluid&lt;/em&gt; sekarang harus terpisah atau &lt;em&gt;silo-ed on purpose.  _Pada sebuah organisasi yang mengakulturasi istilah _DevOps&lt;/em&gt; tentunya ini seakan bertentangan dengan salah dua konsep di dalamnya yang mengagungkan &lt;em&gt;sharing knowledge&lt;/em&gt; dan &lt;em&gt;sharing responsibility&lt;/em&gt;. Berbagi pengetahuan dengan harapan dapat berbagi tanggung jawab bersama semua anggota tim (baik pengembang maupun infrastruktur). Jika &lt;em&gt;DevOps&lt;/em&gt; adalah Kal-El, maka &lt;em&gt;Silo&lt;/em&gt; adalah salah satu batu kripton yang dapat melemahkan konsep dan kultur ini.&lt;/p&gt;

&lt;p&gt;Entah konsep berbagi tanggung jawab ini terlalu naif, atau sebenarnya Silo adalah keniscayaan, tapi sebenarnya segala keterbatasan tersebut menjadi peluang mengeruk pundi – pundi emas dengan menyediakan jasa untuk meringankan beban organisasi. Jika disadarkan, pilihannya apakah kembali mempertimbangkan pihak ke-tiga alias kapitalis masalah – dengan memaklumi dan menerima kekurangan, atau masih bersikeras pada bentuk organisasi infrastruktur yang tidak ideal – dengan memaklumi segregasi antar bagian. Pilihan yang seolah berputar dalam limbo pikiran.&lt;/p&gt;

&lt;p&gt;Diskusi? &lt;em&gt;Yuk lah!&lt;/em&gt;&lt;/p&gt;

</content>
 </entry>
 

</feed>
