% create a queue
{ok, Q} = ebqueue:start_link().
% add some elements
ebqueue:in({xxx, 123}, Q).
ebqueue:in({yyy, 456}, Q).
% read from the queue
{ok, Element} = ebqueue:out(Q).
% read from queue with timeout
case ebqueue:out(Q, 1000) of
timeout -> io:format("Timed out.");
{ok, E} -> io:format("Got element ~p", [E])
end.
-
Notifications
You must be signed in to change notification settings - Fork 0
rgrinberg/ebqueue
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
Tiny simple blocking queue in erlang
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published