From 0d4f7934f716ad914074f484bfca820b1f65305d Mon Sep 17 00:00:00 2001 From: Carsten Rehfeld Date: Sat, 16 May 2026 23:53:21 +0200 Subject: [PATCH] fix(admin): bust admin.js browser cache with ?v=3, disable immutable static cache Quarkus defaults to Cache-Control: immutable, max-age=86400 for static files. The immutable flag means browsers ignore hard-refresh and serve stale JS for 24h. Fix: version query string on admin.js URLs, max-age=300 (5min), clear immutable-paths. Co-Authored-By: Mira Rehfeld --- apix-admin/src/main/resources/application.properties | 4 ++++ .../main/resources/templates/DashboardResource/global.html | 2 +- .../main/resources/templates/DashboardResource/sandbox.html | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/apix-admin/src/main/resources/application.properties b/apix-admin/src/main/resources/application.properties index 017287c..c8bc579 100644 --- a/apix-admin/src/main/resources/application.properties +++ b/apix-admin/src/main/resources/application.properties @@ -12,3 +12,7 @@ apix.admin.key=${APIX_API_KEY:dev-insecure-key-change-in-prod} # Session cookie name apix.admin.cookie-name=apix_admin_session + +# Static assets — short cache so deploys take effect without hard-refresh +quarkus.http.static-resources.max-age=300 +quarkus.http.static-resources.immutable-paths= diff --git a/apix-admin/src/main/resources/templates/DashboardResource/global.html b/apix-admin/src/main/resources/templates/DashboardResource/global.html index 5644427..c9a9554 100644 --- a/apix-admin/src/main/resources/templates/DashboardResource/global.html +++ b/apix-admin/src/main/resources/templates/DashboardResource/global.html @@ -106,6 +106,6 @@ nav { - + diff --git a/apix-admin/src/main/resources/templates/DashboardResource/sandbox.html b/apix-admin/src/main/resources/templates/DashboardResource/sandbox.html index 97aed2d..04eac74 100644 --- a/apix-admin/src/main/resources/templates/DashboardResource/sandbox.html +++ b/apix-admin/src/main/resources/templates/DashboardResource/sandbox.html @@ -149,7 +149,7 @@ button.promote:hover { background: #2ea043; } - +