ostinelli / misultin

Misultin (pronounced mee-sool-téen) is an Erlang library for building fast lightweight HTTP(S) servers, which also supports websockets.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Logger

djui opened this issue · comments

It would be nice to have an optional logger that could write response data to handle request. I believe this should be done inside the misultin_http:call_mfa/2 to handle user code crashes and still be able to log data. The format should be using a standard Apache accept log style.

Currently my implementation is similar to webmachine's logger but has to live inside my request loop because I don't want to patch misultin. Or are there other suitable solutions?

hi,

have you looked at this example in the DEV branch?
https://github.com/ostinelli/misultin/blob/dev/examples/misultin_access_log.erl

can this be what you need?

r.

Bummer, sorry, I somehow didn't see that example neither the access_log key for the request handler. Thanks!