From b0501c33473771ba8c2f7404f6129aa65a8f203c Mon Sep 17 00:00:00 2001 From: Luca Milanesio Date: Sat, 29 Nov 2014 16:18:19 +0000 Subject: Allows starting an already instantiated manager When a manager is injected through other means, (e.g. using a different GuiceModule and injector in Gerrit) we need a way to start it without having to necessarily passing through the injection process again. --- src/main/java/com/gitblit/servlet/GitblitContext.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/main/java/com/gitblit/servlet/GitblitContext.java b/src/main/java/com/gitblit/servlet/GitblitContext.java index fa0534db..85b47205 100644 --- a/src/main/java/com/gitblit/servlet/GitblitContext.java +++ b/src/main/java/com/gitblit/servlet/GitblitContext.java @@ -266,6 +266,12 @@ public class GitblitContext extends GuiceServletContextListener { return x; } + protected X startManager(X x) { + x.start(); + managers.add(x); + return x; + } + protected void logManager(Class clazz) { logger.info(""); logger.info("----[{}]----", clazz.getName()); -- cgit v1.2.3