This repository has been archived on 2026-03-21. You can view files and clone it, but cannot push or open issues or pull requests.
payfrit-biz/api/orders
John Mizerek dc9db32b58 Add API performance profiling, caching, and query optimizations
- Add queryTimed() wrapper and logPerf() for per-endpoint timing metrics
- Add api_perf_log table flush mechanism with background thread batching
- Add application-scope cache (appCacheGet/Put/Invalidate) with TTL
- Cache businesses/get (5m), addresses/states (24h), menu/items (2m)
- Fix N+1 queries in orders/history, orders/listForKDS (batch fetch)
- Fix correlated subquery in orders/getDetail (LEFT JOIN)
- Combine 4 queries into 1 in portal/stats (subselects)
- Optimize getForBuilder tree building with pre-indexed parent lookup
- Add cache invalidation in update, saveBrandColor, updateHours, saveFromBuilder
- New admin/perf.cfm dashboard (localhost-protected)
- Instrument top 10 endpoints with queryTimed + logPerf

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-29 20:41:27 -08:00
..
abandonOrder.cfm App Store Version 2: Multi-menu support, beacon lookup, category scheduling 2026-01-23 19:51:44 -08:00
checkStatusUpdate.cfm Add API performance profiling, caching, and query optimizations 2026-01-29 20:41:27 -08:00
debugLineItems.cfm Add business portal, Stripe Connect, beacon APIs, and task system 2026-01-01 23:38:26 -08:00
getActiveCart.cfm Fix null value handling in getActiveCart API 2026-01-23 21:39:25 -08:00
getCart.cfm Fix null/empty value handling in order APIs 2026-01-23 21:30:13 -08:00
getDetail.cfm Add API performance profiling, caching, and query optimizations 2026-01-29 20:41:27 -08:00
getOrCreateCart.cfm Fix null/empty value handling in order APIs 2026-01-23 21:30:13 -08:00
getPendingForUser.cfm Add user account APIs and fix Lucee header handling 2026-01-08 20:01:07 -08:00
history.cfm Add API performance profiling, caching, and query optimizations 2026-01-29 20:41:27 -08:00
listForKDS.cfm Add API performance profiling, caching, and query optimizations 2026-01-29 20:41:27 -08:00
setLineItem.cfm Fix null value handling in setLineItem API 2026-01-23 21:40:32 -08:00
setOrderType.cfm Fix null value handling in setOrderType API 2026-01-23 21:41:31 -08:00
submit.cfm Add user account APIs and fix Lucee header handling 2026-01-08 20:01:07 -08:00
updateStatus.cfm Add expo/pickup tasks for takeaway and delivery orders when kitchen finishes 2026-01-18 13:44:55 -08:00