From 84adefa331c4159d432d22840663c38f155cd4c1 Mon Sep 17 00:00:00 2001 From: Erlang/OTP Date: Fri, 20 Nov 2009 14:54:40 +0000 Subject: The R13B03 release. --- lib/stdlib/doc/src/log_mf_h.xml | 79 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) create mode 100644 lib/stdlib/doc/src/log_mf_h.xml (limited to 'lib/stdlib/doc/src/log_mf_h.xml') diff --git a/lib/stdlib/doc/src/log_mf_h.xml b/lib/stdlib/doc/src/log_mf_h.xml new file mode 100644 index 0000000000..198a55a63b --- /dev/null +++ b/lib/stdlib/doc/src/log_mf_h.xml @@ -0,0 +1,79 @@ + + + + +
+ + 1996 + 2007 + Ericsson AB, All Rights Reserved + + + The contents of this file are subject to the Erlang Public License, + Version 1.1, (the "License"); you may not use this file except in + compliance with the License. You should have received a copy of the + Erlang Public License along with this software. If not, it can be + retrieved online at http://www.erlang.org/. + + Software distributed under the License is distributed on an "AS IS" + basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See + the License for the specific language governing rights and limitations + under the License. + + The Initial Developer of the Original Code is Ericsson AB. + + + log_mf_h + Martin Björklund + Bjarne Dacker + + Bjarne Däcker + Martin Björklund + 1996-10-31 + A + log_mf_h.sgml +
+ log_mf_h + An Event Handler which Logs Events to Disk + +

The log_mf_h is a gen_event handler module which + can be installed in any gen_event process. It logs onto disk all events + which are sent to an event manager. Each event is written as a + binary which makes the logging very fast. However, a tool such as the Report Browser (rb) must be used in order to read the files. The events are written to multiple files. When all files have been used, the first one is re-used and overwritten. The directory location, the number of files, and the size of each file are configurable. The directory will include one file called index, and + report files 1, 2, ..... +

+
+ + + init(Dir, MaxBytes, MaxFiles) + init(Dir, MaxBytes, MaxFiles, Pred) -> Args + Initiate the event handler + + Dir = string() + MaxBytes = integer() + MaxFiles = 0 < integer() < 256 + Pred = fun(Event) -> boolean() + Event = term() + Args = args() + + +

Initiates the event handler. This function returns + Args, which should be used in a call to + gen_event:add_handler(EventMgr, log_mf_h, Args). +

+

Dir specifies which directory to use for the log + files. MaxBytes specifies the size of each individual + file. MaxFiles specifies how many files are + used. Pred is a predicate function used to filter the + events. If no predicate function is specified, all events are + logged.

+
+
+
+ +
+ See Also +

gen_event(3), rb(3)

+
+
+ -- cgit v1.2.3