You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by sw...@apache.org on 2014/01/07 22:18:08 UTC

git commit: AMBARI-4150. Provide ability to batch requests based on schedule. Unit test fix. (swagle)

Updated Branches:
  refs/heads/trunk 12609b27d -> d507500e4


AMBARI-4150. Provide ability to batch requests based on schedule. Unit test fix. (swagle)


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

Branch: refs/heads/trunk
Commit: d507500e4354dcea7a271f7b30b5ab8285d453b1
Parents: 12609b2
Author: Siddharth Wagle <sw...@hortonworks.com>
Authored: Tue Jan 7 13:18:03 2014 -0800
Committer: Siddharth Wagle <sw...@hortonworks.com>
Committed: Tue Jan 7 13:18:03 2014 -0800

----------------------------------------------------------------------
 .../src/main/java/org/apache/ambari/server/utils/DateUtils.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/d507500e/ambari-server/src/main/java/org/apache/ambari/server/utils/DateUtils.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/utils/DateUtils.java b/ambari-server/src/main/java/org/apache/ambari/server/utils/DateUtils.java
index add74f9..3444988 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/utils/DateUtils.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/utils/DateUtils.java
@@ -81,7 +81,7 @@ public class DateUtils {
    * @return
    */
   public static Long getDateDifferenceInMinutes(Date oldTime) {
-    long diff = oldTime.getTime() - new Date().getTime();
+    long diff = Math.abs(oldTime.getTime() - new Date().getTime());
     return diff / (60 * 1000) % 60;
   }
 }