File 0417-inets-Document-sending-status-with-mod_esi.patch of Package erlang

From ec373d44599af5b63e191bb51227d33accaa19f1 Mon Sep 17 00:00:00 2001
From: Johannes Christ <jc@jchri.st>
Date: Sat, 17 Jun 2023 14:38:19 +0200
Subject: [PATCH] inets: Document sending status with mod_esi

---
 lib/inets/doc/src/mod_esi.xml | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/lib/inets/doc/src/mod_esi.xml b/lib/inets/doc/src/mod_esi.xml
index 9bdaac7a95..5f992303e9 100644
--- a/lib/inets/doc/src/mod_esi.xml
+++ b/lib/inets/doc/src/mod_esi.xml
@@ -150,7 +150,14 @@
 	that is, <c>"\r\n\r\n",</c> the server assumes that no HTTP
 	header fields will be generated.</p>
 
-	<p><c>Env</c> environment data of the request see description above.</p>
+	<p>To set the response status code, the special <c>status</c> response
+	header can be sent. For instance, to acknowledge creation of a resource
+	and annotate the response content type with JSON, one could respond with
+	the following headers:</p>
+
+	<code type="erl">"status: 201 Created\r\n content-type: application/json\r\n\r\n"</code>
+
+	<p><c>Env</c> environment data of the request, see description above.</p>
 		
 	<p><c>Input</c> is query data of a GET request or the body of
 	a PUT or POST request. The default behavior (legacy reasons)
-- 
2.35.3

openSUSE Build Service is sponsored by