-
Notifications
You must be signed in to change notification settings - Fork 522
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chunkserver: fix crc issues #405
Conversation
recheck |
@@ -307,6 +318,10 @@ class CSChunkFile { | |||
return lfs_->Read(fd_, buf, offset + pageSize_, length); | |||
} | |||
|
|||
inline int readMetaData(char* buf, off_t offset, size_t length) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why not use the existing function?
inline int readMetaPage(char* buf) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why not use the existing function?
inline int readMetaPage(char* buf) { ?
done
src/chunkserver/scan_manager.cpp
Outdated
job->taskLock.WRLock(); | ||
job->task.localMap.Clear(); | ||
job->task.followerMap.clear(); | ||
job->task.waitingNum = 3; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's better to use
curve/src/chunkserver/copyset_node.h
Line 284 in c3418be
void ListPeers(std::vector<Peer>* peers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's better to use
curve/src/chunkserver/copyset_node.h
Line 284 in c3418be
void ListPeers(std::vector<Peer>* peers); to get the number of replica rather than hard code 3.
done
request->set_sendscanmaptimeoutms(timeoutMs_); | ||
request->set_sendscanmapretrytimes(retry_); | ||
request->set_sendscanmapretryintervalus(retryIntervalUs_); | ||
if (scanChunkMetaPage) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for scan meta page, you can just set request->set_readmetapage(true)
, ellipsis set_offset
/set_size
and member variable chunkMetaPageSize_
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for scan meta page, you can just set
request->set_readmetapage(true)
, ellipsisset_offset
/set_size
and member variablechunkMetaPageSize_
Although offset and length is not needed in datastore and chunkfile, LOG and build scanmap is need. Otherwise more judgment is needed.
recheck |
9be32d7
to
bfb7ec5
Compare
bfb7ec5
to
e743b93
Compare
* Update README.md
What problem does this PR solve?
Issue Number: close #xxx
Problem Summary:
What is changed and how it works?
What's Changed:
How it Works:
Side effects(Breaking backward compatibility? Performance regression?):
Check List