Skip to content

Commit

Permalink
[BugFix] Fix uncorrect new path for GIN file after restore
Browse files Browse the repository at this point in the history
This pr is very similar with pr(StarRocks#44957). In StarRocks#44957, we fix
the problem for download procedure. In this pr, we fix the
problem for rename procedure for restore.

Signed-off-by: srlch <linzichao@starrocks.com>
  • Loading branch information
srlch committed Apr 30, 2024
1 parent 3ade3a3 commit 728f2c3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions be/src/storage/snapshot_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -210,8 +210,7 @@ Status SnapshotManager::convert_rowset_ids(const string& clone_dir, int64_t tabl
file.find(".fnm", 0) != std::string::npos || file.find(".frq", 0) != std::string::npos ||
file.find(".nrm", 0) != std::string::npos || file.find(".prx", 0) != std::string::npos ||
file.find(".tii", 0) != std::string::npos || file.find(".tis", 0) != std::string::npos ||
file.find("null_bitmap", 0) != std::string::npos || file.find("segments_2", 0) != std::string::npos ||
file.find("segments.gen", 0) != std::string::npos) {
file.find("null_bitmap", 0) != std::string::npos || file.find("segments", 0) != std::string::npos) {
auto* p1 = (char*)std::memchr(file.data(), '_', file.size());
auto* p2 = (char*)std::memchr(p1 + 1, '_', file.size() - (p1 - file.data() + 1));
auto* p3 = (char*)std::memchr(p2 + 1, '_', file.size() - (p2 - file.data() + 1));
Expand Down

0 comments on commit 728f2c3

Please sign in to comment.