Add cache-control headers to HTTP requests and update version to 1.2

This commit is contained in:
2026-04-23 06:40:28 +02:00
parent a0c546dade
commit 03b133827b
2 changed files with 3 additions and 1 deletions
+1 -1
View File
@@ -4,7 +4,7 @@ plugins {
} }
group = 'de.catmangames.jsonfetcher' group = 'de.catmangames.jsonfetcher'
version = '1.1' version = '1.2'
java { java {
sourceCompatibility = JavaVersion.VERSION_11 sourceCompatibility = JavaVersion.VERSION_11
@@ -58,6 +58,8 @@ public class JsonFetcher {
HttpRequest req = HttpRequest.newBuilder() HttpRequest req = HttpRequest.newBuilder()
.uri(java.net.URI.create(baseUrl + path)) .uri(java.net.URI.create(baseUrl + path))
.header("Cache-Control", "no-cache, no-store, must-revalidate")
.header("Pragma", "no-cache")
.GET() .GET()
.build(); .build();