Bump version to 0.8.2; add compatibility Ranch 1.8/2.0

This commit is contained in:
Sergey Prokhorov 2026-04-05 13:54:59 +02:00
parent fc9ec1d326
commit f24b70db80
No known key found for this signature in database
GPG key ID: 1C570244E4EF3337
2 changed files with 6 additions and 2 deletions

View file

@ -10,7 +10,7 @@
-behaviour(ranch_protocol).
%% API
-export([start_link/3, send/2]).
-export([start_link/3, start_link/4, send/2]).
-export([hex/1, unhex/1]).
-export([keys_str/0]).
@ -68,6 +68,10 @@
start_link(Ref, Transport, Opts) ->
{ok, proc_lib:spawn_link(?MODULE, ranch_init, [{Ref, Transport, Opts}])}.
%% Ranch 1.x compatibility shim (socket is obtained via ranch:handshake/1 in 2.x)
start_link(Ref, _Socket, Transport, Opts) ->
start_link(Ref, Transport, Opts).
keys_str() ->
[{Name, Port, hex(Secret)}
|| {Name, Port, Secret} <- application:get_env(?APP, ports, [])].

View file

@ -1,6 +1,6 @@
{application, mtproto_proxy,
[{description, "High-performance Telegram MTProto proxy server"},
{vsn, "0.8.1"},
{vsn, "0.8.2"},
{registered, []},
{mod, { mtproto_proxy_app, []}},
{applications,