Skip to content
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

Setting for TCP keepalive. [CLICKHOUSE-1834] #3441

Merged
merged 2 commits into from
Oct 23, 2018
Merged

Setting for TCP keepalive. [CLICKHOUSE-1834] #3441

merged 2 commits into from
Oct 23, 2018

Conversation

CurtizJ
Copy link
Member

@CurtizJ CurtizJ commented Oct 22, 2018

I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/?lang=en

@alexey-milovidov
Copy link
Member

Let's rename keep_alive_timeout to tcp_keep_alive_timeout everywhere to avoid potential confusion with HTTP Keep-Alive.

@@ -49,6 +49,7 @@ struct Settings
M(SettingMilliseconds, connect_timeout_with_failover_ms, DBMS_DEFAULT_CONNECT_TIMEOUT_WITH_FAILOVER_MS, "Connection timeout for selecting first healthy replica.") \
M(SettingSeconds, receive_timeout, DBMS_DEFAULT_RECEIVE_TIMEOUT_SEC, "") \
M(SettingSeconds, send_timeout, DBMS_DEFAULT_SEND_TIMEOUT_SEC, "") \
M(SettingSeconds, tcp_keep_alive_timeout, 0, "") \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing documentation.

@alexey-milovidov alexey-milovidov merged commit 10abde5 into ClickHouse:master Oct 23, 2018
@proller
Copy link
Contributor

proller commented Oct 24, 2018

this brokes macos build:

FAILED: dbms/CMakeFiles/dbms.dir/src/Client/Connection.cpp.o 
/usr/local/bin/ccache /usr/local/bin/g++-8  -DBOOST_SYSTEM_NO_DEPRECATED -DLZ4_DISABLE_DEPRECATE_WARNINGS=1 -DPOCO_STATIC -DPOCO_UNBUNDLED_ZLIB -DUNALIGNED_OK -DWITH_GZFILEOP -DX86_64 -DZLIB_COMPAT -isystem ../contrib/libsparsehash -isystem ../contrib/libdivide -isystem ../contrib/poco/Data/include -isystem /usr/local/include -I../dbms/src -Idbms/src -isystem ../contrib/double-conversion -isystem ../contrib/libpcg-random/include -I../contrib/cityhash102/include -I../libs/libcommon/include -Ilibs/libcommon/include -I../libs/libpocoext/include -isystem ../contrib/poco/Foundation/include -I../contrib/zlib-ng -Icontrib/zlib-ng -I../contrib/cctz/include -isystem ../contrib/boost -I../libs/libwidechar_width -isystem ../contrib/libcpuid/include -I../contrib/lz4/lib -I../contrib/zstd/lib -isystem ../contrib/poco/Net/include -isystem ../contrib/poco/Util/include -isystem ../contrib/poco/XML/include -isystem ../contrib/poco/JSON/include -isystem ../contrib/poco/NetSSL_OpenSSL/include -isystem ../contrib/poco/Crypto/include -isystem ../contrib/ssl/include -isystem contrib/re2_st -isystem ../contrib/re2 -I../contrib/libbtrie/include -isystem ../contrib/poco/MongoDB/include -I../contrib/capnproto/c++/src -I../contrib/capnproto/c++/src/capnp/.. -I../contrib/capnproto/c++/src/kj/.. -fdiagnostics-color=always  -pipe -msse4.1 -msse4.2 -mpopcnt  -fno-omit-frame-pointer  -Wall  -Wnon-virtual-dtor -Wextra -Werror -O3 -DNDEBUG   -fno-tree-loop-distribute-patterns -std=c++1z -MD -MT dbms/CMakeFiles/dbms.dir/src/Client/Connection.cpp.o -MF dbms/CMakeFiles/dbms.dir/src/Client/Connection.cpp.o.d -o dbms/CMakeFiles/dbms.dir/src/Client/Connection.cpp.o -c ../dbms/src/Client/Connection.cpp
../dbms/src/Client/Connection.cpp: In member function 'void DB::Connection::connect()':
../dbms/src/Client/Connection.cpp:83:31: error: 'SOL_TCP' was not declared in this scope
             socket->setOption(SOL_TCP, TCP_KEEPIDLE, timeouts.tcp_keep_alive_timeout);
                               ^~~~~~~
../dbms/src/Client/Connection.cpp:83:40: error: 'TCP_KEEPIDLE' was not declared in this scope
             socket->setOption(SOL_TCP, TCP_KEEPIDLE, timeouts.tcp_keep_alive_timeout);
                                        ^~~~~~~~~~~~
../dbms/src/Client/Connection.cpp:83:40: note: suggested alternative: 'OCSP_RESPID'
             socket->setOption(SOL_TCP, TCP_KEEPIDLE, timeouts.tcp_keep_alive_timeout);
                                        ^~~~~~~~~~~~
                                        OCSP_RESPID

@jackpgao
Copy link

@morsik
Copy link

morsik commented Oct 18, 2024

Apparently this doesn't actually work? :/

#63659

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants