Age | Commit message (Collapse) | Author |
|
|
|
|
|
Still need to add ALPN support and to wait before trying to send
data on a proxied TLS connection that didn't complete its handshake.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This cleaner separation gets rid of the implicit body check
that was causing issues for many users. Now the body is
either given explicitly or it is expected via future
gun:data/3 calls.
|
|
An invalid stream reference (the websocket tuple wrapper)
was sent in the gun_data message.
Also moves autobahn to its own test suite.
|
|
|
|
Otherwise this can mess up the underlying protocol we will
switch to, like TLS or HTTP/2.
|
|
Also augment the CONNECT tests to confirm that the
intermediaries are accounted for.
|
|
This fixes HTTP/2 over TLS connections.
The protocol destination option has been deprecated in favor
of a protocols option.
|
|
Gun can now be used to connect through TCP HTTP/1.1 proxies
using all supported protocols. It is also possible to create
a tunnel through multiple proxies.
Also updates Cowlib to 2.6.0.
|
|
|
|
|
|
We instead of two new modules, gun_tcp and gun_tls.
They only have 6 functions so far, much less than
what Ranch provided before.
Also renames ssl to tls where applicable. It's still
possible to use the ssl transport option but it's now
undocumented.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This is a bit less efficient but necessary in case we
start getting the beginning of \r\n\r\n and it cuts just
there.
|
|
The code is definitely not the best, but as long as it doesn't
break anything it should be OK for now.
|
|
|
|
This disables the keepalive mechanism entirely.
|
|
|
|
|
|
This functionality can be used to implement custom protocols
on top of Websocket, but may also be used to decode frame
contents on the fly if necessary.
The default_protocol option defines what module should be
used when no protocol was selected.
The protocols option is a list of key/value pairs used to
select the handler depending on the protocol that the server
accepted.
The feature is currently experimental.
|
|
Content handlers are a chain of modules implementing callbacks
that receive the body of responses and may modify it (for example
for decompressing the content) or act upon it (like sending a
message to the owner process.
The gun_sse content handler module can be used to translate
text/event-stream events on the fly and deliver them to the
owner process as a {gun_sse...} message.
This feature is currently not documented and is only tested
against a public server. It requires an up to date Cowlib.
|
|
|
|
No response body is expected from now on.
|
|
Oops!
|
|
Thanks @petrohi for the initial patch.
|
|
Oops! Thanks everyone who reported/submitted patches.
|
|
When we stream content we need to set this header manually
from Gun.
|
|
|
|
Also improves the code and documentation about this message.
It was incorrectly specified that a gun_ws_upgrade message
could be sent on error; instead a gun_response is sent.
|
|
|
|
The flush(Pid) function was enhanced to also discard Websocket
messages and the new up/down messages.
|
|
map:to_list -> maps:to_list
Only call maps:to_list once.
|
|
The type option has been removed. The transport and protocols
options can be used in its place.
The transport_opts option can be used to specify transport
options.
The http_opts and spdy_opts options can be used to specify
protocol specific options.
The keepalive option is now a protocol specific option.
Defaults depending on the port number have changed. Now only
port 443 uses ssl by default, other ports use tcp.
|
|
|
|
The content-type and content-length alone indicate whether a
body is present for request/4.
The host header can now be overriden.
A number of headers like transfer-encoding are automatically
deleted from the list of headers we receive. SPDY also deletes
connection, keep-alive and proxy-connection.
SPDY now sends the port in the :host header.
|
|
|