Return-Path: X-Original-To: apmail-ambari-commits-archive@www.apache.org Delivered-To: apmail-ambari-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7ED6318AC6 for ; Sat, 19 Sep 2015 12:52:38 +0000 (UTC) Received: (qmail 48175 invoked by uid 500); 19 Sep 2015 12:52:38 -0000 Delivered-To: apmail-ambari-commits-archive@ambari.apache.org Received: (qmail 48146 invoked by uid 500); 19 Sep 2015 12:52:38 -0000 Mailing-List: contact commits-help@ambari.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: ambari-dev@ambari.apache.org Delivered-To: mailing list commits@ambari.apache.org Received: (qmail 48137 invoked by uid 99); 19 Sep 2015 12:52:38 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 19 Sep 2015 12:52:38 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 46E94DFF32; Sat, 19 Sep 2015 12:52:38 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: vbrodetskyi@apache.org To: commits@ambari.apache.org Message-Id: <61616441fc1f40c992a4a5b97e4f3888@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: ambari git commit: AMBARI-13159. On older jdk versions getting compile error Object cast to boolen error.(vbrodetskyi) Date: Sat, 19 Sep 2015 12:52:38 +0000 (UTC) Repository: ambari Updated Branches: refs/heads/trunk 131c8cd51 -> fa4240e71 AMBARI-13159. On older jdk versions getting compile error Object cast to boolen error.(vbrodetskyi) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/fa4240e7 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/fa4240e7 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/fa4240e7 Branch: refs/heads/trunk Commit: fa4240e71e3bd7ff740179f04e894218a1249e3d Parents: 131c8cd Author: Vitaly Brodetskyi Authored: Sat Sep 19 15:52:27 2015 +0300 Committer: Vitaly Brodetskyi Committed: Sat Sep 19 15:52:27 2015 +0300 ---------------------------------------------------------------------- .../src/main/java/org/apache/ambari/server/orm/dao/AlertsDAO.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ambari/blob/fa4240e7/ambari-server/src/main/java/org/apache/ambari/server/orm/dao/AlertsDAO.java ---------------------------------------------------------------------- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/orm/dao/AlertsDAO.java b/ambari-server/src/main/java/org/apache/ambari/server/orm/dao/AlertsDAO.java index 4a5c5b0..39b12c4 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/orm/dao/AlertsDAO.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/orm/dao/AlertsDAO.java @@ -521,7 +521,7 @@ public class AlertsDAO { int integerValue; if (hostStateValue instanceof Boolean) { - integerValue = (boolean)hostStateValue ? 1 : 0; + integerValue = ((Boolean)hostStateValue).booleanValue() ? 1 : 0; } else { integerValue = ((Number)hostStateValue).intValue(); }