瀏覽代碼

Document the lager_truncation_size compile-time option

pull/74/merge
Andrew Thompson 12 年之前
父節點
當前提交
bcbd8ff939
共有 1 個檔案被更改,包括 15 行新增0 行删除
  1. +15
    -0
      README.org

+ 15
- 0
README.org 查看文件

@ -236,3 +236,18 @@
#+BEGIN_EXAMPLE
lager:trace_console([{pid, "<0.410.0>"}])
#+END_EXAMPLE
* Setting the truncation limit at compile-time
Lager defaults to truncating messages at 4096 bytes, you can alter this by
using the {lager_truncation_size, X} option. In rebar, you can add it to
erl_opts:
#+BEGIN_EXAMPLE
{erl_opts, [{parse_transform, lager_transform}, {lager_truncation_size, 1024}]}.
#+END_EXAMPLE
You can also pass it to erlc, if you prefer:
#+BEGIN_EXAMPLE
erlc -pa lager/ebin +'{parse_transform, lager_transform}' +'{lager_truncation_size, 64}' file.erl
l+END_EXAMPLE

Loading…
取消
儲存