logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

Log::Agent::Driver::Fork - dummy driver for forking output to multiple drivers

Author

       Mark Rogaski <mrogaski@pobox.com>

Description

       This driver merely acts a multiplexer for logxxx() calls, duplicating them and distributing them to other
       drivers.

       The only routine of interest here is the creation routine:

       make(@drivers)
           Create  a  Log::Agent::Driver::Fork driver that duplicates logxxx() calls and distributes them to the
           drivers in @drivers.  The arguments must be the return value  of  the  make()  call  for  the  client
           drivers.

License

       Copyright (C) 2002 Mark Rogaski; all rights reserved.

       See Log::Agent(3) or the README file included with the distribution for license information.

Name

       Log::Agent::Driver::Fork - dummy driver for forking output to multiple drivers

Notes

       Many  thanks  go  to  Daniel  Lundin  and  Jason May who proposed this module independently.  Eventually,
       logconfig() will support multiple drivers directly. But, for now, this solution requires no change to the
       existing interface.

See Also

Log::Agent::Driver(3), Log::Agent(3).

perl v5.36.0                                       2022-10-15                           Agent::Driver::Fork(3pm)

Synopsis

        use Log::Agent;
        require Log::Agent::Driver::Fork;
        require Log::Agent::Driver::Foo;
        require Log::Agent::Driver::Bar;

        my $driver = Log::Agent::Driver::Fork->make(
            Log::Agent::Driver::Foo->make( ... ),
            Log::Agent::Driver::Bar->make( ... )
        );
        logconfig(-driver => $driver);

See Also