From cd6b41a13af403d32e08ff416e60982b5cb718dc Mon Sep 17 00:00:00 2001 From: Thijs Schreijer Date: Mon, 31 Aug 2026 22:27:42 +0200 Subject: Add SSE sink (socket.sse module) Implements SSE by using the replacement body sink. Replaces the sink with an SSE parser if the response is a text stream. Example application included --- samples/README | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'samples/README') diff --git a/samples/README b/samples/README index 4ee06b6..5fff925 100644 --- a/samples/README +++ b/samples/README @@ -104,6 +104,15 @@ Unix machines. It uses the lp.lua implementation, in the samples directory. Just run 'lua lpr.lua queue=' and the file will print! + sse.lua -- Server-Sent Events (SSE) client + +This little program uses socket.sse to connect to a text/event-stream +URL and print each event received, stopping after a fixed number of +them (5 by default). With no arguments it connects to a public live +test feed, so you can try it with no setup at all. Just run + + lua sse.lua [] [] + cddb.lua -- CDDB client This is the first try on a simple CDDB client. Not really -- cgit v1.2.3-55-g6feb