[Wikitech-l] Re: Different cache invalidation rules for similar users?

2022-04-03 Thread Krinkle
On Sun, 3 Apr 2022, at 17:57, Strainu wrote:
> Hi,
> 
> I've recently seen some complaints from 2 users located in the same country 
> that it takes about half a day for the Javascript changes to propagate. Users 
> from different countries but similar user rights don't seem to have this 
> problem.
> 
> Is it possible to have different cache invalidation rules for different 
> countries? If not, what else could cause this behavior?

It depends on what kind of changes and to what piece of JavaScript code.

My guess would be that this is a change not to deployed software or gadgets or 
site scripts, but a user script. And that the user script is loaded by URL via 
importScriptURI or mw.loader.load. And that the URL is non-standard (e.g. not 
exactly /w/index.php?title=..=raw=text/javascript, but with other 
parameters or different order or different encoding). This means that it is not 
purged on edits.

In that case, it will stay cached. It might then be that someone near one data 
center is lucky that the URL is not used there before and sees no cache. Or 
that near another data center the URL is not popular enough to stay in the CDN 
and thus falls out before the 7 day expiry despite no observed edit or purge.

To know for sure, I would need to see the specific script edit and how the 
script is loaded.

-- Krinkle
___
Wikitech-l mailing list -- wikitech-l@lists.wikimedia.org
To unsubscribe send an email to wikitech-l-le...@lists.wikimedia.org
https://lists.wikimedia.org/postorius/lists/wikitech-l.lists.wikimedia.org/

[Wikitech-l] Re: Different cache invalidation rules for similar users?

2022-04-03 Thread Brian Wolff
Its possible that different cache clusters have different versions of a
cached file.

Different ways of loading js have different cache characteristics (e.g.
some have much less purging) so it can depend a bit on method. Its also
possible that one datacenter missed a cache purge the others did not,
however in modern times this is a much more reliable process so unlikely.

--
Bawolff

On Sunday, April 3, 2022, Strainu  wrote:

> Hi,
>
> I've recently seen some complaints from 2 users located in the same
> country that it takes about half a day for the Javascript changes to
> propagate. Users from different countries but similar user rights don't
> seem to have this problem.
>
> Is it possible to have different cache invalidation rules for different
> countries? If not, what else could cause this behavior?
>
> Thanks,
>   Strainu
___
Wikitech-l mailing list -- wikitech-l@lists.wikimedia.org
To unsubscribe send an email to wikitech-l-le...@lists.wikimedia.org
https://lists.wikimedia.org/postorius/lists/wikitech-l.lists.wikimedia.org/

[Wikitech-l] Different cache invalidation rules for similar users?

2022-04-03 Thread Strainu
Hi,

I've recently seen some complaints from 2 users located in the same country
that it takes about half a day for the Javascript changes to propagate.
Users from different countries but similar user rights don't seem to have
this problem.

Is it possible to have different cache invalidation rules for different
countries? If not, what else could cause this behavior?

Thanks,
  Strainu
___
Wikitech-l mailing list -- wikitech-l@lists.wikimedia.org
To unsubscribe send an email to wikitech-l-le...@lists.wikimedia.org
https://lists.wikimedia.org/postorius/lists/wikitech-l.lists.wikimedia.org/