Skip to content

Commit

Permalink
* #2642 Create index failed caused by server crashed.
Browse files Browse the repository at this point in the history
Signed-off-by: yhmo <yihua.mo@zilliz.com>

* changelog

Signed-off-by: yhmo <yihua.mo@zilliz.com>

* changelog

Signed-off-by: yhmo <yihua.mo@zilliz.com>

* typo

Signed-off-by: yhmo <yihua.mo@zilliz.com>

* #2692 Milvus hangs during multi-thread concurrent search

Signed-off-by: yhmo <yihua.mo@zilliz.com>
  • Loading branch information
groot authored and JinHai-CN committed Jul 4, 2020
1 parent 04eb5a8 commit aa549f0
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Please mark all changes in change log and use the issue from GitHub
- \#2642 Create index failed and server crashed
- \#2649 Search parameter of annoy has conflict with document
- \#2690 Remove body parser in show-partitions endpoints
- \#2692 Milvus hangs during multi-thread concurrent search

## Feature
- \#2319 Redo metadata to support MVCC
Expand Down
1 change: 1 addition & 0 deletions core/src/server/delivery/request/BaseRequest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ BaseRequest::OnPostExecute() {

void
BaseRequest::Done() {
std::unique_lock<std::mutex> lock(finish_mtx_);
done_ = true;
finish_cond_.notify_all();
}
Expand Down
9 changes: 5 additions & 4 deletions core/src/server/delivery/request/BaseRequest.h
Original file line number Diff line number Diff line change
Expand Up @@ -215,15 +215,16 @@ class BaseRequest {
protected:
const std::shared_ptr<milvus::server::Context> context_;

mutable std::mutex finish_mtx_;
std::condition_variable finish_cond_;

RequestType type_;
std::string request_group_;
bool async_;
bool done_;
Status status_;

private:
mutable std::mutex finish_mtx_;
std::condition_variable finish_cond_;
bool done_;

public:
const std::shared_ptr<milvus::server::Context>&
Context() const {
Expand Down

0 comments on commit aa549f0

Please sign in to comment.