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 BCA49200B25 for ; Wed, 8 Jun 2016 13:03:22 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id BB216160A2E; Wed, 8 Jun 2016 11:03:22 +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 DE025160A29 for ; Wed, 8 Jun 2016 13:03:21 +0200 (CEST) Received: (qmail 6630 invoked by uid 500); 8 Jun 2016 11:03:21 -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 6619 invoked by uid 99); 8 Jun 2016 11:03:21 -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; Wed, 08 Jun 2016 11:03:21 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id E727CDFC7E; Wed, 8 Jun 2016 11:03:20 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: oleewere@apache.org To: commits@ambari.apache.org Message-Id: <1e7f6397139e470b88ca1914e65e2541@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: ambari git commit: AMBARI-17086. Log Search capability for Nifi (Miklos Gergely via oleewere) Date: Wed, 8 Jun 2016 11:03:20 +0000 (UTC) archived-at: Wed, 08 Jun 2016 11:03:22 -0000 Repository: ambari Updated Branches: refs/heads/trunk 71cbc0254 -> de4499546 AMBARI-17086. Log Search capability for Nifi (Miklos Gergely via oleewere) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/de449954 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/de449954 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/de449954 Branch: refs/heads/trunk Commit: de44995464af2901f214e74e730341b0c1aa61ac Parents: 71cbc02 Author: oleewere Authored: Wed Jun 8 12:49:05 2016 +0200 Committer: oleewere Committed: Wed Jun 8 12:58:15 2016 +0200 ---------------------------------------------------------------------- .../LOGSEARCH/0.5.0/package/scripts/params.py | 4 +- .../package/templates/input.config-nifi.json.j2 | 98 ++++++++++++++++++++ 2 files changed, 101 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ambari/blob/de449954/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/package/scripts/params.py ---------------------------------------------------------------------- diff --git a/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/package/scripts/params.py b/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/package/scripts/params.py index 34583ba..7acdec2 100644 --- a/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/package/scripts/params.py +++ b/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/package/scripts/params.py @@ -230,6 +230,8 @@ hbase_log_dir = default('/configurations/hbase-env/hbase_log_dir', '/var/log/hba hdfs_log_dir_prefix = default('/configurations/hadoop-env/hdfs_log_dir_prefix', '/var/log/hadoop') hive_log_dir = default('/configurations/hive-env/hive_log_dir', '/var/log/hive') kafka_log_dir = default('/configurations/kafka-env/kafka_log_dir', '/var/log/kafka') +nifi_master_log_dir = default('/configurations/nifi-bootstrap-env/nifi_master_log_dir', '/var/log/nifi_master') +nifi_node_log_dir = default('/configurations/nifi-bootstrap-env/nifi_nod_log_dir', '/var/log/nifi_node') oozie_log_dir = default('/configurations/oozie-env/oozie_log_dir', '/var/log/oozie') ranger_usersync_log_dir = default('/configurations/ranger-env/ranger_usersync_log_dir', '/var/log/ranger/usersync') ranger_admin_log_dir = default('/configurations/ranger-env/ranger_admin_log_dir', '/var/log/ranger/admin') @@ -308,7 +310,7 @@ logfeeder_log_filter_enable = str(default('/configurations/logfeeder-properties/ logfeeder_solr_config_interval = default('/configurations/logfeeder-properties/logfeeder.solr.config.interval', 5) logfeeder_supported_services = ['accumulo', 'ambari', 'ams', 'atlas', 'falcon', 'hbase', 'hdfs', 'hive', 'kafka', - 'knox', 'logsearch', 'oozie', 'ranger', 'storm', 'yarn', 'zookeeper'] + 'knox', 'logsearch', 'nifi', 'oozie', 'ranger', 'storm', 'yarn', 'zookeeper'] logfeeder_config_file_names = ['global.config.json', 'output.config.json'] + ['input.config-%s.json' % (tag) for tag in logfeeder_supported_services] http://git-wip-us.apache.org/repos/asf/ambari/blob/de449954/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/package/templates/input.config-nifi.json.j2 ---------------------------------------------------------------------- diff --git a/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/package/templates/input.config-nifi.json.j2 b/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/package/templates/input.config-nifi.json.j2 new file mode 100644 index 0000000..1bbab20 --- /dev/null +++ b/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/package/templates/input.config-nifi.json.j2 @@ -0,0 +1,98 @@ +{# + # Licensed to the Apache Software Foundation (ASF) under one + # or more contributor license agreements. See the NOTICE file + # distributed with this work for additional information + # regarding copyright ownership. The ASF licenses this file + # to you under the Apache License, Version 2.0 (the + # "License"); you may not use this file except in compliance + # with the License. You may obtain a copy of the License at + # + # http://www.apache.org/licenses/LICENSE-2.0 + # + # Unless required by applicable law or agreed to in writing, software + # distributed under the License is distributed on an "AS IS" BASIS, + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. + #} +{ + "input":[ + { + "type":"nifi_app_master", + "rowtype":"service", + "path":"{{nifi_master_log_dir}}/nifi-app.log" + }, + { + "type":"nifi_bootstrap_master", + "rowtype":"service", + "path":"{{nifi_master_log_dir}}/nifi-bootstrap.log" + }, + { + "type":"nifi_setup_master", + "rowtype":"service", + "path":"{{nifi_master_log_dir}}/nifi-setup.log" + }, + { + "type":"nifi_user_master", + "rowtype":"service", + "path":"{{nifi_master_log_dir}}/nifi-user.log" + }, + { + "type":"nifi_app_node", + "rowtype":"service", + "path":"{{nifi_node_log_dir}}/nifi-app.log" + }, + { + "type":"nifi_bootstrap_node", + "rowtype":"service", + "path":"{{nifi_node_log_dir}}/nifi-bootstrap.log" + }, + { + "type":"nifi_setup_node", + "rowtype":"service", + "path":"{{nifi_node_log_dir}}/nifi-setup.log" + }, + { + "type":"nifi_user_node", + "rowtype":"service", + "path":"{{nifi_node_log_dir}}/nifi-user.log" + } + + ], + "filter":[ + { + "filter":"grok", + "conditions":{ + "fields":{ + "type":[ + "nifi_app_master", + "nifi_bootstrap_master", + "nifi_setup_master", + "nifi_user_master", + "nifi_app_node", + "nifi_bootstrap_node", + "nifi_setup_node", + "nifi_user_node" + ] + + } + + }, + "log4j_format":"", + "multiline_pattern":"^(%{TIMESTAMP_ISO8601:logtime})", + "message_pattern":"(?m)^%{TIMESTAMP_ISO8601:logtime}%{SPACE}%{LOGLEVEL:level}%{SPACE}\\[%{DATA:thread_name}\\]%{SPACE}%{GREEDYDATA:log_message}", + "post_map_values":{ + "logtime":{ + "map_date":{ + "date_pattern":"yyyy-MM-dd HH:mm:ss,SSS" + } + + } + + } + + } + + ] + +}