Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id CAD86200C7D for ; Tue, 2 May 2017 08:02:10 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id C9876160BC2; Tue, 2 May 2017 06:02:10 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 41841160BC1 for ; Tue, 2 May 2017 08:02:10 +0200 (CEST) Received: (qmail 89414 invoked by uid 500); 2 May 2017 06:02:09 -0000 Mailing-List: contact issues-help@eagle.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@eagle.apache.org Delivered-To: mailing list issues@eagle.apache.org Received: (qmail 89405 invoked by uid 99); 2 May 2017 06:02:09 -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; Tue, 02 May 2017 06:02:09 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 4FCAADFB91; Tue, 2 May 2017 06:02:09 +0000 (UTC) From: jhsenjaliya To: issues@eagle.apache.org Reply-To: issues@eagle.apache.org References: In-Reply-To: Subject: [GitHub] eagle pull request #925: [EAGLE-1012] Some language level problems in `eagle... Content-Type: text/plain Message-Id: <20170502060209.4FCAADFB91@git1-us-west.apache.org> Date: Tue, 2 May 2017 06:02:09 +0000 (UTC) archived-at: Tue, 02 May 2017 06:02:11 -0000 Github user jhsenjaliya commented on a diff in the pull request: https://github.com/apache/eagle/pull/925#discussion_r114253102 --- Diff: eagle-core/eagle-alert-parent/eagle-alert/alert-engine/src/main/java/org/apache/eagle/alert/engine/publisher/impl/AlertEagleStorePlugin.java --- @@ -62,10 +60,9 @@ public void onAlert(AlertStreamEvent event) throws Exception { if (eventList == null || eventList.isEmpty()) { return; } - List alertEvents = new ArrayList<>(); - for (AlertStreamEvent e : eventList) { - alertEvents.add(AlertPublishEvent.createAlertPublishEvent(e)); - } + List alertEvents = eventList.stream().map( --- End diff -- i feel its fancy to use newer java features, but old syntax is more readable, may be its just a coding preference --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastructure@apache.org or file a JIRA ticket with INFRA. ---