@ -29,7 +29,8 @@ var pidFilePath = __dirname + '/pidfile',
css : {
css : {
cache : undefined ,
cache : undefined ,
acpCache : undefined
acpCache : undefined
}
} ,
templatesCompiled : false
} ;
} ;
Loader . init = function ( callback ) {
Loader . init = function ( callback ) {
@ -112,6 +113,12 @@ Loader.addWorkerEvents = function(worker) {
} ) ;
} ) ;
}
}
if ( Loader . templatesCompiled && ! worker . isPrimary ) {
worker . send ( {
action : 'templates:compiled'
} ) ;
}
break ;
break ;
case 'restart' :
case 'restart' :
@ -141,6 +148,8 @@ Loader.addWorkerEvents = function(worker) {
} , worker . pid ) ;
} , worker . pid ) ;
break ;
break ;
case 'templates:compiled' :
case 'templates:compiled' :
Loader . templatesCompiled = true ;
Loader . notifyWorkers ( {
Loader . notifyWorkers ( {
action : 'templates:compiled' ,
action : 'templates:compiled' ,
} , worker . pid ) ;
} , worker . pid ) ;