mynameborat commented on a change in pull request #915: Consolidating offset
read and write for store-offsets and side-inputs, maintaining backward
compatbility
URL: https://github.com/apache/samza/pull/915#discussion_r255823615
##########
File path:
samza-core/src/test/scala/org/apache/samza/storage/TestTaskStorageManager.scala
##########
@@ -567,6 +566,22 @@ class TestTaskStorageManager extends MockitoSugar {
testChangelogConsumerOffsetRegistration(oldestOffset, newestOffset,
upcomingOffset, expectedRegisteredOffset, fileOffset, writeOffsetFile)
}
+ @Test
+ def testReadOfOldOffsetFormat(): Unit = {
+ // Create a file in old single-offset format, with a sample offset
+ val storeDirectory =
StorageManagerUtil.getStorePartitionDir(TaskStorageManagerBuilder.defaultLoggedStoreBaseDir,
loggedStore, taskName)
+ val storeFile = new File(storeDirectory, "store.sst")
+ val offsetFile = new File(storeDirectory, "OFFSET")
Review comment:
nit: make the offset file name public in the utils and reuse it here?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services