Skip to content

Commit

Permalink
build: add zone_to_erlang/2 allowing for custom timeout (#171)
Browse files Browse the repository at this point in the history
  • Loading branch information
DXTimer authored Dec 18, 2024
1 parent 9f524ae commit e5d6202
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/erldns_zone_parser.erl
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
-export([
start_link/0,
zone_to_erlang/1,
zone_to_erlang/2,
register_parsers/1,
register_parser/1,
list_parsers/0
Expand Down Expand Up @@ -63,6 +64,10 @@ start_link() ->
zone_to_erlang(Zone) ->
gen_server:call(?SERVER, {parse_zone, Zone}, ?PARSE_TIMEOUT).

-spec zone_to_erlang(binary(), integer()) -> {binary(), binary(), [dns:rr()], [erldns:keyset()]}.
zone_to_erlang(Zone, Timeout) ->
gen_server:call(?SERVER, {parse_zone, Zone}, Timeout).

%% @doc Register a list of custom parser modules.
-spec register_parsers([module()]) -> ok.
register_parsers(Modules) ->
Expand Down

0 comments on commit e5d6202

Please sign in to comment.