diff --git a/CHANGELOG.md b/CHANGELOG.md index f5f9725825..a52c72c4f4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ Please mark all change in change log and use the ticket from JIRA. ## Feature ## Improvement +- \#190 - Update default config:use_blas_threshold to 1100 and server version printout to 0.52 ## Task diff --git a/NOTICE.md b/NOTICE.md index 018e2b80e0..fee2f37a7a 100644 --- a/NOTICE.md +++ b/NOTICE.md @@ -8,20 +8,16 @@ | ------------- | ------------------------------------------------------------ | | Apache Arrow | [Apache License 2.0](https://github.com/apache/arrow/blob/master/LICENSE.txt) | | Boost | [Boost Software License](https://github.com/boostorg/boost/blob/master/LICENSE_1_0.txt) | -| BZip2 | [BZip2](http://www.bzip.org/) | | FAISS | [MIT](https://github.com/facebookresearch/faiss/blob/master/LICENSE) | | Gtest | [BSD 3-Clause](https://github.com/google/googletest/blob/master/LICENSE) | | LAPACK | [LAPACK](https://github.com/Reference-LAPACK/lapack/blob/master/LICENSE) | -| LZ4 | [BSD 2-Clause](https://github.com/Blosc/c-blosc/blob/master/LICENSES/LZ4.txt) | | MySQLPP | [LGPL 2.1](https://tangentsoft.com/mysqlpp/artifact/b128a66dab867923) | | OpenBLAS | [BSD 3-Clause](https://github.com/xianyi/OpenBLAS/blob/develop/LICENSE) | | Prometheus | [Apache License 2.0](https://github.com/prometheus/prometheus/blob/master/LICENSE) | -| Snappy | [BSD](https://github.com/google/snappy/blob/master/COPYING) | | SQLite | [Public Domain](https://www.sqlite.org/copyright.html) | | SQLite-ORM | [BSD 3-Clause](https://github.com/fnc12/sqlite_orm/blob/master/LICENSE) | | yaml-cpp | [MIT](https://github.com/jbeder/yaml-cpp/blob/master/LICENSE) | | ZLIB | [ZLIB](http://zlib.net/zlib_license.html) | -| ZSTD | [BSD](https://github.com/facebook/zstd/blob/dev/LICENSE) | | libunwind | [MIT](https://github.com/libunwind/libunwind/blob/master/LICENSE) | | gperftools | [BSD 3-Clause](https://github.com/gperftools/gperftools/blob/master/COPYING) | | grpc | [Apache 2.0](https://github.com/grpc/grpc/blob/master/LICENSE) | diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt index 402e65fb10..7acf3062fa 100644 --- a/core/CMakeLists.txt +++ b/core/CMakeLists.txt @@ -44,7 +44,7 @@ if(NOT GIT_BRANCH_NAME STREQUAL "") string(REGEX REPLACE "\n" "" GIT_BRANCH_NAME ${GIT_BRANCH_NAME}) endif() -set(MILVUS_VERSION "0.5.1") +set(MILVUS_VERSION "${GIT_BRANCH_NAME}") string(REGEX MATCH "[0-9]+\\.[0-9]+\\.[0-9]" MILVUS_VERSION "${MILVUS_VERSION}") find_package(ClangTools) @@ -71,7 +71,7 @@ if(MILVUS_VERSION_MAJOR STREQUAL "" OR MILVUS_VERSION_MINOR STREQUAL "" OR MILVUS_VERSION_PATCH STREQUAL "") message(WARNING "Failed to determine Milvus version from git branch name") - set(MILVUS_VERSION "0.5.0") + set(MILVUS_VERSION "0.5.2") endif() message(STATUS "Build version = ${MILVUS_VERSION}") diff --git a/core/conf/server_config.template b/core/conf/server_config.template index 8dfb30f534..48d29a1096 100644 --- a/core/conf/server_config.template +++ b/core/conf/server_config.template @@ -34,7 +34,7 @@ cache_config: cache_insert_data: false # whether to load inserted data into cache, must be a boolean engine_config: - use_blas_threshold: 20 # if nq < use_blas_threshold, use SSE, faster with fluctuated response times + use_blas_threshold: 1100 # if nq < use_blas_threshold, use SSE, faster with fluctuated response times # if nq >= use_blas_threshold, use OpenBlas, slower with stable response times gpu_search_threshold: 1000 # threshold beyond which the search computation is executed on GPUs only diff --git a/core/src/cache/Cache.h b/core/src/cache/Cache.h index 62a7f13ca8..d3513032b9 100644 --- a/core/src/cache/Cache.h +++ b/core/src/cache/Cache.h @@ -40,12 +40,15 @@ class Cache { return usage_; } + // unit: BYTE int64_t capacity() const { return capacity_; - } // unit: BYTE + } + + // unit: BYTE void - set_capacity(int64_t capacity); // unit: BYTE + set_capacity(int64_t capacity); double freemem_percent() const { @@ -59,16 +62,22 @@ class Cache { size_t size() const; + bool exists(const std::string& key); + ItemObj get(const std::string& key); + void insert(const std::string& key, const ItemObj& item); + void erase(const std::string& key); + void print(); + void clear(); diff --git a/core/src/cache/CacheMgr.h b/core/src/cache/CacheMgr.h index f5e04f6509..f0f8ba952d 100644 --- a/core/src/cache/CacheMgr.h +++ b/core/src/cache/CacheMgr.h @@ -53,13 +53,16 @@ class CacheMgr { int64_t CacheUsage() const; + int64_t CacheCapacity() const; + void SetCapacity(int64_t capacity); protected: CacheMgr(); + virtual ~CacheMgr(); protected: