Anthony Accioly on Nostr: πππ: When acting as a reverse proxy, Nginx uses HTTP/1.0 and doesnβt ...
πππ: When acting as a reverse proxy, Nginx uses HTTP/1.0 and doesnβt enable πππππππππ (HTTP persistent connections) to upstream servers by default. My reverse proxy was happily responding to clients using HTTP/1.1 or HTTP/2.0 while still using HTTP/1.0 to connect to my personal relay.
I didnβt think it would make much of a difference, given that Nostr is WebSocket-basedβi.e., HTTP connections are quickly upgraded with:
π²πππππππππ:βπππππππ
πππππππ:βπ ππππππππ
Plus, my personal relay isnβt exactly handling a lot of traffic.
Nevertheless, configuring a small number of cached connections apparently reduced CPU usage, not only for Nginx but also for Haven itself. The more you know...
Iβve enabled persistent connections for Nginx on my Haven repo and merged girino (npub18laβ¦cfsz)'s latest contribution from upstream. Do let me know if you encounter any issues.
https://www.f5.com/company/blog/nginx/avoiding-top-10-nginx-configuration-mistakes#no-keepalives
#Haven #Nginx #HTTP #ReverseProxy #WebSockets #Nostr
I didnβt think it would make much of a difference, given that Nostr is WebSocket-basedβi.e., HTTP connections are quickly upgraded with:
π²πππππππππ:βπππππππ
πππππππ:βπ ππππππππ
Plus, my personal relay isnβt exactly handling a lot of traffic.
Nevertheless, configuring a small number of cached connections apparently reduced CPU usage, not only for Nginx but also for Haven itself. The more you know...
Iβve enabled persistent connections for Nginx on my Haven repo and merged girino (npub18laβ¦cfsz)'s latest contribution from upstream. Do let me know if you encounter any issues.
https://www.f5.com/company/blog/nginx/avoiding-top-10-nginx-configuration-mistakes#no-keepalives
#Haven #Nginx #HTTP #ReverseProxy #WebSockets #Nostr