Caching and status codes

I apologise if anyone got this email twice. I forgot to switch out my
email address before submitting to the list. Following is my original
reply.


Ok when I replied I thought you were going to argue about something
ideological about how the content creator should get the final say in
how their content is accessed, but it looks like you are arguing on a
technical viewpoint. What you are saying does not make a lot of sense to
me though.

> Rude clients are going to cache.

This is the statement that bothered me because it seemed very weird to
consider a client "rude" for not making requests. So I asked about it
for clarification.

> > I don't understand why a client caching responses is rude. Or rather,
> > I don't understand who it is being rude to. When I configure my HTTP
> > or Gemini browser to cache every response, is my browser now being
> > rude to me? Is it being rude to the server?
> The rude thing here would be having to serve large files over Gemini
> and expect them to be served often,

But here you are saying that the rude thing here is having to serve
large files over gemini and expecting them to be served often. This
would be the server being rude, and clients caching or not caching
resources would not have an impact on how large a server's reponses are.

If anything, it would result in less traffic and at least partially
mitigate the issue. If your server is being _rude_ and sending large
responses, my client is not gonna make it worse by requesting it every
single time. Your server might have a lot of bandwidth, my client does
not.

> the protocol operates under the assumption that caching does not exist,
> it's by convention, this simplifies the client a LOT and removes such
> uncertainty when writing dynamic content for Gemini. Consider reading
> 2.1.1 in gemini://gemini.circumlunar.space/docs/faq.gmi

The protocol operates under the assumption that caching does not exist
in order to make clients and servers simpler. A client adding caching
would NOT affect a server negatively. If you consider caching clients to
be rude clients, too bad, you will never notice them because instead of
making extra requests, they are making less. I suppose you can ask them
to apologise for not making you spend money on compute/bandwidth etc.

> > How can something that causes less resource usage on the server be
> > rude to the server, or something I configured or downloaded as a
> > "client that has caching" be rude to me for using it?
> Because the server operates under the assumption that content is not
> cached, if you're serving large files over Gemini you should look
> somewhere else, this is not bittorrent, and if your server is eating up
> a lot of resources, you're doing Gemini wrong, Gemini servers don't
> have to be complicated, that's your own problem. Consider using
> connection queue and serving connections one by instead of forking or
> multithreading because the protocol allows such simple design by
> closing the connection right after the transaction, it's not like in
> HTTP land where you have keep-alive.

Again, you are talking about making servers more complicated. If my
client does not cache and your server sends large responses, this is
indeed a problem and you might have to make your server more complex to
handle it. Caching clients would make simpler server code possible, as
performance tricks would not be necessary. But even ignoring that, a
client that caches responses would not make your server more complex.

> > Is not doing everything a server sends being rude to the server
> > operator? If a server sends a 100000000x100000000 image, is my image
> > viewer being rude for refusing to decode/display it?
> No, its being sane, this does not apply here.

So it is being sane when a server says "display this monstrous image"
and the client refuses, but it is insane when the server says "please
download this resource that you downloaded 3 seconds ago" and the client
says "I'll just use the response I have cached"?

> Does everyone here require a lecture on why their desired features
> aren't in the protocol yet? seems to be the common point of discussion
> here, as if the protocol is NOT ENOUGH, I don't know what brought your
> interest here, did you see it as a great way of avoiding the current
> scope creep of the modern web, or as a playground to satisfy your bad
> ideas?

The whole point of the discussion is that clients WILL cache resources.
Gemini benefits a lot from having a wide range of different clients. You
simply can't control everyone's use case to fit the way you think they
should consume content.

Just like some browsers/proxies cache HTTP and Gopher responses, some
people who are bandwidth constrained or simply not wasteful will choose
to cache their Gemini responses too. The discussion throws out the idea
of client HINTS that will say "This might be a dynamic response, maybe
don't cache it". Neither the server nor the client needs to take
advantage of this, a client can always cache or never cache, and a
server can expect everything to be cached or not cached. Just like
before.

I understand the desire to keep the spec short, and actually agree with
people on this. I believe a new response code for this is not necessary.
But a client that caches something is not being rude, at least not more
than a client that offers to save the resource to the disk or to send it
to a printer.

> Do you have anything else to help the community with? perhaps hosting
> content in the Gemini space? or helping in the development of tools
> interacting with the protocol? or is your interest just satisfied when
> the spec becomes ten times of its current size, then you can MAYBE
> decide to use the protocol for yourself.

Disagreeing with someone is one thing, but you don't have to attack them
like this. Before you shame other people, please enlighten us with the
tangible value that you have provided to the greater Gemini community.

> If any feature does not add a great value at an acceptable cost to the
> simplicity of the protocol, consider it rejected before even proposing
> it, I don't want to have a different experience browsing Gemini space
> using netcat than using Kristall.

I agree with this completely.

--
Leo

---

Previous in thread (20 of 55): 🗣️ Nathan Galt (mailinglists (a) ngalt.com)

Next in thread (22 of 55): 🗣️ John Cowan (cowan (a) ccil.org)

View entire thread.