diff --git a/.gitignore b/.gitignore index 3c4daa6363d91e85f0054e652fa95e6b2436e9de..36faba3e3ead74f955e38248d220178015b04267 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,7 @@ build _build _build.log _install +install bin/ install_manifest.txt diff --git a/conf/nebula-graphd.conf.default b/conf/nebula-graphd.conf.default index d16efcf293101d201378dab72846607011d032bd..65e323573dae36fe113393dd0674d9f2968887f8 100644 --- a/conf/nebula-graphd.conf.default +++ b/conf/nebula-graphd.conf.default @@ -39,7 +39,7 @@ # Seconds before the idle connections are closed, 0 for never closed --client_idle_timeout_secs=0 # Seconds before the idle sessions are expired, 0 for no expiration ---session_idle_timeout_secs=60000 +--session_idle_timeout_secs=0 # The number of threads to accept incoming connections --num_accept_threads=1 # The number of networking IO threads, 0 for # of CPU cores @@ -52,3 +52,15 @@ --ws_http_port=13000 # HTTP2 service port --ws_h2_port=13002 +# The default charset when a space is created +--default_charset=utf8 +# The defaule collate when a space is created +--default_collate=utf8_bin + +########## authorization ########## +# Enable authorization +--enable_authorize=false + +########## Authentication ########## +# User login authentication type, password for nebula authentication, ldap for ldap authentication, cloud for cloud authentication +--auth_type=password diff --git a/conf/nebula-graphd.conf.production b/conf/nebula-graphd.conf.production index f3dc0ffc91e7ff7b62d93b32f033546952bd29d6..892ea4bec95e8c22e41907a6ade34e014ed66749 100644 --- a/conf/nebula-graphd.conf.production +++ b/conf/nebula-graphd.conf.production @@ -53,4 +53,13 @@ # HTTP2 service port --ws_h2_port=13002 ---load_data_interval_secs=120 +# Heartbeat interval of communication between meta client and graphd service +--heartbeat_interval_secs=10 + +########## authorization ########## +# Enable authorization +--enable_authorize=false + +########## authentication ########## +# User login authentication type, password for nebula authentication, ldap for ldap authentication, cloud for cloud authentication +--auth_type=password diff --git a/src/service/GraphFlags.cpp b/src/service/GraphFlags.cpp index a8a358c9e44d58db892b358a1ee0caa34fdeae13..f72ee4a4b7a7dde9a709a627530beb65f2ab0394 100644 --- a/src/service/GraphFlags.cpp +++ b/src/service/GraphFlags.cpp @@ -12,7 +12,7 @@ DEFINE_int32(client_idle_timeout_secs, 0, "Seconds before we close the idle connections, 0 for infinite"); DEFINE_int32(session_idle_timeout_secs, - 600, + 0, "Seconds before we expire the idle sessions, 0 for infinite"); DEFINE_int32(session_reclaim_interval_secs, 10, "Period we try to reclaim expired sessions"); DEFINE_int32(num_netio_threads, diff --git a/src/service/SessionManager.cpp b/src/service/SessionManager.cpp index 0015eaa163a144872f648cad8456eb5c06726fe5..e6f78a054fbddaa571efdc43663388fd32790f1b 100644 --- a/src/service/SessionManager.cpp +++ b/src/service/SessionManager.cpp @@ -81,6 +81,9 @@ int64_t SessionManager::newSessionId() { // TODO(dutor) Now we do a brute-force scanning, of course we could make it more efficient. void SessionManager::reclaimExpiredSessions() { + if (FLAGS_session_idle_timeout_secs == 0) { + return; + } folly::RWSpinLock::WriteHolder holder(rwlock_); if (activeSessions_.empty()) { return;