diff --git a/CHANGELOG.md b/CHANGELOG.md index 05b5bfa6a1..351e32537b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -53,6 +53,7 @@ With this release InfluxDB is moving to Go 1.5. - [#4053](https://github.com/influxdb/influxdb/pull/4053): Prohibit dropping default retention policy. - [#4060](https://github.com/influxdb/influxdb/pull/4060): Don't log EOF error in openTSDB input. - [#3978](https://github.com/influxdb/influxdb/issues/3978): [0.9.3] (regression) cannot use GROUP BY * with more than a single field in SELECT clause +- [#4058](https://github.com/influxdb/influxdb/pull/4058): Disable bz1 recompression ## v0.9.3 [2015-08-26] diff --git a/tsdb/engine/bz1/bz1.go b/tsdb/engine/bz1/bz1.go index 07c86a360c..29ebc86652 100644 --- a/tsdb/engine/bz1/bz1.go +++ b/tsdb/engine/bz1/bz1.go @@ -389,25 +389,14 @@ func (e *Engine) writeIndex(tx *bolt.Tx, key string, a [][]byte) error { return fmt.Errorf("new blocks: %s", err) } return nil - } else { - // Determine uncompressed block size. - sz, err := snappy.DecodedLen(v[8:]) - if err != nil { - return fmt.Errorf("snappy decoded len: %s", err) - } - // Append new blocks if our time range is past the last on-disk time - // and if our previous block was at least the minimum block size. - if int64(btou64(v[0:8])) < tmin && sz >= e.BlockSize { - bkt.FillPercent = 1.0 - if err := e.writeBlocks(bkt, a); err != nil { - return fmt.Errorf("append blocks: %s", err) - } - return nil + } else if int64(btou64(v[0:8])) < tmin { + // Append new blocks if our time range is past the last on-disk time. + bkt.FillPercent = 1.0 + if err := e.writeBlocks(bkt, a); err != nil { + return fmt.Errorf("append blocks: %s", err) } - - // Otherwise fallthrough to slower insert mode. - e.statMap.Add(statSlowInsert, 1) + return nil } // Generate map of inserted keys.