Open fragosog opened 1 year ago
Wound up with
<LocationMatch "^(/|/index\.html)$" >
Header set Cache-Control "max-age=0, no-cache, no-store, must-revalidate"
Header set Pragma "no-cache"
</LocationMatch>
per above PS.
To configure Cache-Control headers in your Apache server, you can use the following directives:
<Location /sparql> Header set Cache-Control "max-age=0, no-cache, no-store, must-revalidate" Header set Pragma "no-cache" </Location>
This snippet ensures that the /sparql
location is not cached by browsers or CDNs. The max-age=0
directive prevents caching, and no-cache
ensures that the content is always revalidated. Additionally, you might consider applying similar settings to specific files or directories as needed
Thanks, but it turns out it's not the endpoint or the page. The caching is being done by a javascript widget in the page. Yet to be fixed . . .
OK, can't test in the servers, but I think this fixes the caching in the resultset section. In the index.content file in si-web/html, below the line
(yasgui.getTab()).setQuery("select distinct ?graph where { graph ?graph { ?s ?p ?o } } limit 100");
added:
yasgui.getTab().yasr.options , {
requestConfig: {
persistencyExpire: 0,
}};
it's in git tag 1.1.0. Please update the git repo in the dev server and test it with good and bad queries for several days before putting in a deployment request for the upper tiers. Feel free to ping for the build details.
Noticed in the ASK query when it was being enabled in the modsec rules. Need to add something like this to apache configuration
PS Maybe the page should be not-cached rather than the endpoint. The query doesn't run in a naive browser, so probably the error page is what's getting cached.