From 37750acef6236eccc36548931f876b33a59d8a8e Mon Sep 17 00:00:00 2001 From: Pradeep Chhetri Date: Thu, 11 Jun 2015 17:33:26 +0545 Subject: [PATCH] Fixed some Typos --- influxql/ast.go | 4 ++-- tsdb/meta.go | 5 +++-- tsdb/query_executor.go | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/influxql/ast.go b/influxql/ast.go index e5c951b977..aabed19d74 100644 --- a/influxql/ast.go +++ b/influxql/ast.go @@ -1360,7 +1360,7 @@ func MatchSource(sources Sources, name string) string { return "" } -// Target represents a target (destination) policy, measurment, and DB. +// Target represents a target (destination) policy, measurement, and DB. type Target struct { // Measurement to write into. Measurement *Measurement @@ -1625,7 +1625,7 @@ func (s *ShowMeasurementsStatement) RequiredPrivileges() ExecutionPrivileges { return ExecutionPrivileges{{Name: "", Privilege: ReadPrivilege}} } -// DropMeasurmentStatement represents a command to drop a measurement. +// DropMeasurementStatement represents a command to drop a measurement. type DropMeasurementStatement struct { // Name of the measurement to be dropped. Name string diff --git a/tsdb/meta.go b/tsdb/meta.go index 77975a52e7..e196277de1 100644 --- a/tsdb/meta.go +++ b/tsdb/meta.go @@ -46,7 +46,7 @@ func (d *DatabaseIndex) Measurement(name string) *Measurement { return d.measurements[name] } -// MeasurementSeriesCounts returns the number of measurments and series currently indexed by the database. +// MeasurementSeriesCounts returns the number of measurements and series currently indexed by the database. // Useful for reporting and monitoring. func (d *DatabaseIndex) MeasurementSeriesCounts() (nMeasurements int, nSeries int) { d.mu.RLock() @@ -78,7 +78,7 @@ func (s *DatabaseIndex) createSeriesIndexIfNotExists(measurementName string, ser return series } -// addMeasurementToIndexIfNotExists creates or retrieves an in memory index object for the measurement +// createMeasurementIndexIfNotExists creates or retrieves an in memory index object for the measurement func (s *DatabaseIndex) createMeasurementIndexIfNotExists(name string) *Measurement { m := s.measurements[name] if m == nil { @@ -147,6 +147,7 @@ func (db *DatabaseIndex) measurementsByExpr(expr influxql.Expr) (Measurements, e return nil, fmt.Errorf("%#v", expr) } +// measurementsByTagFilters returns the measurements matching the filters on tag values. func (db *DatabaseIndex) measurementsByTagFilters(filters []*TagFilter) Measurements { // If no filters, then return all measurements. if len(filters) == 0 { diff --git a/tsdb/query_executor.go b/tsdb/query_executor.go index 53165e730b..fda80b891e 100644 --- a/tsdb/query_executor.go +++ b/tsdb/query_executor.go @@ -355,7 +355,7 @@ func (q *QueryExecutor) expandSources(sources influxql.Sources) (influxql.Source // Get measurements from the database that match the regex. measurements := db.measurementsByRegex(src.Regex.Val) - // Add those measurments to the set. + // Add those measurements to the set. for _, m := range measurements { m2 := &influxql.Measurement{ Database: src.Database,