Packages

An Elixir implementation of the Kafka protocol. It enables communication with Kafka brokers using standard Elixir data structures without the need for manual serialization.

Current section

Files

Jump to
klife_protocol lib klife_protocol.ex
Raw

lib/klife_protocol.ex

defmodule KlifeProtocol do
@moduledoc """
Use the `KlifeProtocol.Messages` modules to serialze and deserialize messages.
"""
def perf_test() do
bin = File.read!("test/files/large_fetch_resp")
t0 = System.monotonic_time(:millisecond)
{:ok, _resp} = KlifeProtocol.Messages.Fetch.deserialize_response(bin, 4)
tf = System.monotonic_time(:millisecond)
tf - t0
end
end