gavinchou commented on code in PR #40226:
URL: https://github.com/apache/doris/pull/40226#discussion_r1741140492
##########
be/src/io/cache/fs_file_cache_storage.cpp:
##########
@@ -183,29 +209,51 @@ Status FSFileCacheStorage::remove(const FileCacheKey&
key) {
return Status::OK();
}
-Status FSFileCacheStorage::change_key_meta(const FileCacheKey& key, const
KeyMeta& new_meta) {
- // TTL change
- if (key.meta.expiration_time != new_meta.expiration_time) {
+Status FSFileCacheStorage::change_key_meta_type(const FileCacheKey& key, const
FileCacheType type) {
+ // file operation
+ if (key.meta.type != type) {
+ // TTL type file dose not need to change the suffix
+ DCHECK(key.meta.type != FileCacheType::TTL && type !=
FileCacheType::TTL);
+ std::string dir = get_path_in_local_cache(key.hash,
key.meta.expiration_time);
Review Comment:
return error instead of dcheck
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]