Module mod_logging

Simple database logging.

Copyright © 2010 Arjan Scherpenisse

Behaviours: gen_server.

Authors: Arjan Scherpenisse (arjan@scherpenisse.net).

Description

Simple database logging.

Function Index

code_change/3Convert process state when code is changed.
handle_call/3Handling call messages.
handle_cast/2
handle_info/2Handling all non call/cast messages.
init/1Initiates the server.
is_ui_ratelimit_check/1Return true if ok to insert an UI log entry (max 1 per second).
manage_schema/2
observe_admin_menu/3
observe_search_query/2
observe_tick_1h/2
observe_tick_1m/2
pid_observe_zlog/3
start_link/1Starts the server.
terminate/2This function is called by a gen_server when it is about to terminate.

Function Details

code_change/3

code_change(OldVsn, State, Extra) -> {ok, NewState}

Convert process state when code is changed

handle_call/3

handle_call(Message::Request, From, State) -> {reply, Reply, State} | {reply, Reply, State, Timeout} | {noreply, State} | {noreply, State, Timeout} | {stop, Reason, Reply, State} | {stop, Reason, State}

Handling call messages

handle_cast/2

handle_cast(Message, State) -> any()

handle_info/2

handle_info(Info, State) -> {noreply, State} | {noreply, State, Timeout} | {stop, Reason, State}

Handling all non call/cast messages

init/1

init(Args) -> {ok, State} | {ok, State, Timeout} | ignore | {stop, Reason}

Initiates the server.

is_ui_ratelimit_check/1

is_ui_ratelimit_check(Context) -> any()

Return true if ok to insert an UI log entry (max 1 per second)

manage_schema/2

manage_schema(X1, Context) -> any()

observe_admin_menu/3

observe_admin_menu(Admin_menu, Acc, Context) -> any()

observe_search_query/2

observe_search_query(Query, Context) -> any()

observe_tick_1h/2

observe_tick_1h(X1, Context) -> any()

observe_tick_1m/2

observe_tick_1m(X1, Context) -> any()

pid_observe_zlog/3

pid_observe_zlog(Pid, Zlog, Context) -> any()

start_link/1

start_link(Args) -> {ok, Pid} | ignore | {error, Error}

Starts the server

terminate/2

terminate(Reason, State) -> void()

This function is called by a gen_server when it is about to terminate. It should be the opposite of Module:init/1 and do any necessary cleaning up. When it returns, the gen_server terminates with Reason. The return value is ignored.


Generated by EDoc