@@ -2821,7 +2821,7 @@ func TestIngester_sholdUpdateCacheShippedBlocks(t *testing.T) {
2821
2821
require .Equal (t , len (db .getCachedShippedBlocks ()), 0 )
2822
2822
shippedBlock , _ := ulid .Parse ("01D78XZ44G0000000000000000" )
2823
2823
2824
- require .NoError (t , shipper .WriteMetaFile (log .NewNopLogger (), db .db . Dir () , & shipper.Meta {
2824
+ require .NoError (t , shipper .WriteMetaFile (log .NewNopLogger (), db .shipperMetadataFilePath , & shipper.Meta {
2825
2825
Version : shipper .MetaVersion1 ,
2826
2826
Uploaded : []ulid.ULID {shippedBlock },
2827
2827
}))
@@ -2858,7 +2858,7 @@ func TestIngester_closeAndDeleteUserTSDBIfIdle_shouldNotCloseTSDBIfShippingIsInP
2858
2858
2859
2859
// Mock the shipper meta (no blocks).
2860
2860
db := i .getTSDB (userID )
2861
- require .NoError (t , shipper .WriteMetaFile (log .NewNopLogger (), db .db . Dir () , & shipper.Meta {
2861
+ require .NoError (t , shipper .WriteMetaFile (log .NewNopLogger (), db .shipperMetadataFilePath , & shipper.Meta {
2862
2862
Version : shipper .MetaVersion1 ,
2863
2863
}))
2864
2864
@@ -3788,7 +3788,7 @@ func TestIngesterNotDeleteUnshippedBlocks(t *testing.T) {
3788
3788
` , oldBlocks [0 ].Meta ().ULID .Time ()/ 1000 )), "cortex_ingester_oldest_unshipped_block_timestamp_seconds" ))
3789
3789
3790
3790
// Saying that we have shipped the second block, so only that should get deleted.
3791
- require .Nil (t , shipper .WriteMetaFile (nil , db .db . Dir () , & shipper.Meta {
3791
+ require .Nil (t , shipper .WriteMetaFile (nil , db .shipperMetadataFilePath , & shipper.Meta {
3792
3792
Version : shipper .MetaVersion1 ,
3793
3793
Uploaded : []ulid.ULID {oldBlocks [1 ].Meta ().ULID },
3794
3794
}))
@@ -3816,7 +3816,7 @@ func TestIngesterNotDeleteUnshippedBlocks(t *testing.T) {
3816
3816
` , newBlocks [0 ].Meta ().ULID .Time ()/ 1000 )), "cortex_ingester_oldest_unshipped_block_timestamp_seconds" ))
3817
3817
3818
3818
// Shipping 2 more blocks, hence all the blocks from first round.
3819
- require .Nil (t , shipper .WriteMetaFile (nil , db .db . Dir () , & shipper.Meta {
3819
+ require .Nil (t , shipper .WriteMetaFile (nil , db .shipperMetadataFilePath , & shipper.Meta {
3820
3820
Version : shipper .MetaVersion1 ,
3821
3821
Uploaded : []ulid.ULID {oldBlocks [1 ].Meta ().ULID , newBlocks [0 ].Meta ().ULID , newBlocks [1 ].Meta ().ULID },
3822
3822
}))
0 commit comments