[CalendarServer-changes] [6081] CalendarServer/trunk/calendarserver/tap/caldav.py
source_changes at macosforge.org
source_changes at macosforge.org
Mon Aug 16 09:09:16 PDT 2010
Revision: 6081
http://trac.macosforge.org/projects/calendarserver/changeset/6081
Author: cdaboo at apple.com
Date: 2010-08-16 09:09:16 -0700 (Mon, 16 Aug 2010)
Log Message:
-----------
Single process mode needs to start the postgres sub-process if postgres is being used.
Modified Paths:
--------------
CalendarServer/trunk/calendarserver/tap/caldav.py
Modified: CalendarServer/trunk/calendarserver/tap/caldav.py
===================================================================
--- CalendarServer/trunk/calendarserver/tap/caldav.py 2010-08-13 23:30:51 UTC (rev 6080)
+++ CalendarServer/trunk/calendarserver/tap/caldav.py 2010-08-16 16:09:16 UTC (rev 6081)
@@ -671,8 +671,33 @@
return service
- makeService_Single = makeService_Slave
+ def makeService_Single(self, options):
+ #
+ # Change default log level to "info" as its useful to have
+ # that during startup
+ #
+ service = self.makeService_Slave(options)
+ if config.UseDatabase:
+ # Postgres
+
+ dbRoot = CachingFilePath(config.DatabaseRoot)
+
+ monitor = DelayedStartupProcessMonitor()
+ service.processMonitor = monitor
+
+ def subServiceFactory(connectionFactory):
+ return monitor
+
+ postgresUID = None
+ postgresGID = None
+
+ PostgresService(dbRoot, subServiceFactory, v1_schema,
+ "caldav", logFile=config.PostgresLogFile,
+ uid=postgresUID, gid=postgresGID).setServiceParent(service)
+
+ return service
+
def makeService_Combined(self, options):
s = ErrorLoggingMultiService()
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20100816/c5b4f089/attachment.html>
More information about the calendarserver-changes
mailing list