001/*
002 * Licensed to the Apache Software Foundation (ASF) under one
003 * or more contributor license agreements.  See the NOTICE file
004 * distributed with this work for additional information
005 * regarding copyright ownership.  The ASF licenses this file
006 * to you under the Apache License, Version 2.0 (the
007 * "License"); you may not use this file except in compliance
008 * with the License.  You may obtain a copy of the License at
009 *
010 *     http://www.apache.org/licenses/LICENSE-2.0
011 *
012 * Unless required by applicable law or agreed to in writing, software
013 * distributed under the License is distributed on an "AS IS" BASIS,
014 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
015 * See the License for the specific language governing permissions and
016 * limitations under the License.
017 */
018package org.apache.hadoop.hbase.ipc;
019
020import org.apache.hadoop.hbase.metrics.ExceptionTrackingSource;
021import org.apache.yetus.audience.InterfaceAudience;
022
023@InterfaceAudience.Private
024public interface MetricsHBaseServerSource extends ExceptionTrackingSource {
025  String AUTHORIZATION_SUCCESSES_NAME = "authorizationSuccesses";
026  String AUTHORIZATION_SUCCESSES_DESC = "Number of authorization successes.";
027  String AUTHORIZATION_FAILURES_NAME = "authorizationFailures";
028  String AUTHORIZATION_FAILURES_DESC = "Number of authorization failures.";
029  String AUTHENTICATION_SUCCESSES_NAME = "authenticationSuccesses";
030  String AUTHENTICATION_SUCCESSES_DESC = "Number of authentication successes.";
031  String AUTHENTICATION_FAILURES_NAME = "authenticationFailures";
032  String AUTHENTICATION_FAILURES_DESC = "Number of authentication failures.";
033  String AUTHENTICATION_FALLBACKS_NAME = "authenticationFallbacks";
034  String AUTHENTICATION_FALLBACKS_DESC = "Number of fallbacks to insecure authentication.";
035  String SENT_BYTES_NAME = "sentBytes";
036  String SENT_BYTES_DESC = "Number of bytes sent.";
037  String RECEIVED_BYTES_NAME = "receivedBytes";
038  String RECEIVED_BYTES_DESC = "Number of bytes received.";
039  String REQUEST_SIZE_NAME = "requestSize";
040  String REQUEST_SIZE_DESC = "Request size in bytes.";
041  String RESPONSE_SIZE_NAME = "responseSize";
042  String RESPONSE_SIZE_DESC = "Response size in bytes.";
043  String QUEUE_CALL_TIME_NAME = "queueCallTime";
044  String QUEUE_CALL_TIME_DESC = "Queue Call Time.";
045  String PROCESS_CALL_TIME_NAME = "processCallTime";
046  String PROCESS_CALL_TIME_DESC = "Processing call time.";
047  String TOTAL_CALL_TIME_NAME = "totalCallTime";
048  String TOTAL_CALL_TIME_DESC = "Total call time, including both queued and processing time.";
049  String QUEUE_SIZE_NAME = "queueSize";
050  String QUEUE_SIZE_DESC = "Number of bytes in the call queues; request has been read and "
051    + "parsed and is waiting to run or is currently being executed.";
052  String GENERAL_QUEUE_NAME = "numCallsInGeneralQueue";
053  String GENERAL_QUEUE_DESC = "Number of calls in the general call queue; "
054    + "parsed requests waiting in scheduler to be executed";
055  String PRIORITY_QUEUE_NAME = "numCallsInPriorityQueue";
056  String METAPRIORITY_QUEUE_NAME = "numCallsInMetaPriorityQueue";
057  String REPLICATION_QUEUE_NAME = "numCallsInReplicationQueue";
058  String REPLICATION_QUEUE_DESC = "Number of calls in the replication call queue waiting to be run";
059  String BULKLOAD_QUEUE_NAME = "numCallsInBulkLoadQueue";
060  String BULKLOAD_QUEUE_DESC = "Number of calls in the bulkload call queue waiting to be run";
061  String PRIORITY_QUEUE_DESC = "Number of calls in the priority call queue waiting to be run";
062  String METAPRIORITY_QUEUE_DESC = "Number of calls in the priority call queue waiting to be run";
063  String WRITE_QUEUE_NAME = "numCallsInWriteQueue";
064  String WRITE_QUEUE_DESC = "Number of calls in the write call queue; "
065    + "parsed requests waiting in scheduler to be executed";
066  String READ_QUEUE_NAME = "numCallsInReadQueue";
067  String READ_QUEUE_DESC = "Number of calls in the read call queue; "
068    + "parsed requests waiting in scheduler to be executed";
069  String SCAN_QUEUE_NAME = "numCallsInScanQueue";
070  String SCAN_QUEUE_DESC = "Number of calls in the scan call queue; "
071    + "parsed requests waiting in scheduler to be executed";
072  String NUM_OPEN_CONNECTIONS_NAME = "numOpenConnections";
073  String NUM_OPEN_CONNECTIONS_DESC = "Number of open connections.";
074  String NUM_ACTIVE_HANDLER_NAME = "numActiveHandler";
075  String NUM_ACTIVE_HANDLER_DESC = "Total number of active rpc handlers.";
076  String NUM_ACTIVE_GENERAL_HANDLER_NAME = "numActiveGeneralHandler";
077  String NUM_ACTIVE_GENERAL_HANDLER_DESC = "Number of active general rpc handlers.";
078  String NUM_ACTIVE_PRIORITY_HANDLER_NAME = "numActivePriorityHandler";
079  String NUM_ACTIVE_PRIORITY_HANDLER_DESC = "Number of active priority rpc handlers.";
080  String NUM_ACTIVE_REPLICATION_HANDLER_NAME = "numActiveReplicationHandler";
081  String NUM_ACTIVE_REPLICATION_HANDLER_DESC = "Number of active replication rpc handlers.";
082  String NUM_ACTIVE_BULKLOAD_HANDLER_NAME = "numActiveBulkLoadHandler";
083  String NUM_ACTIVE_BULKLOAD_HANDLER_DESC = "Number of active bulkload rpc handlers.";
084  String NUM_ACTIVE_WRITE_HANDLER_NAME = "numActiveWriteHandler";
085  String NUM_ACTIVE_WRITE_HANDLER_DESC = "Number of active write rpc handlers.";
086  String NUM_ACTIVE_READ_HANDLER_NAME = "numActiveReadHandler";
087  String NUM_ACTIVE_READ_HANDLER_DESC = "Number of active read rpc handlers.";
088  String NUM_ACTIVE_SCAN_HANDLER_NAME = "numActiveScanHandler";
089  String NUM_ACTIVE_SCAN_HANDLER_DESC = "Number of active scan rpc handlers.";
090  String NUM_GENERAL_CALLS_DROPPED_NAME = "numGeneralCallsDropped";
091  String NUM_GENERAL_CALLS_DROPPED_DESC =
092    "Total number of calls in general queue which " + "were dropped by CoDel RPC executor";
093  String NUM_LIFO_MODE_SWITCHES_NAME = "numLifoModeSwitches";
094  String NUM_LIFO_MODE_SWITCHES_DESC =
095    "Total number of calls in general queue which " + "were served from the tail of the queue";
096  // Direct Memory Usage metrics
097  String NETTY_DM_USAGE_NAME = "nettyDirectMemoryUsage";
098
099  String NETTY_DM_USAGE_DESC = "Current Netty direct memory usage.";
100
101  void authorizationSuccess();
102
103  void authorizationFailure();
104
105  void authenticationSuccess();
106
107  void authenticationFailure();
108
109  void authenticationFallback();
110
111  void sentBytes(long count);
112
113  void receivedBytes(int count);
114
115  void sentResponse(long count);
116
117  void receivedRequest(long count);
118
119  void dequeuedCall(int qTime);
120
121  void processedCall(int processingTime);
122
123  void queuedAndProcessedCall(int totalTime);
124}