Migrate internal stats to consistent names

Go style -- and existing runtime stats -- do not use underscores, but
instead use camel case. This change makes the internal stats adhere to
that convention.
pull/4610/head
Philip O'Toole 2015-10-28 20:59:10 -07:00
parent 4e2a16c459
commit de7919240f
14 changed files with 101 additions and 97 deletions

View File

@ -1,5 +1,8 @@
## v0.9.5 [unreleased]
### Release Notes
- Field names for the internal stats have been changed to be more inline with Go style.
### Features
- [#4098](https://github.com/influxdb/influxdb/issues/4098): Enable `golint` on the code base - uuid subpackage
- [#4141](https://github.com/influxdb/influxdb/pull/4141): Control whether each query should be logged
@ -86,6 +89,7 @@
- [#4521](https://github.com/influxdb/influxdb/issues/4521): TSM1: panic: decode of short block: got 1, exp 9
- [#4587](https://github.com/influxdb/influxdb/pull/4587): Prevent NaN float values from being stored
- [#4596](https://github.com/influxdb/influxdb/pull/4596): Skip empty string for start position when parsing line protocol @Thanks @ch33hau
- [#4610](https://github.com/influxdb/influxdb/pull/4610): Make internal stats names consistent with Go style.
## v0.9.4 [2015-09-14]

View File

@ -23,16 +23,16 @@ type ConsistencyLevel int
// The statistics generated by the "write" mdoule
const (
statWriteReq = "req"
statPointWriteReq = "point_req"
statPointWriteReqLocal = "point_req_local"
statPointWriteReqRemote = "point_req_remote"
statWriteOK = "write_ok"
statWritePartial = "write_partial"
statWriteTimeout = "write_timeout"
statWriteErr = "write_error"
statWritePointReqHH = "point_req_hh"
statSubWriteOK = "sub_write_ok"
statSubWriteDrop = "sub_write_drop"
statPointWriteReq = "pointReq"
statPointWriteReqLocal = "pointReqLocal"
statPointWriteReqRemote = "pointReqRemote"
statWriteOK = "writeOk"
statWritePartial = "writePartial"
statWriteTimeout = "writeTimeout"
statWriteErr = "writeError"
statWritePointReqHH = "pointReqHH"
statSubWriteOK = "subWriteOk"
statSubWriteDrop = "subWriteDrop"
)
const (

View File

@ -27,11 +27,11 @@ const MuxHeader = 2
// Statistics maintained by the cluster package
const (
writeShardReq = "write_shard_req"
writeShardPointsReq = "write_shard_points_req"
writeShardFail = "write_shard_fail"
mapShardReq = "map_shard_req"
mapShardResp = "map_shard_resp"
writeShardReq = "writeShardReq"
writeShardPointsReq = "writeShardPointsReq"
writeShardFail = "writeShardFail"
mapShardReq = "mapShardReq"
mapShardResp = "mapShardResp"
)
// Service processes data received over raw TCP connections.

View File

@ -22,13 +22,13 @@ const leaderWaitTimeout = 30 * time.Second
// statistics gathered by the collectd service.
const (
statPointsReceived = "points_rx"
statBytesReceived = "bytes_rx"
statPointsParseFail = "points_parse_fail"
statReadFail = "read_fail"
statBatchesTrasmitted = "batches_tx"
statPointsTransmitted = "points_tx"
statBatchesTransmitFail = "batches_tx_fail"
statPointsReceived = "pointsRx"
statBytesReceived = "bytesRx"
statPointsParseFail = "pointsParseFail"
statReadFail = "readFail"
statBatchesTrasmitted = "batchesTx"
statPointsTransmitted = "pointsTx"
statBatchesTransmitFail = "batchesTxFail"
)
// pointsWriter is an internal interface to make testing easier.

View File

@ -23,9 +23,9 @@ const (
// Statistics for the CQ service.
const (
statQueryOK = "query_ok"
statQueryFail = "query_fail"
statPointsWritten = "points_written"
statQueryOK = "queryOk"
statQueryFail = "queryFail"
statPointsWritten = "pointsWritten"
)
// ContinuousQuerier represents a service that executes continuous queries.

View File

@ -25,15 +25,15 @@ const (
// statistics gathered by the graphite package.
const (
statPointsReceived = "points_rx"
statBytesReceived = "bytes_rx"
statPointsParseFail = "points_parse_fail"
statPointsUnsupported = "points_unsupported_fail"
statBatchesTrasmitted = "batches_tx"
statPointsTransmitted = "points_tx"
statBatchesTransmitFail = "batches_tx_fail"
statConnectionsActive = "connections_active"
statConnectionsHandled = "connections_handled"
statPointsReceived = "pointsRx"
statBytesReceived = "bytesRx"
statPointsParseFail = "pointsParseFail"
statPointsUnsupported = "pointsUnsupportedFail"
statBatchesTrasmitted = "batchesTx"
statPointsTransmitted = "pointsTx"
statBatchesTransmitFail = "batchesTxFail"
statConnectionsActive = "connsActive"
statConnectionsHandled = "connsHandled"
)
type tcpConnection struct {

View File

@ -21,11 +21,11 @@ import (
var ErrHintedHandoffDisabled = fmt.Errorf("hinted handoff disabled")
const (
writeShardReq = "wr_shard_req"
writeShardReqPoints = "wr_shard_req_points"
writeNodeReq = "wr_node_req"
writeNodeReqFail = "wr_node_req_fail"
writeNodeReqPoints = "wr_node_req_points"
writeShardReq = "writeShardReq"
writeShardReqPoints = "writeShardReqPoints"
writeNodeReq = "writeNodeReq"
writeNodeReqFail = "writeNodeReqFail"
writeNodeReqPoints = "writeNodeReqPoints"
)
type Service struct {

View File

@ -15,16 +15,16 @@ import (
// statistics gathered by the httpd package.
const (
statRequest = "req" // Number of HTTP requests served
statCQRequest = "cq_req" // Number of CQ-execute requests served
statQueryRequest = "query_req" // Number of query requests served
statWriteRequest = "write_req" // Number of write requests serverd
statPingRequest = "ping_req" // Number of ping requests served
statWriteRequestBytesReceived = "write_req_bytes" // Sum of all bytes in write requests
statQueryRequestBytesTransmitted = "query_resp_bytes" // Sum of all bytes returned in query reponses
statPointsWrittenOK = "points_written_ok" // Number of points written OK
statPointsWrittenFail = "points_written_fail" // Number of points that failed to be written
statAuthFail = "auth_fail" // Number of authentication failures
statRequest = "req" // Number of HTTP requests served
statCQRequest = "cqReq" // Number of CQ-execute requests served
statQueryRequest = "queryReq" // Number of query requests served
statWriteRequest = "writeReq" // Number of write requests serverd
statPingRequest = "pingReq" // Number of ping requests served
statWriteRequestBytesReceived = "writeReqBytes" // Sum of all bytes in write requests
statQueryRequestBytesTransmitted = "queryRespBytes" // Sum of all bytes returned in query reponses
statPointsWrittenOK = "pointsWritteOk" // Number of points written OK
statPointsWrittenFail = "pointsWrittenFail" // Number of points that failed to be written
statAuthFail = "authFail" // Number of authentication failures
)
// Service manages the listener and handler for an HTTP endpoint.

View File

@ -27,21 +27,21 @@ const leaderWaitTimeout = 30 * time.Second
// statistics gathered by the openTSDB package.
const (
statHTTPConnectionsHandled = "http_connections_handled"
statTelnetConnectionsActive = "tl_connections_active"
statTelnetConnectionsHandled = "tl_connections_handled"
statTelnetPointsReceived = "tl_points_rx"
statTelnetBytesReceived = "tl_bytes_rx"
statTelnetReadError = "tl_read_err"
statTelnetBadLine = "tl_bad_line"
statTelnetBadTime = "tl_bad_time"
statTelnetBadTag = "tl_bad_tag"
statTelnetBadFloat = "tl_bad_float"
statBatchesTrasmitted = "batches_tx"
statPointsTransmitted = "points_tx"
statBatchesTransmitFail = "batches_tx_fail"
statConnectionsActive = "connections_active"
statConnectionsHandled = "connections_handled"
statHTTPConnectionsHandled = "httpConnsHandled"
statTelnetConnectionsActive = "tlConnsActive"
statTelnetConnectionsHandled = "tlConnsHandled"
statTelnetPointsReceived = "tlPointsRx"
statTelnetBytesReceived = "tlBytesRx"
statTelnetReadError = "tlReadErr"
statTelnetBadLine = "tlBadLine"
statTelnetBadTime = "tlBadTime"
statTelnetBadTag = "tlBadTag"
statTelnetBadFloat = "tlBadFloat"
statBatchesTrasmitted = "batchesTx"
statPointsTransmitted = "pointsTx"
statBatchesTransmitFail = "batchesTxFail"
statConnectionsActive = "connsActive"
statConnectionsHandled = "connsHandled"
)
// Service manages the listener and handler for an HTTP endpoint.

View File

@ -16,8 +16,8 @@ import (
// Statistics for the Subscriber service.
const (
statPointsWritten = "points_written"
statWriteFailures = "write_failures"
statPointsWritten = "pointsWritten"
statWriteFailures = "writeFailures"
)
type PointsWriter interface {

View File

@ -23,13 +23,13 @@ const (
// statistics gathered by the UDP package.
const (
statPointsReceived = "points_rx"
statBytesReceived = "bytes_rx"
statPointsParseFail = "points_parse_fail"
statReadFail = "read_fail"
statBatchesTrasmitted = "batches_tx"
statPointsTransmitted = "points_tx"
statBatchesTransmitFail = "batches_tx_fail"
statPointsReceived = "pointsRx"
statBytesReceived = "bytesRx"
statPointsParseFail = "pointsParseFail"
statReadFail = "readFail"
statBatchesTrasmitted = "batchesTx"
statPointsTransmitted = "pointsTx"
statBatchesTransmitFail = "batchesTxFail"
)
//

View File

@ -33,12 +33,12 @@ const (
)
const (
statSlowInsert = "slow_insert"
statPointsWrite = "points_write"
statPointsWriteDedupe = "points_write_dedupe"
statBlocksWrite = "blks_write"
statBlocksWriteBytes = "blks_write_bytes"
statBlocksWriteBytesCompress = "blks_write_bytes_c"
statSlowInsert = "slowInsert"
statPointsWrite = "pointsWrite"
statPointsWriteDedupe = "pointsWriteDedupe"
statBlocksWrite = "blksWrite"
statBlocksWriteBytes = "blksWriteBytes"
statBlocksWriteBytesCompress = "blksWriteBytesC"
)
func init() {

View File

@ -72,19 +72,19 @@ const (
// Statistics maintained by the WAL
const (
statPointsWriteReq = "points_write_req"
statPointsWrite = "points_write"
statPointsWriteReq = "pointsWriteReq"
statPointsWrite = "pointsWrite"
statFlush = "flush"
statAutoFlush = "auto_flush"
statIdleFlush = "idle_flush"
statMetadataFlush = "meta_flush"
statThresholdFlush = "threshold_flush"
statMemoryFlush = "mem_flush"
statSeriesFlushed = "series_flush"
statPointsFlushed = "points_flush"
statFlushDuration = "flush_duration"
statWriteFail = "write_fail"
statMemorySize = "mem_size"
statAutoFlush = "autoFlush"
statIdleFlush = "idleFlush"
statMetadataFlush = "metaFlush"
statThresholdFlush = "thresholdFlush"
statMemoryFlush = "memFlush"
statSeriesFlushed = "seriesFlush"
statPointsFlushed = "pointsFlush"
statFlushDuration = "flushDuration"
statWriteFail = "writeFail"
statMemorySize = "memSize"
)
// flushType indiciates why a flush and compaction are being run so the partition can

View File

@ -20,12 +20,12 @@ import (
)
const (
statWriteReq = "write_req"
statSeriesCreate = "series_create"
statFieldsCreate = "fields_create"
statWritePointsFail = "write_points_fail"
statWritePointsOK = "write_points_ok"
statWriteBytes = "write_bytes"
statWriteReq = "writeReq"
statSeriesCreate = "seriesCreate"
statFieldsCreate = "fieldsCreate"
statWritePointsFail = "writePointsFail"
statWritePointsOK = "writePointsOk"
statWriteBytes = "writeBytes"
)
var (