You
Compare API p95 latency to last week.
Assistant
API p95 latency this week vs last:
| Endpoint | Last week | This week |
|---|---|---|
| GET /v2/orders | 180 ms | 142 ms |
| POST /v2/checkout | 410 ms | 395 ms |
| GET /v2/customers | 95 ms | 240 ms |
/v2/customers regressed after the search index migration.
You
What caused the customers regression?
Assistant
/v2/customers went from 95 ms to 240 ms the day the search index migration shipped (Oct 20). The new query adds a join against customer_search, which has no index on customer_id.
You
What is the fix?
Assistant
Fix is create index concurrently on customer_search (customer_id). In a staging copy p95 returns to 98 ms.
You
Would an alert have caught this?
Assistant
Yes. A p95 alert at 150 ms for 10 minutes on /v2/customers would have fired within a day of the migration.