From e39252ae5048156ac33999ce9bb07212798b6b80 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Hoguin?= Date: Thu, 26 Sep 2019 14:05:08 +0200 Subject: Add Gun 2.0-pre documentation But don't propagate via RSS. --- docs/en/gun/2.0/manual/gun_socks_up/index.html | 198 +++++++++++++++++++++++++ 1 file changed, 198 insertions(+) create mode 100644 docs/en/gun/2.0/manual/gun_socks_up/index.html (limited to 'docs/en/gun/2.0/manual/gun_socks_up') diff --git a/docs/en/gun/2.0/manual/gun_socks_up/index.html b/docs/en/gun/2.0/manual/gun_socks_up/index.html new file mode 100644 index 00000000..6fcbc69b --- /dev/null +++ b/docs/en/gun/2.0/manual/gun_socks_up/index.html @@ -0,0 +1,198 @@ + + + + + + + + + + Nine Nines: gun_socks_up(3) + + + + + + + + + + + + + + + + +
+
+
+
+ +

gun_socks_up(3)

+ +

Name

+

gun_socks_up - The Socks connection is up

+

Description

+
+
{gun_socks_up, ConnPid, Protocol}
+
+ConnPid  :: pid()
+Protocol :: http | http2 | socks
+
+

The Socks connection is up.

+

This message informs the owner/calling process that the connection completed through the configured Socks proxy.

+

If Gun is configured to connect to another Socks server, then the connection is not usable yet. One or more gun_socks_up(3) messages will follow.

+

Otherwise, Gun will start processing the messages it received while waiting for the connection to be up. If this is a reconnection, then this may not be desirable for all requests. Those requests should be cancelled when the connection goes down, and any subsequent messages ignored.

+

Elements

+
ConnPid
+

The pid of the Gun connection process.

+
+
Protocol
+

The protocol selected for this connection. It can be used to determine the capabilities of the server.

+
+
+

Changelog

+
  • 2.0: Message introduced. +
  • +
+

Examples

+
Receive a gun_socks_up message in a gen_server
+
+
handle_info({gun_socks_up, ConnPid, _Protocol},
+            State=#state{conn_pid=ConnPid}) ->
+    %% Do something.
+    {noreply, State}.
+
+

See also

+

gun(3), gun:open(3), gun:open_unix(3), gun:await_up(3), gun_up(3), gun_down(3), gun_error(3)

+ + + + + + +
+ +
+ + +

+ Gun + 2.0 + Function Reference + +

+ + + +

Navigation

+ +

Version select

+ + +

Like my work? Donate!

+

Donate to Loïc Hoguin because his work on Cowboy, Ranch, Gun and Erlang.mk is fantastic:

+
+ + + + + + + + + +

Recurring payment options are also available via BountySource. These funds are used to cover the recurring expenses like dedicated servers or domain names.

+ + + +
+
+
+
+ + + + + + + + + -- cgit v1.2.3