Skip to content

Open Source alternative to Algolia + Pinecone and an Easier-to-Use alternative to ElasticSearch ⚡ 🔍 ✨ Fast, typo tolerant, in-memory fuzzy Search Engine for building delightful search experiences

Minor logging changes.

Kishore Nallan4d22698cc55d
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 41c4e75d..87761f8b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -40,7 +40,7 @@ include(cmake/H2O.cmake)
include(cmake/RocksDB.cmake)
include(cmake/GoogleTest.cmake)
include(cmake/TestResources.cmake)
-include(cmake/G3log.cmake)
+include(cmake/g3log.cmake)
FILE(GLOB SRC_FILES src/*.cpp)
diff --git a/include/store.h b/include/store.h
index 114b3a20..ae437878 100644
--- a/include/store.h
+++ b/include/store.h
@@ -72,7 +72,7 @@ public:
rocksdb::Status s = rocksdb::DB::Open(options, state_dir_path, &db);
if(!s.ok()) {
- LOG(FATAL) << "Error while initializing store: " << s.ToString();
+ LOG(ERR) << "Error while initializing store: " << s.ToString();
}
assert(s.ok());
diff --git a/src/api.cpp b/src/api.cpp
index 7835276d..b56218a4 100644
--- a/src/api.cpp
+++ b/src/api.cpp
@@ -283,7 +283,7 @@ void get_search(http_req & req, http_res & res) {
res.send_200(req.params[CALLBACK] + "(" + results_json_str + ");");
}
- LOG(INFO) << "Time taken: " << timeMillis << "ms";
+ //LOG(INFO) << "Time taken: " << timeMillis << "ms";
}
void get_collection_summary(http_req & req, http_res & res) {
diff --git a/src/http_server.cpp b/src/http_server.cpp
index cad4b47b..ee830593 100644
--- a/src/http_server.cpp
+++ b/src/http_server.cpp
@@ -70,7 +70,7 @@ int HttpServer::setup_ssl(const char *cert_file, const char *key_file) {
int nid = NID_X9_62_prime256v1;
EC_KEY *key = EC_KEY_new_by_curve_name(nid);
if (key == NULL) {
- LOG(INFO) << "Failed to create DH/ECDH.";
+ LOG(ERR) << "Failed to create DH/ECDH.";
return -1;
}
@@ -82,11 +82,11 @@ int HttpServer::setup_ssl(const char *cert_file, const char *key_file) {
SSL_CTX_set_options(accept_ctx->ssl_ctx, SSL_OP_SINGLE_ECDH_USE);
if (SSL_CTX_use_certificate_chain_file(accept_ctx->ssl_ctx, cert_file) != 1) {
- LOG(INFO) << "An error occurred while trying to load server certificate file:" << cert_file;
+ LOG(ERR) << "An error occurred while trying to load server certificate file:" << cert_file;
return -1;
}
if (SSL_CTX_use_PrivateKey_file(accept_ctx->ssl_ctx, key_file, SSL_FILETYPE_PEM) != 1) {
- LOG(INFO) << "An error occurred while trying to load private key file: " << key_file;
+ LOG(ERR) << "An error occurred while trying to load private key file: " << key_file;
return -1;
}
diff --git a/src/main/benchmark.cpp b/src/main/benchmark.cpp
index 1077b487..a7bdb913 100644
--- a/src/main/benchmark.cpp
+++ b/src/main/benchmark.cpp
@@ -28,7 +28,7 @@ int main(int argc, char* argv[]) {
collection = collectionManager.create_collection("hnstories_direct", fields_to_index, "points").get();
}
- std::ifstream infile("/Users/kishore/Downloads/hnstories.jsonl");
+ std::ifstream infile(argv[1]);
std::string json_line;
auto begin = std::chrono::high_resolution_clock::now();