Removed some inmem references

pull/10616/head
Edd Robinson 2018-09-26 17:11:22 +01:00
parent e4cca868f4
commit aa433a723a
3 changed files with 4 additions and 46 deletions

View File

@ -5,7 +5,6 @@ import (
"fmt"
"time"
"github.com/influxdata/influxdb/monitor/diagnostics"
"github.com/influxdata/influxdb/toml"
)
@ -14,7 +13,7 @@ const (
DefaultEngine = "tsm1"
// DefaultIndex is the default index for new shards
DefaultIndex = InmemIndexName
DefaultIndex = TSI1IndexName
// tsdb/engine/wal configuration options
@ -48,17 +47,6 @@ const (
// will be set to equal the normal throughput
DefaultCompactThroughputBurst = 48 * 1024 * 1024
// DefaultMaxPointsPerBlock is the maximum number of points in an encoded
// block in a TSM file
DefaultMaxPointsPerBlock = 1000
// DefaultMaxSeriesPerDatabase is the maximum number of series a node can hold per database.
// This limit only applies to the "inmem" index.
DefaultMaxSeriesPerDatabase = 1000000
// DefaultMaxValuesPerTag is the maximum number of values a tag can have within a measurement.
DefaultMaxValuesPerTag = 100000
// DefaultMaxConcurrentCompactions is the maximum number of concurrent full and level compactions
// that can run at one time. A value of 0 results in 50% of runtime.GOMAXPROCS(0) used at runtime.
DefaultMaxConcurrentCompactions = 0
@ -90,16 +78,6 @@ type Config struct {
// Limits
// MaxSeriesPerDatabase is the maximum number of series a node can hold per database.
// When this limit is exceeded, writes return a 'max series per database exceeded' error.
// A value of 0 disables the limit. This limit only applies when using the "inmem" index.
MaxSeriesPerDatabase int `toml:"max-series-per-database"`
// MaxValuesPerTag is the maximum number of tag values a single tag key can have within
// a measurement. When the limit is execeeded, writes return an error.
// A value of 0 disables the limit.
MaxValuesPerTag int `toml:"max-values-per-tag"`
// MaxConcurrentCompactions is the maximum number of concurrent level and full compactions
// that can be running at one time across all shards. Compactions scheduled to run when the
// limit is reached are blocked until a running compaction completes. Snapshot compactions are
@ -135,10 +113,7 @@ func NewConfig() Config {
CompactFullWriteColdDuration: toml.Duration(DefaultCompactFullWriteColdDuration),
CompactThroughput: toml.Size(DefaultCompactThroughput),
CompactThroughputBurst: toml.Size(DefaultCompactThroughputBurst),
MaxSeriesPerDatabase: DefaultMaxSeriesPerDatabase,
MaxValuesPerTag: DefaultMaxValuesPerTag,
MaxConcurrentCompactions: DefaultMaxConcurrentCompactions,
MaxConcurrentCompactions: DefaultMaxConcurrentCompactions,
MaxIndexLogFileSize: toml.Size(DefaultMaxIndexLogFileSize),
@ -181,17 +156,3 @@ func (c *Config) Validate() error {
return nil
}
// Diagnostics returns a diagnostics representation of a subset of the Config.
func (c Config) Diagnostics() (*diagnostics.Diagnostics, error) {
return diagnostics.RowFromMap(map[string]interface{}{
"dir": c.Dir,
"cache-max-memory-size": c.CacheMaxMemorySize,
"cache-snapshot-memory-size": c.CacheSnapshotMemorySize,
"cache-snapshot-write-cold-duration": c.CacheSnapshotWriteColdDuration,
"compact-full-write-cold-duration": c.CompactFullWriteColdDuration,
"max-series-per-database": c.MaxSeriesPerDatabase,
"max-values-per-tag": c.MaxValuesPerTag,
"max-concurrent-compactions": c.MaxConcurrentCompactions,
}), nil
}

View File

@ -15,10 +15,7 @@ import (
)
// Available index types.
const (
InmemIndexName = "inmem"
TSI1IndexName = "tsi1"
)
const TSI1IndexName = "tsi1"
type Index interface {
Open() error // used by this package

View File

@ -24,7 +24,7 @@ import (
)
// IndexName is the name of the index.
const IndexName = tsdb.TSI1IndexName
const IndexName = "tsi1"
// ErrCompactionInterrupted is returned if compactions are disabled or
// an index is closed while a compaction is occurring.