steveloughran commented on a change in pull request #2056:
URL: https://github.com/apache/hadoop/pull/2056#discussion_r439319323
##
File path:
hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AbfsStatistic.java
##
@@ -57,7 +57,23 @@
FILES_DELETED("files_deleted",
"Total number of files deleted from the object store."),
ERROR_IGNORED("error_ignored",
- "Errors caught and ignored.");
+ "Errors caught and ignored."),
+
+ //Network statistics.
+ CONNECTIONS_MADE("connections_made",
+ "Total number of times connection was made with Data store."),
+ SEND_REQUESTS("send_requests",
+ "Total number of times http requests was sent to the data store."),
+ GET_RESPONSE("get_response",
+ "Total number of times response was recorded after sending requests."),
Review comment:
"a response"
##
File path:
hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AbfsStatistic.java
##
@@ -57,7 +57,23 @@
FILES_DELETED("files_deleted",
"Total number of files deleted from the object store."),
ERROR_IGNORED("error_ignored",
- "Errors caught and ignored.");
+ "Errors caught and ignored."),
+
+ //Network statistics.
+ CONNECTIONS_MADE("connections_made",
+ "Total number of times connection was made with Data store."),
+ SEND_REQUESTS("send_requests",
+ "Total number of times http requests was sent to the data store."),
+ GET_RESPONSE("get_response",
Review comment:
responses
##
File path:
hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AbfsStatistic.java
##
@@ -57,7 +57,23 @@
FILES_DELETED("files_deleted",
"Total number of files deleted from the object store."),
ERROR_IGNORED("error_ignored",
- "Errors caught and ignored.");
+ "Errors caught and ignored."),
+
+ //Network statistics.
+ CONNECTIONS_MADE("connections_made",
+ "Total number of times connection was made with Data store."),
+ SEND_REQUESTS("send_requests",
+ "Total number of times http requests was sent to the data store."),
+ GET_RESPONSE("get_response",
+ "Total number of times response was recorded after sending requests."),
+ BYTES_SEND("bytes_send",
+ "Total bytes sent through http requests."),
Review comment:
how about "bytes sent from Azure Datalake"
##
File path:
hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AbfsStatistic.java
##
@@ -57,7 +57,23 @@
FILES_DELETED("files_deleted",
"Total number of files deleted from the object store."),
ERROR_IGNORED("error_ignored",
- "Errors caught and ignored.");
+ "Errors caught and ignored."),
+
+ //Network statistics.
+ CONNECTIONS_MADE("connections_made",
+ "Total number of times connection was made with Data store."),
+ SEND_REQUESTS("send_requests",
+ "Total number of times http requests was sent to the data store."),
Review comment:
"were sent"
##
File path:
hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AbfsStatistic.java
##
@@ -57,7 +57,23 @@
FILES_DELETED("files_deleted",
"Total number of files deleted from the object store."),
ERROR_IGNORED("error_ignored",
- "Errors caught and ignored.");
+ "Errors caught and ignored."),
+
+ //Network statistics.
+ CONNECTIONS_MADE("connections_made",
+ "Total number of times connection was made with Data store."),
+ SEND_REQUESTS("send_requests",
+ "Total number of times http requests was sent to the data store."),
+ GET_RESPONSE("get_response",
+ "Total number of times response was recorded after sending requests."),
+ BYTES_SEND("bytes_send",
Review comment:
"bytes sent"
##
File path:
hadoop-tools/hadoop-azure/src/test/java/org/apache/hadoop/fs/azurebfs/ITestAbfsNetworkStatistics.java
##
@@ -0,0 +1,245 @@
+/**
+ * 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.
+ */
+
+package org.apache.hadoop.fs.azurebfs;
+
+import java.io.IOException;
+import java.util.Map;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.junit.Test;
+
+import