Proje: Okul B2B App · Hub: Okul B2B App — Incidents

API URL Legacy Build Migration — api.okul.work → api.okul.com.tr

Commit’ler: 9ad2bd6, ee0fcd8

Semptom

Eski build’lerde api.okul.work test URL’i hardcoded kalmıştı. Bu URL’i kullanan eski build’ler production’da hata veriyordu.

Root Cause

Google Play review sırasında test API (api.okul.work) gösterilmişti. Review onayı sonrası Firebase Remote Config ile production URL’e geçiş planlanmıştı ama Remote Config tam aktif edilmemişti. Bu sırada bazı kullanıcılar eski build’leri kullanmaya devam etti.

Çözüm

  1. IS_LEGACY_BUILD flag eklendi: EXPO_PUBLIC_API_URL içinde 'okul.work' varsa true
  2. _layout.tsx’te legacy build tespiti → zorla logout + OTA update tetikleme
  3. Config.ts’de production’da api.okul.work URL’leri api.okul.com.tr’ye yönlendirme
  4. Tüm eas.json profilleri api.okul.com.tr’ye güncellendi
  5. Expo Go hâlâ api.okul.work kullanıyor (test environment için)

Kalıcı Kural

api.okul.work sadece Expo Go geliştirme ortamı için. Production build’larda hiçbir zaman api.okul.work kullanılmamalı.