Index: /trunk/Nebulous-Server/Changes
===================================================================
--- /trunk/Nebulous-Server/Changes	(revision 10626)
+++ /trunk/Nebulous-Server/Changes	(revision 10627)
@@ -13,4 +13,7 @@
     - change Nebulous::Server::SOAP install stub methods to bypass AUTOLOAD on
       successive calls to the same method
+    - make Nebulous::Server::Log mod_perl aware
+    - change Nebulous::Server::Log to accept a Nebulous::Server::Config object
+      as a parameter instead of fetching it as a singleton
 
 0.02 Fri Dec  2 17:36:59 HST 2005
Index: /trunk/Nebulous-Server/lib/Nebulous/Server.pm
===================================================================
--- /trunk/Nebulous-Server/lib/Nebulous/Server.pm	(revision 10626)
+++ /trunk/Nebulous-Server/lib/Nebulous/Server.pm	(revision 10627)
@@ -1,5 +1,5 @@
 # Copyright (c) 2004  Joshua Hoblitt
 #
-# $Id: Server.pm,v 1.21 2006-12-08 20:57:36 jhoblitt Exp $
+# $Id: Server.pm,v 1.22 2006-12-12 00:02:53 jhoblitt Exp $
 
 package Nebulous::Server;
@@ -29,7 +29,7 @@
 
     # log4perl is not avaliable until we call init()
-    Nebulous::Server::Log->init;
-
+    Nebulous::Server::Log->init($config);
     my $log = Log::Log4perl::get_logger( "Nebulous::Server" );
+
     my $sql = Nebulous::Server::SQL->new;
 
Index: /trunk/Nebulous-Server/lib/Nebulous/Server/Log.pm
===================================================================
--- /trunk/Nebulous-Server/lib/Nebulous/Server/Log.pm	(revision 10626)
+++ /trunk/Nebulous-Server/lib/Nebulous/Server/Log.pm	(revision 10627)
@@ -1,5 +1,5 @@
 # Copyright (c) 2004  Joshua Hoblitt
 #
-# $Id: Log.pm,v 1.5 2005-08-26 02:06:33 jhoblitt Exp $
+# $Id: Log.pm,v 1.6 2006-12-12 00:02:53 jhoblitt Exp $
 
 package Nebulous::Server::Log;
@@ -8,5 +8,5 @@
 use warnings FATAL => qw( all );
 
-our $VERSION = '0.01';
+our $VERSION = '0.02';
 
 use Log::Log4perl;
@@ -14,6 +14,5 @@
 
 sub init {
-    # test for an extern config file here
-    my $config = Nebulous::Server::Config->instance;
+    my ($self, $config) = @_;
 
     my $dsn         = $config->dsn;
@@ -50,5 +49,11 @@
 END
 
-    Log::Log4perl::init( \$conf );
+    if ($INC{'Apache/DBI.pm'} && $ENV{MOD_PERL}) {
+        Log::Log4perl::init_once( \$conf );
+    } else {
+        Log::Log4perl::init( \$conf );
+    }
+
+    return 1;
 }
 
Index: /trunk/Nebulous/Changes
===================================================================
--- /trunk/Nebulous/Changes	(revision 10626)
+++ /trunk/Nebulous/Changes	(revision 10627)
@@ -13,4 +13,7 @@
     - change Nebulous::Server::SOAP install stub methods to bypass AUTOLOAD on
       successive calls to the same method
+    - make Nebulous::Server::Log mod_perl aware
+    - change Nebulous::Server::Log to accept a Nebulous::Server::Config object
+      as a parameter instead of fetching it as a singleton
 
 0.02 Fri Dec  2 17:36:59 HST 2005
Index: /trunk/Nebulous/lib/Nebulous/Server.pm
===================================================================
--- /trunk/Nebulous/lib/Nebulous/Server.pm	(revision 10626)
+++ /trunk/Nebulous/lib/Nebulous/Server.pm	(revision 10627)
@@ -1,5 +1,5 @@
 # Copyright (c) 2004  Joshua Hoblitt
 #
-# $Id: Server.pm,v 1.21 2006-12-08 20:57:36 jhoblitt Exp $
+# $Id: Server.pm,v 1.22 2006-12-12 00:02:53 jhoblitt Exp $
 
 package Nebulous::Server;
@@ -29,7 +29,7 @@
 
     # log4perl is not avaliable until we call init()
-    Nebulous::Server::Log->init;
-
+    Nebulous::Server::Log->init($config);
     my $log = Log::Log4perl::get_logger( "Nebulous::Server" );
+
     my $sql = Nebulous::Server::SQL->new;
 
Index: /trunk/Nebulous/lib/Nebulous/Server/Log.pm
===================================================================
--- /trunk/Nebulous/lib/Nebulous/Server/Log.pm	(revision 10626)
+++ /trunk/Nebulous/lib/Nebulous/Server/Log.pm	(revision 10627)
@@ -1,5 +1,5 @@
 # Copyright (c) 2004  Joshua Hoblitt
 #
-# $Id: Log.pm,v 1.5 2005-08-26 02:06:33 jhoblitt Exp $
+# $Id: Log.pm,v 1.6 2006-12-12 00:02:53 jhoblitt Exp $
 
 package Nebulous::Server::Log;
@@ -8,5 +8,5 @@
 use warnings FATAL => qw( all );
 
-our $VERSION = '0.01';
+our $VERSION = '0.02';
 
 use Log::Log4perl;
@@ -14,6 +14,5 @@
 
 sub init {
-    # test for an extern config file here
-    my $config = Nebulous::Server::Config->instance;
+    my ($self, $config) = @_;
 
     my $dsn         = $config->dsn;
@@ -50,5 +49,11 @@
 END
 
-    Log::Log4perl::init( \$conf );
+    if ($INC{'Apache/DBI.pm'} && $ENV{MOD_PERL}) {
+        Log::Log4perl::init_once( \$conf );
+    } else {
+        Log::Log4perl::init( \$conf );
+    }
+
+    return 1;
 }
 
