mirror of
https://github.com/taylanbakircioglu/haproxy-openmanager.git
synced 2026-09-18 00:26:51 +00:00
59c0287972
CRITICAL FIXES after deep analysis: 1. REMOVED SSL certificate_ids comparison from parse endpoint ❌ PROBLEM: Parse marked frontend as UPDATE when SSL changed ❌ REALITY: Bulk-create PRESERVES SSL settings (line 1588-1589: MVP decision) ✅ SOLUTION: Don't compare SSL fields in parse endpoint - ssl_enabled, ssl_certificate_ids, ssl_port are NOT compared - Aligns with MVP: "Preserve manual SSL configuration" - Prevents false UPDATE status for SSL-only changes 2. ADDED missing frontend field comparisons ✅ timeout_http_request ✅ rate_limit ✅ compression (using 'in' operator for boolean) ✅ log_separate (using 'in' operator for boolean) ✅ monitor_uri - These fields exist in bulk-create but were missing in parse comparison - Now parse endpoint checks ALL updatable fields consistently 3. KEPT json import (used elsewhere for json.dumps) MVP DESIGN CONSISTENCY: ┌─────────────────┬────────────────┬─────────────────┐ │ Field Type │ Parse Check │ Bulk-Create │ ├─────────────────┼────────────────┼─────────────────┤ │ SSL Settings │ ❌ SKIP │ ❌ PRESERVE │ │ ACL Rules │ ❌ SKIP │ ❌ PRESERVE │ │ Regular Fields │ ✅ COMPARE │ ✅ MERGE │ │ Boolean Fields │ ✅ 'in' check │ ✅ 'in' check │ │ Numeric Fields │ ✅ truthy+cmp │ ✅ truthy+cmp │ └─────────────────┴────────────────┴─────────────────┘ MERGE STRATEGY (MVP): - Config has field → Compare with DB → UPDATE if different - Config missing field → Preserve DB value → NO UPDATE - SSL/ACL → Always preserve (manual config protected) TESTED SCENARIOS: ✅ Frontend with SSL changes only → Status: NO CHANGES (correct!) ✅ Frontend with timeout change → Status: UPDATE (correct!) ✅ Frontend with compression toggle → Status: UPDATE (correct!) ✅ Same config re-imported → Status: NO CHANGES (correct!) Impact: Parse endpoint now accurately reflects what bulk-create will actually do.