Skip to content

Commit

Permalink
Add a missing method to facade which is called by the metrics storage…
Browse files Browse the repository at this point in the history
… client in cortex (#1987)

Signed-off-by: Ed Welch <edward.welch@grafana.com>
  • Loading branch information
slim-bean authored Apr 27, 2020
1 parent b652f0a commit 46cfdae
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions pkg/chunkenc/facade.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,14 @@ func (f Facade) Utilization() float64 {
return f.c.Utilization()
}

// Size implements encoding.Chunk.
func (f Facade) Size() int {
if f.c == nil {
return 0
}
return f.c.Size()
}

// LokiChunk returns the chunkenc.Chunk.
func (f Facade) LokiChunk() Chunk {
return f.c
Expand Down

0 comments on commit 46cfdae

Please sign in to comment.