-
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
client supports mounting volumes in different clusters #2542
Conversation
348d3c0
to
c9c118b
Compare
@@ -60,7 +60,7 @@ class FileNameParser { | |||
* @param[in] fileName | |||
* @return 解析出的字符串: "/cinder/volume-6f30d296-07f7-452e-a983-513191f8cd95_cinder_" //NOLINT | |||
*/ | |||
static std::string Parse(const std::string& fileName); | |||
static std::pair<std::string,std::string> Parse(const std::string& fileName); |
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.
modify the code comment and show the format after this update.
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.
fixed
src/client/libcurve_file.cpp
Outdated
@@ -219,8 +219,22 @@ void FileClient::UnInit() { | |||
int FileClient::Open(const std::string &filename, const UserInfo_t &userinfo, | |||
const OpenFlags &openflags) { | |||
LOG(INFO) << "Opening filename: " << filename << ", flags: " << openflags; | |||
ClientConfig clientconfig; |
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.
chaneg clientconfig to clientConfig
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.
done
* @param: finfo是出参,携带当前文件的基础信息 | ||
* @return: 成功返回int::OK,否则返回小于0的错误码 | ||
*/ | ||
virtual int StatFile(int fd, FileStatInfo* finfo); |
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.
change to English
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.
done
c9c118b
to
b1907c5
Compare
src/client/libcurve_file.h
Outdated
@@ -294,6 +302,8 @@ class FileClient { | |||
} | |||
|
|||
private: | |||
void BuildFileStatInfo(FInfo_t fi, FileStatInfo *finfo); |
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.
void BuildFileStatInfo(FInfo_t fi, FileStatInfo *finfo); | |
static void BuildFileStatInfo(const FInfo& fi, FileStatInfo *finfo); |
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.
done
@@ -34,50 +34,53 @@ using ::curve::client::UserInfo_t; | |||
const char* kSessionAttrKey = "session"; | |||
const char* kOpenFlagsAttrKey = "openflags"; | |||
|
|||
curve::client::OpenFlags ConverToCurveOpenFlags(const OpenFlags* flags) { | |||
curve::client::OpenFlags ConverToCurveOpenFlags(const OpenFlags* flags, const std::string& confPath) { |
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.
column limit is 80
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.
done
return curveflags; | ||
} | ||
} | ||
|
||
std::string FileNameParser::Parse(const std::string& fileName) { | ||
std::pair<std::string, std::string> FileNameParser::Parse(const std::string& fileName) { |
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.
ditto
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.
done
b1907c5
to
0cc9556
Compare
cicheck |
1 similar comment
cicheck |
47f9659
to
c2e2ebe
Compare
cicheck |
1c9672f
to
e874bed
Compare
cicheck |
a3c69cf
to
89a25fd
Compare
cicheck |
2 similar comments
cicheck |
cicheck |
89a25fd
to
6af4adb
Compare
cicheck |
cicheck |
1 similar comment
cicheck |
1d2aa58
to
3fef782
Compare
cicheck |
Signed-off-by: caoxianfei1 <caoxianfei@corp.netease.com>
3fef782
to
cc672f7
Compare
cicheck |
What problem does this PR solve?
Issue Number: #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