khia / exlager

Elixir binding for lager
Apache License 2.0
66 stars 36 forks source link

Does not seem to be able to configure lager #13

Closed drouchy closed 10 years ago

drouchy commented 10 years ago

Hi,

I'm trying to use exlager. Everthing looks ok, until I try to configure lager.

here in my mix file

def project do
   [ app: ..., elixirc_options: options(Mix.env)]
end

def options(:test) do
  [exlager_level: :emergency]
end

but when I run the tests:

11:18:56.893 [info] Application lager started on node nonode@nohost
11:18:56.893 [info] Application exlager started on node nonode@nohost
11:18:56.893 [info] Application re_inspector_backend started on node nonode@nohost
11:18:56.914 [info] Application ex_unit started on node nonode@nohost

I'm using Elizir 0.12.4 & exlager SHA1 779a75350c6bf6a30b779f6d63e2d50a94c4d9a1

David

khia commented 10 years ago

Exlager doesn't try to configure lager. It just eliminates calls to lagger in compile time for levels greater than exlager_level. The messages you see are from system. Exlager only affects modules where you explicitly use it. If you want to change log level system wide you need to configure lagger (see https://github.com/basho/lager/).