set delete-tallies default to false (#1844)

This commit is contained in:
Jennifer Li Johnson 2019-04-25 15:30:37 -04:00 committed by GitHub
parent 381ab0b63a
commit db6a2a46a9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 10 additions and 10 deletions

View File

@ -487,7 +487,7 @@ func (planet *Planet) newSatellites(count int) ([]*satellite.Peer, error) {
Rollup: rollup.Config{
Interval: 2 * time.Minute,
MaxAlphaUsage: 25 * memory.GB,
DeleteTallies: true,
DeleteTallies: false,
},
Mail: mailservice.Config{
SMTPServerAddress: "smtp.mail.example.com:587",

View File

@ -19,7 +19,7 @@ import (
type Config struct {
Interval time.Duration `help:"how frequently rollup should run" devDefault:"120s" releaseDefault:"24h"`
MaxAlphaUsage memory.Size `help:"the bandwidth and storage usage limit for the alpha release" default:"25GB"`
DeleteTallies bool `help:"option for deleting tallies after they are rolled up" default:"true"`
DeleteTallies bool `help:"option for deleting tallies after they are rolled up" default:"false"`
}
// Service is the rollup service for totalling data on storage nodes on daily intervals

View File

@ -27,13 +27,7 @@ type testData struct {
func TestRollupNoDeletes(t *testing.T) {
testplanet.Run(t, testplanet.Config{
SatelliteCount: 1, StorageNodeCount: 10, UplinkCount: 0,
Reconfigure: testplanet.Reconfigure{
Satellite: func(log *zap.Logger, index int, config *satellite.Config) {
config.Rollup.DeleteTallies = false
},
},
},
SatelliteCount: 1, StorageNodeCount: 10, UplinkCount: 0},
func(t *testing.T, ctx *testcontext.Context, planet *testplanet.Planet) {
days := 5
testData := createData(planet, days)
@ -87,7 +81,13 @@ func TestRollupNoDeletes(t *testing.T) {
}
func TestRollupDeletes(t *testing.T) {
testplanet.Run(t, testplanet.Config{
SatelliteCount: 1, StorageNodeCount: 10, UplinkCount: 0},
SatelliteCount: 1, StorageNodeCount: 10, UplinkCount: 0,
Reconfigure: testplanet.Reconfigure{
Satellite: func(log *zap.Logger, index int, config *satellite.Config) {
config.Rollup.DeleteTallies = true
},
},
},
func(t *testing.T, ctx *testcontext.Context, planet *testplanet.Planet) {
days := 5
testData := createData(planet, days)