// EnableSharding enable sharding on collection of the day
EnableSharding enable sharding on collection of the day
// EnableSharding enable sharding on collection of the day
func (d *MongoDB) EnableSharding(t time.Time) error {
	return d.DB.Run(bson.D{
		{
			Name:  "shardCollection",
			Value: d.DB.Name + "." + d.CollectionName(t),
		},
		{
			Name:  "key",
			Value: bson.M{"timestamp": "hashed"},
		},
	}, nil)
}
func ( d * MongoDB ) EnableSharding ( t time . Time ) error { return d . DB . Run ( bson . D { { Name : " " , Value : d . DB . Name + " " + d . CollectionName ( t ) , } , { Name : " " , Value : bson . M { " " : " " } , } , } , nil ) }
EnableSharding enable sharding on collection of the day
EnableSharding enable sharding on collection of the day