Re: Use CDN for djangoproject.com

2019-04-12 Thread Tobias McNulty
Last week we had an average hit ratio of around 63%, including ~10 purges that dropped the rate down temporarily before the cache rebuilt: [image: Screenshot 2019-04-11 09.37.57.png] In terms of bandwidth, we're averaging around 5 GB/day for docs and 10 GB/day for static. Giving static its own doma

Re: Use CDN for djangoproject.com

2019-03-31 Thread Tobias McNulty
On Sat, Mar 30, 2019 at 7:32 PM Tom Forbes wrote: > I’m a stats nerd, and I think I’m not alone on this list in that respect, > would it be possible to share some more numbers after a week of usage? I > would be interested in the total bandwidth used/saved, the global > distribution of requests a

Re: Use CDN for djangoproject.com

2019-03-11 Thread Adam Johnson
Looking good! Thanks for your work Tobias. I get 30ms through CDN instead of 230ms from here in London, UK. I take back my bad comments about Fastly, since they are giving free credits :) If you don't need custom Varnish code they are quite easy to configure and easy to contact on IRC.n On Mon,

Re: Use CDN for djangoproject.com

2019-03-11 Thread Tobias McNulty
Hi all, These changes have been deployed (though we're not yet using a CDN for the primary domain, docs.djangoproject.com, so you shouldn't notice a change). The alternate URL (https://django-docs.global.ssl.fastly.net/en/2.1/) will now cache docs pages for up to a week, and the hourly docs rebui

Re: Use CDN for djangoproject.com

2019-02-25 Thread Florian Apolloner
Hi Tobias, I think a cache of something like a day will most certainly not hurt anyone. If the need arises we can still manually purge the cache as needed. Cheers, Florian On Sunday, February 24, 2019 at 1:00:50 AM UTC+1, Tobias McNulty wrote: > > Hi all, > > An implementation question has come

Re: Use CDN for djangoproject.com

2019-02-24 Thread Tobias McNulty
Tom, That's great! Thanks for the feedback. I've updated the PR with something along the lines of what you suggested (along with the corresponding configuration in Fastly). Take a look and let me know what you think. Cheers, Tobias On Su

Re: Use CDN for djangoproject.com

2019-02-24 Thread Tom Forbes
Awesome work! For my location (Lisbon, Portugal) it takes about 130ms to retrieve the HTML for a docs page ( https://django-docs.global.ssl.fastly.net/en/2.1/intro/reusable-apps/ to be specific). The same page on docs.djangoproject.com responds in 800–900ms. On 24 February 2019 at 14:35:55, Tob

Re: Use CDN for djangoproject.com

2019-02-24 Thread Tobias McNulty
Hi Tom, Thanks for your message. I think we'll end up with Fastly since it would be free, but I'm waiting to see their sponsorship contract. CloudFront would work too but I don't know of any such open source sponsorship options with AWS. I will say wildcard purging looks a bit simpler in CloudFro

Re: Use CDN for djangoproject.com

2019-02-23 Thread Tom Forbes
Sorry, I did not completely grok your message. I would be in favour of just invalidating the whole cache if needed, it seems the simplest solution. Invalidating most of the cache on every non-dev deploy would also be OK I think. On Sun, 24 Feb 2019, 00:10 Tom Forbes, wrote: > Which CDN are we go

Re: Use CDN for djangoproject.com

2019-02-23 Thread Tom Forbes
Which CDN are we going to use? Fastly has awesome sub 100ms global invalidation which we can trigger on every deploy, and cloudflare has something similar. On Sun, 24 Feb 2019, 00:00 Tobias McNulty, wrote: > Hi all, > > An implementation question has come up regarding cache lifetime (see this >

Re: Use CDN for djangoproject.com

2019-02-23 Thread Tobias McNulty
Hi all, An implementation question has come up regarding cache lifetime (see this PR ). Right now, the whole site (including docs) has the site-wide Django cache enabled

Re: Use CDN for djangoproject.com

2019-02-15 Thread Tobias McNulty
Thanks for sharing the results. I did manage to get a domain set up with working SSL, in case you want to use it: https://django-docs.global.ssl.fastly.net/en/2.1/ Tobias On Thu, Feb 14, 2019, 11:49 PM Cheng C Thanks for the test site, Tobias. > > Tested from Melbourne, Australia: > > https://d

Re: Use CDN for djangoproject.com

2019-02-14 Thread Cheng C
Thanks for the test site, Tobias. Tested from Melbourne, Australia: https://docs.djangoproject.com/en/2.1/ Average Ping: 268ms Browser: 22 requests, 238KB transferred, Finish: 2.72s, DOMContentLoaded: 1.37s, Load: 1.68s https://docs.djangoproject.com.global.prod.fastly.net/en/2.1/ Average Pi

Re: Use CDN for djangoproject.com

2019-02-14 Thread Tobias McNulty
Adam, is there another provider you would recommend instead, that does not require changing DNS providers? FWIW, python.org does in fact use Fastly: $ host www.python.org www.python.org is an alias for dualstack.python.map.fastly.net. dualstack.python.map.fastly.net has address 151.101.248.223 dua

Re: Use CDN for djangoproject.com

2019-02-14 Thread Adam Johnson
I have not had great experience with Fastly in the past and would avoid them. They run an old fork of Varnish which is not fun to configure. On Thu, 14 Feb 2019 at 11:16, Josh Smeaton wrote: > Cloudflare have many SSL options, including fully encrypted and > authenticated comms all the way throu

Re: Use CDN for djangoproject.com

2019-02-14 Thread Tobias McNulty
Fastly could be a good fit. I've reached out to see if they'd be willing to provide a free account. If anyone on this list works at Fastly or knows someone who does, feel free to email/introduce me off list, too. Tobias On Thu, Feb 14, 2019, 5:58 AM Tom Forbes That makes sense, but in this case

Re: Use CDN for djangoproject.com

2019-02-14 Thread Josh Smeaton
Cloudflare have many SSL options, including fully encrypted and authenticated comms all the way through (terminate and reconnect). Typically done by having a “hidden” origin domain that also hosts a certificate. I’m unsure if it’s possible to have both origin and front hosting the same name so that

Re: Use CDN for djangoproject.com

2019-02-14 Thread Tom Forbes
That makes sense, but in this case we are only talking about potentially yielding control of the docs subdomain which is not used to serve sensitive build artefacts? Another option is fastly.com, who support other large open source projects for free. They essentially give you geographically distri

Re: Use CDN for djangoproject.com

2019-02-13 Thread Florian Apolloner
On Wednesday, February 13, 2019 at 11:25:37 PM UTC+1, Josh Smeaton wrote: > > Why do we not want to use Cloudflare? > Last time I checked (if one puts the full site behind cloudflare) you'd have nasty checks that usually triggers captchas for Tor users etc. From what I can tell there was no wa

Re: Use CDN for djangoproject.com

2019-02-13 Thread Markus Holtermann
Hi all to elaborate on what Tobias said: we deliberately have the infrastructure spread across multiple service providers: DNS registry, nameservers, hosting, TLS certificate authority, … None of them have access to everything. The reason is that we offer the download of the release artifacts f

Re: Use CDN for djangoproject.com

2019-02-13 Thread Tobias McNulty
For me it's the trust factor (allowing someone else to decrypt and re-encrypt all our data). This may be less of an issue for the docs site, *if* we don't have to assign DNS authority for the whole domain to the CDN provider. Tobias On Wed, Feb 13, 2019, 7:47 PM Kye Russell I’ve been hearing th

Re: Use CDN for djangoproject.com

2019-02-13 Thread Kye Russell
I’ve been hearing that there are other CDN providers that offer a very comparable service for a fraction of the cost of CloudFront. Anyways, at this stage let’s not get bogged down on provider decisions. I’m curious if anyone has any general objections to a CDN of any kind. It shouldn’t be that b

Re: Use CDN for djangoproject.com

2019-02-13 Thread Tom Forbes
I would highly recommend cloudflare. It's free, can be set up in 15 minutes and works really, really well. On Thu, 14 Feb 2019, 00:36 Cristiano Coelho, wrote: > Consider AWS's cloudfront then :) > > El martes, 12 de febrero de 2019, 2:34:09 (UTC-5), Florian Apolloner > escribió: >> >> Especially

Re: Use CDN for djangoproject.com

2019-02-13 Thread Cristiano Coelho
Consider AWS's cloudfront then :) El martes, 12 de febrero de 2019, 2:34:09 (UTC-5), Florian Apolloner escribió: > > Especially cloudflare is a service we do not want to use. as for the docs > only, does the mirror on rtd work better for you? They are probably behind > a CDN. > > Cheers, > Flor

Re: Use CDN for djangoproject.com

2019-02-13 Thread Josh Smeaton
Why do we not want to use Cloudflare? FWIW I agree that the docs site performance is not great (also from melbourne) - but I'd still suffer the performance hit over going via RTD mirrors for familiarity. On Tuesday, 12 February 2019 18:34:09 UTC+11, Florian Apolloner wrote: > > Especially clou

Re: Use CDN for djangoproject.com

2019-02-11 Thread Florian Apolloner
Especially cloudflare is a service we do not want to use. as for the docs only, does the mirror on rtd work better for you? They are probably behind a CDN. Cheers, Florian On Tuesday, February 12, 2019 at 6:43:41 AM UTC+1, Cheng C wrote: > > Hi, > > Is it possible to utilize a CDN service for d

Use CDN for djangoproject.com

2019-02-11 Thread Cheng C
Hi, Is it possible to utilize a CDN service for djangoproject.com, or at least on docs.djangoproject.com? The site is actually quite fast for me but I think there is still room for improvement. Cloudflare sponsored dozens of open source projects