ambari git commit: AMBARI-19649. Ambari purge tool broken. (Laszlo Puskas via stoader)

2017-01-20 Thread stoader
Repository: ambari
Updated Branches:
  refs/heads/trunk 83cf094b5 -> ec6ba0abb


AMBARI-19649. Ambari purge tool broken. (Laszlo Puskas via stoader)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/ec6ba0ab
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/ec6ba0ab
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/ec6ba0ab

Branch: refs/heads/trunk
Commit: ec6ba0abbf2b1ce343f370f63512d45e7add9a40
Parents: 83cf094
Author: Laszlo Puskas 
Authored: Fri Jan 20 23:18:13 2017 +0100
Committer: Toader, Sebastian 
Committed: Fri Jan 20 23:18:13 2017 +0100

--
 .../java/org/apache/ambari/server/cleanup/CleanupDriver.java | 3 ++-
 .../main/java/org/apache/ambari/server/stack/StackManager.java   | 4 ++--
 2 files changed, 4 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/ec6ba0ab/ambari-server/src/main/java/org/apache/ambari/server/cleanup/CleanupDriver.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/cleanup/CleanupDriver.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/cleanup/CleanupDriver.java
index f10250e..788290b 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/cleanup/CleanupDriver.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/cleanup/CleanupDriver.java
@@ -21,6 +21,7 @@ import java.text.DateFormat;
 import java.text.SimpleDateFormat;
 import java.util.Date;
 
+import org.apache.ambari.server.audit.AuditLoggerModule;
 import org.apache.ambari.server.controller.ControllerModule;
 import org.apache.commons.cli.CommandLine;
 import org.apache.commons.cli.CommandLineParser;
@@ -79,7 +80,7 @@ public class CleanupDriver {
 CleanupContext cleanupContext = processArguments(args);
 
 // set up the guice context
-Injector injector = Guice.createInjector(new ControllerModule(), new 
CleanupModule());
+Injector injector = Guice.createInjector(new ControllerModule(), new 
AuditLoggerModule(), new CleanupModule());
 
 // explicitly starting the persist service
 injector.getInstance(AmbariJpaPersistService.class).start();

http://git-wip-us.apache.org/repos/asf/ambari/blob/ec6ba0ab/ambari-server/src/main/java/org/apache/ambari/server/stack/StackManager.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/stack/StackManager.java 
b/ambari-server/src/main/java/org/apache/ambari/server/stack/StackManager.java
index 28d9e5d..d9a3ac4 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/stack/StackManager.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/stack/StackManager.java
@@ -53,8 +53,8 @@ import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.xml.sax.SAXException;
 
-import com.google.inject.Inject;
 import com.google.inject.assistedinject.Assisted;
+import com.google.inject.assistedinject.AssistedInject;
 
 
 /**
@@ -134,7 +134,7 @@ public class StackManager {
* @throws AmbariException
*   if an exception occurs while processing the stacks
*/
-  @Inject
+  @AssistedInject
   public StackManager(@Assisted("stackRoot") File stackRoot,
   @Assisted("commonServicesRoot") @Nullable File commonServicesRoot,
   @Assisted("extensionRoot") @Nullable File extensionRoot,



ambari git commit: AMBARI-19649. Ambari purge tool broken. (Laszlo Puskas via stoader)

2017-01-20 Thread stoader
Repository: ambari
Updated Branches:
  refs/heads/branch-2.5 e1e496cde -> 8111ba662


AMBARI-19649. Ambari purge tool broken. (Laszlo Puskas via stoader)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/8111ba66
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/8111ba66
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/8111ba66

Branch: refs/heads/branch-2.5
Commit: 8111ba662e849c27e4a9a04305b3ef2260c030e9
Parents: e1e496c
Author: Laszlo Puskas 
Authored: Fri Jan 20 19:18:10 2017 +0100
Committer: Toader, Sebastian 
Committed: Fri Jan 20 22:11:59 2017 +0100

--
 .../java/org/apache/ambari/server/cleanup/CleanupDriver.java   | 3 ++-
 .../main/java/org/apache/ambari/server/stack/StackManager.java | 6 +++---
 2 files changed, 5 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/8111ba66/ambari-server/src/main/java/org/apache/ambari/server/cleanup/CleanupDriver.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/cleanup/CleanupDriver.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/cleanup/CleanupDriver.java
index f10250e..788290b 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/cleanup/CleanupDriver.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/cleanup/CleanupDriver.java
@@ -21,6 +21,7 @@ import java.text.DateFormat;
 import java.text.SimpleDateFormat;
 import java.util.Date;
 
+import org.apache.ambari.server.audit.AuditLoggerModule;
 import org.apache.ambari.server.controller.ControllerModule;
 import org.apache.commons.cli.CommandLine;
 import org.apache.commons.cli.CommandLineParser;
@@ -79,7 +80,7 @@ public class CleanupDriver {
 CleanupContext cleanupContext = processArguments(args);
 
 // set up the guice context
-Injector injector = Guice.createInjector(new ControllerModule(), new 
CleanupModule());
+Injector injector = Guice.createInjector(new ControllerModule(), new 
AuditLoggerModule(), new CleanupModule());
 
 // explicitly starting the persist service
 injector.getInstance(AmbariJpaPersistService.class).start();

http://git-wip-us.apache.org/repos/asf/ambari/blob/8111ba66/ambari-server/src/main/java/org/apache/ambari/server/stack/StackManager.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/stack/StackManager.java 
b/ambari-server/src/main/java/org/apache/ambari/server/stack/StackManager.java
index 0e2e0d8..d9a3ac4 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/stack/StackManager.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/stack/StackManager.java
@@ -51,10 +51,10 @@ import 
org.apache.ambari.server.state.stack.ServiceMetainfoXml;
 import org.apache.commons.io.FileUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
+import org.xml.sax.SAXException;
 
-import com.google.inject.Inject;
 import com.google.inject.assistedinject.Assisted;
-import org.xml.sax.SAXException;
+import com.google.inject.assistedinject.AssistedInject;
 
 
 /**
@@ -134,7 +134,7 @@ public class StackManager {
* @throws AmbariException
*   if an exception occurs while processing the stacks
*/
-  @Inject
+  @AssistedInject
   public StackManager(@Assisted("stackRoot") File stackRoot,
   @Assisted("commonServicesRoot") @Nullable File commonServicesRoot,
   @Assisted("extensionRoot") @Nullable File extensionRoot,