You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by wu...@apache.org on 2022/12/03 13:54:31 UTC

[ambari-metrics] branch master updated: AMBARI-25782: Fix syntax, refactor and versions after forwarding from Ambari to ambari-metrics (#75)

This is an automated email from the ASF dual-hosted git repository.

wuzhiguo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ambari-metrics.git


The following commit(s) were added to refs/heads/master by this push:
     new 9078a5f  AMBARI-25782: Fix syntax, refactor and versions after forwarding from Ambari to ambari-metrics (#75)
9078a5f is described below

commit 9078a5fc9e65578840b1062d56d49a5e3f8f63dc
Author: lucasbak <lu...@gmail.com>
AuthorDate: Sat Dec 3 14:54:26 2022 +0100

    AMBARI-25782: Fix syntax, refactor and versions after forwarding from Ambari to ambari-metrics (#75)
---
 .github/pull_request_template.md                          | 15 +++++++++++++++
 README.md                                                 | 15 +++++++++++++++
 ambari-metrics-assembly/pom.xml                           |  2 +-
 ambari-metrics-host-monitoring/pom.xml                    |  4 +++-
 .../metrics2/sink/kafka/KafkaTimelineMetricsReporter.java |  6 +-----
 ambari-metrics-storm-sink/pom.xml                         |  7 ++++++-
 ambari-metrics-timelineservice/pom.xml                    |  5 +++--
 .../upgrade/core/AbstractPhoenixMetricsCopier.java        |  2 +-
 .../upgrade/core/PhoenixClusterMetricsCopier.java         |  2 +-
 pom.xml                                                   | 12 ++++++------
 10 files changed, 52 insertions(+), 18 deletions(-)

diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md
index fa46064..2a3a348 100644
--- a/.github/pull_request_template.md
+++ b/.github/pull_request_template.md
@@ -1,3 +1,18 @@
+<!---
+   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.
+--->
+
 ## What changes were proposed in this pull request?
 
 (Please fill in changes proposed in this fix)
diff --git a/README.md b/README.md
index 67d9146..cefc206 100644
--- a/README.md
+++ b/README.md
@@ -1,3 +1,18 @@
+<!---
+   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.
+--->
+
 # Apache Ambari Metrics
 Apache Ambari subproject
 
diff --git a/ambari-metrics-assembly/pom.xml b/ambari-metrics-assembly/pom.xml
index 31eec12..d91741a 100644
--- a/ambari-metrics-assembly/pom.xml
+++ b/ambari-metrics-assembly/pom.xml
@@ -195,7 +195,7 @@
           <plugin>
             <groupId>org.codehaus.mojo</groupId>
             <artifactId>rpm-maven-plugin</artifactId>
-            <version>2.0.1</version>
+            <version>2.1.4</version>
             <configuration>
               <group>Development</group>
               <needarch>x86_64</needarch>
diff --git a/ambari-metrics-host-monitoring/pom.xml b/ambari-metrics-host-monitoring/pom.xml
index 69677b2..886b6fa 100644
--- a/ambari-metrics-host-monitoring/pom.xml
+++ b/ambari-metrics-host-monitoring/pom.xml
@@ -191,7 +191,9 @@
                     <exec dir="${basedir}/src/main/python/psutil" executable="${executable.python}" failonerror="true">
                       <arg value="setup.py" />
                       <arg value="build" />
-                      <arg value="--build-platlib" />
+                      <arg value="--build-temp" />
+                      <arg value="${basedir}\target\psutil_build_temp" />
+                      <arg value="--build-base" />
                       <arg value="${basedir}/target/psutil_build" />
                     </exec>
                   </target>
diff --git a/ambari-metrics-kafka-sink/src/main/java/org/apache/hadoop/metrics2/sink/kafka/KafkaTimelineMetricsReporter.java b/ambari-metrics-kafka-sink/src/main/java/org/apache/hadoop/metrics2/sink/kafka/KafkaTimelineMetricsReporter.java
index 52f1c70..14ce666 100644
--- a/ambari-metrics-kafka-sink/src/main/java/org/apache/hadoop/metrics2/sink/kafka/KafkaTimelineMetricsReporter.java
+++ b/ambari-metrics-kafka-sink/src/main/java/org/apache/hadoop/metrics2/sink/kafka/KafkaTimelineMetricsReporter.java
@@ -20,12 +20,8 @@ package org.apache.hadoop.metrics2.sink.kafka;
 
 import java.net.InetAddress;
 import java.net.UnknownHostException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashSet;
-import java.util.List;
+import java.util.*;
 import java.util.Map.Entry;
-import java.util.Set;
 import java.util.concurrent.TimeUnit;
 import org.apache.commons.lang.ArrayUtils;
 import org.apache.commons.lang.ClassUtils;
diff --git a/ambari-metrics-storm-sink/pom.xml b/ambari-metrics-storm-sink/pom.xml
index e309817..5687693 100644
--- a/ambari-metrics-storm-sink/pom.xml
+++ b/ambari-metrics-storm-sink/pom.xml
@@ -81,7 +81,7 @@ limitations under the License.
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-shade-plugin</artifactId>
-        <version>2.2</version>
+        <version>3.2.1</version>
         <executions>
           <execution>
             <phase>package</phase>
@@ -127,6 +127,11 @@ limitations under the License.
               <pattern>org.apache.commons.codec</pattern>
               <shadedPattern>org.apache.hadoop.metrics2.sink.relocated.commons.codec</shadedPattern>
             </relocation>
+            <!-- The ambari-metrics-common package already has the org.apache.commons.lang, so just point there -->
+            <relocation>
+              <pattern>org.apache.commons.lang</pattern>
+              <shadedPattern>org.apache.ambari.metrics.relocated.commons.lang</shadedPattern>
+            </relocation>
           </relocations>
         </configuration>
       </plugin>
diff --git a/ambari-metrics-timelineservice/pom.xml b/ambari-metrics-timelineservice/pom.xml
index 3501ed4..dc9dfac 100644
--- a/ambari-metrics-timelineservice/pom.xml
+++ b/ambari-metrics-timelineservice/pom.xml
@@ -36,6 +36,7 @@
     <protobuf.version>2.5.0</protobuf.version>
     <phoenix.version>5.1.2</phoenix.version>
     <hbase.version>2.4.13</hbase.version>
+    <slf4j.version>2.0.0</slf4j.version>
   </properties>
 
   <build>
@@ -92,7 +93,7 @@
       <plugin>
         <groupId>org.codehaus.mojo</groupId>
         <artifactId>rpm-maven-plugin</artifactId>
-        <version>2.0.1</version>
+        <version>2.1.4</version>
         <executions>
           <execution>
             <!-- unbinds rpm creation from maven lifecycle -->
@@ -324,7 +325,7 @@
     <dependency>
       <groupId>org.apache.zookeeper</groupId>
       <artifactId>zookeeper</artifactId>
-      <version>3.4.5.1.3.0.0-107</version>
+      <version>3.5.9</version>
       <exclusions>
         <exclusion>
           <artifactId>jline</artifactId>
diff --git a/ambari-metrics-timelineservice/src/main/java/org/apache/ambari/metrics/core/timeline/upgrade/core/AbstractPhoenixMetricsCopier.java b/ambari-metrics-timelineservice/src/main/java/org/apache/ambari/metrics/core/timeline/upgrade/core/AbstractPhoenixMetricsCopier.java
index f70dc3f..2ce4a74 100644
--- a/ambari-metrics-timelineservice/src/main/java/org/apache/ambari/metrics/core/timeline/upgrade/core/AbstractPhoenixMetricsCopier.java
+++ b/ambari-metrics-timelineservice/src/main/java/org/apache/ambari/metrics/core/timeline/upgrade/core/AbstractPhoenixMetricsCopier.java
@@ -65,7 +65,7 @@ public abstract class AbstractPhoenixMetricsCopier implements Runnable {
       LOG.error(e);
     } finally {
       long timerDelta = System.currentTimeMillis() - timerStart;
-      LOG.debug(String.format("Copying took %s seconds from table %s to table %s for metric names %s", timerDelta/ 1000.0, inputTable,
+      LOG.debug(String.format("Copying took %s seconds from table %s to table %s for metric names %s", timerDelta/ 1000.0, inputTable, outputTable, metricNames));
 
       saveMetricsProgress();
     }
diff --git a/ambari-metrics-timelineservice/src/main/java/org/apache/ambari/metrics/core/timeline/upgrade/core/PhoenixClusterMetricsCopier.java b/ambari-metrics-timelineservice/src/main/java/org/apache/ambari/metrics/core/timeline/upgrade/core/PhoenixClusterMetricsCopier.java
index 0840be8..e5352da 100644
--- a/ambari-metrics-timelineservice/src/main/java/org/apache/ambari/metrics/core/timeline/upgrade/core/PhoenixClusterMetricsCopier.java
+++ b/ambari-metrics-timelineservice/src/main/java/org/apache/ambari/metrics/core/timeline/upgrade/core/PhoenixClusterMetricsCopier.java
@@ -68,4 +68,4 @@ public class PhoenixClusterMetricsCopier extends AbstractPhoenixMetricsCopier {
    }
 
   }
-}
+
diff --git a/pom.xml b/pom.xml
index 4603b23..709d294 100644
--- a/pom.xml
+++ b/pom.xml
@@ -37,14 +37,14 @@
     <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
     <python.ver>python &gt;= 2.6</python.ver>
     <deb.python.ver>python (&gt;= 2.6)</deb.python.ver>
-    <!--TODO change to HDP URL-->
-    <grafana.folder>grafana-5.2.4</grafana.folder>
-    <grafana.tar>https://s3-us-west-2.amazonaws.com/grafana-releases/release/grafana-5.2.4.linux-amd64.tar.gz</grafana.tar>
+    <slf4j.version>2.0.0</slf4j.version>
     <hbase.tar>https://archive.apache.org/dist/hbase/2.4.13/hbase-2.4.13-bin.tar.gz</hbase.tar>
     <hbase.folder>hbase-2.4.13</hbase.folder>
     <hadoop.tar>https://archive.apache.org/dist/hadoop/common/hadoop-3.3.4/hadoop-3.3.4.tar.gz</hadoop.tar>
     <hadoop.folder>hadoop-3.3.4</hadoop.folder>
     <hadoop.version>3.3.4</hadoop.version>
+    <grafana.folder>grafana-6.7.4</grafana.folder>
+    <grafana.tar>https://dl.grafana.com/oss/release/grafana-6.7.4.linux-amd64.tar.gz</grafana.tar>
     <phoenix.tar>https://downloads.apache.org/phoenix/phoenix-5.1.2/phoenix-hbase-2.4-5.1.2-bin.tar.gz</phoenix.tar>
     <phoenix.folder>phoenix-hbase-2.4-5.1.2-bin</phoenix.folder>
     <resmonitor.install.dir>/usr/lib/python2.6/site-packages/resource_monitoring</resmonitor.install.dir>
@@ -71,8 +71,8 @@
   </distributionManagement>
   <repositories>
     <repository>
-      <id>apache-hadoop</id>
-      <name>hdp</name>
+      <id>apache-releases</id>
+      <name>releases</name>
       <url>https://repository.apache.org/content/repositories/releases/</url>
     </repository>
     <repository>
@@ -187,7 +187,7 @@
                <name>package-release</name>
                <value>${project.version}</value>
                <regex>
-                 ^([0-9]+)\.([0-9]+)\.([0-9]+)\.([0-9]+)(\.|-)((([a-zA-Z]+)?([0-9]+))|(SNAPSHOT)).*
+                 ^([0-9]+)\.([0-9]+)\.([0-9]+)\.([0-9]+)((\.|-)(([0-9]+)|(SNAPSHOT)|(techwin)).*)?
                </regex>
                <replacement>$7</replacement>
                <failIfNoMatch>true</failIfNoMatch>


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@ambari.apache.org
For additional commands, e-mail: commits-help@ambari.apache.org