mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-11-21 14:44:00 +00:00
all: spelling fix: superflouos->superfluous. This is a follow-up for 0acdab3ab9
This commit is contained in:
parent
3159b41689
commit
7f3e884a31
7 changed files with 9 additions and 9 deletions
|
@ -245,7 +245,7 @@ func (idxbc *indexBlockCache) Get(k uint64) *indexBlock {
|
||||||
func (idxbc *indexBlockCache) Put(k uint64, idxb *indexBlock) {
|
func (idxbc *indexBlockCache) Put(k uint64, idxb *indexBlock) {
|
||||||
idxbc.mu.Lock()
|
idxbc.mu.Lock()
|
||||||
|
|
||||||
// Remove superflouos entries.
|
// Remove superfluous entries.
|
||||||
if overflow := len(idxbc.m) - getMaxCachedIndexBlocksPerPart(); overflow > 0 {
|
if overflow := len(idxbc.m) - getMaxCachedIndexBlocksPerPart(); overflow > 0 {
|
||||||
// Remove 10% of items from the cache.
|
// Remove 10% of items from the cache.
|
||||||
overflow = int(float64(len(idxbc.m)) * 0.1)
|
overflow = int(float64(len(idxbc.m)) * 0.1)
|
||||||
|
@ -393,7 +393,7 @@ func (ibc *inmemoryBlockCache) Get(k inmemoryBlockCacheKey) *inmemoryBlock {
|
||||||
func (ibc *inmemoryBlockCache) Put(k inmemoryBlockCacheKey, ib *inmemoryBlock) {
|
func (ibc *inmemoryBlockCache) Put(k inmemoryBlockCacheKey, ib *inmemoryBlock) {
|
||||||
ibc.mu.Lock()
|
ibc.mu.Lock()
|
||||||
|
|
||||||
// Clean superflouos entries in cache.
|
// Clean superfluous entries in cache.
|
||||||
if overflow := len(ibc.m) - getMaxCachedInmemoryBlocksPerPart(); overflow > 0 {
|
if overflow := len(ibc.m) - getMaxCachedInmemoryBlocksPerPart(); overflow > 0 {
|
||||||
// Remove 10% of items from the cache.
|
// Remove 10% of items from the cache.
|
||||||
overflow = int(float64(len(ibc.m)) * 0.1)
|
overflow = int(float64(len(ibc.m)) * 0.1)
|
||||||
|
|
|
@ -136,7 +136,7 @@ func testTableSearchSerial(tb *Table, items []string) error {
|
||||||
n++
|
n++
|
||||||
}
|
}
|
||||||
if ts.NextItem() {
|
if ts.NextItem() {
|
||||||
return fmt.Errorf("superflouos item found at position %d when searching for %q: %q", n, key, ts.Item)
|
return fmt.Errorf("superfluous item found at position %d when searching for %q: %q", n, key, ts.Item)
|
||||||
}
|
}
|
||||||
if err := ts.Error(); err != nil {
|
if err := ts.Error(); err != nil {
|
||||||
return fmt.Errorf("unexpected error when searching for %q: %w", key, err)
|
return fmt.Errorf("unexpected error when searching for %q: %w", key, err)
|
||||||
|
|
|
@ -83,7 +83,7 @@ func parseRows(sc *scanner, dst []Row, tags []Tag, metrics []metric, cds []Colum
|
||||||
tagsLen := len(tags)
|
tagsLen := len(tags)
|
||||||
for sc.NextColumn() {
|
for sc.NextColumn() {
|
||||||
if col >= uint(len(cds)) {
|
if col >= uint(len(cds)) {
|
||||||
// Skip superflouous column.
|
// Skip superfluous column.
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
cd := &cds[col]
|
cd := &cds[col]
|
||||||
|
|
|
@ -165,7 +165,7 @@ func TestRowsUnmarshalSuccess(t *testing.T) {
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
// Superflouos columns
|
// Superfluous columns
|
||||||
f("1:metric:foo", `123,456,foo,bar`, []Row{
|
f("1:metric:foo", `123,456,foo,bar`, []Row{
|
||||||
{
|
{
|
||||||
Metric: "foo",
|
Metric: "foo",
|
||||||
|
|
|
@ -44,7 +44,7 @@ func TestDeduplicateSamples(t *testing.T) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if j != len(timestampsCopy) {
|
if j != len(timestampsCopy) {
|
||||||
t.Fatalf("superflouos timestamps found starting from index %d: %v", j, timestampsCopy[j:])
|
t.Fatalf("superfluous timestamps found starting from index %d: %v", j, timestampsCopy[j:])
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
f(time.Millisecond, nil, []int64{})
|
f(time.Millisecond, nil, []int64{})
|
||||||
|
@ -94,7 +94,7 @@ func TestDeduplicateSamplesDuringMerge(t *testing.T) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if j != len(timestampsCopy) {
|
if j != len(timestampsCopy) {
|
||||||
t.Fatalf("superflouos timestamps found starting from index %d: %v", j, timestampsCopy[j:])
|
t.Fatalf("superfluous timestamps found starting from index %d: %v", j, timestampsCopy[j:])
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
f(time.Millisecond, nil, []int64{})
|
f(time.Millisecond, nil, []int64{})
|
||||||
|
|
|
@ -479,7 +479,7 @@ var maxLabelsPerTimeseries = 30
|
||||||
// SetMaxLabelsPerTimeseries sets the limit on the number of labels
|
// SetMaxLabelsPerTimeseries sets the limit on the number of labels
|
||||||
// per each time series.
|
// per each time series.
|
||||||
//
|
//
|
||||||
// Superfouos labels are dropped.
|
// Superfluous labels are dropped.
|
||||||
func SetMaxLabelsPerTimeseries(maxLabels int) {
|
func SetMaxLabelsPerTimeseries(maxLabels int) {
|
||||||
if maxLabels <= 0 {
|
if maxLabels <= 0 {
|
||||||
logger.Panicf("BUG: maxLabels must be positive; got %d", maxLabels)
|
logger.Panicf("BUG: maxLabels must be positive; got %d", maxLabels)
|
||||||
|
|
|
@ -249,7 +249,7 @@ func (ibc *indexBlockCache) Get(k uint64) *indexBlock {
|
||||||
func (ibc *indexBlockCache) Put(k uint64, ib *indexBlock) {
|
func (ibc *indexBlockCache) Put(k uint64, ib *indexBlock) {
|
||||||
ibc.mu.Lock()
|
ibc.mu.Lock()
|
||||||
|
|
||||||
// Clean superflouos cache entries.
|
// Clean superfluous cache entries.
|
||||||
if overflow := len(ibc.m) - getMaxCachedIndexBlocksPerPart(); overflow > 0 {
|
if overflow := len(ibc.m) - getMaxCachedIndexBlocksPerPart(); overflow > 0 {
|
||||||
// Remove 10% of items from the cache.
|
// Remove 10% of items from the cache.
|
||||||
overflow = int(float64(len(ibc.m)) * 0.1)
|
overflow = int(float64(len(ibc.m)) * 0.1)
|
||||||
|
|
Loading…
Reference in a new issue