rpc_addr | http_addr c++
emaxerrno opened this issue · comments
Alexander Gallego commented
the rpc_server should have 2 seastar::ipv4_addr structs, one for http and one for rpc.
There should be no implicit addr 's in codebase. i.e.: :::0
Alexander Gallego commented
ugh. this would be a breaking change :'(
Noah Watkins commented
replace http_port and rpc_port in server_args with ipv4_addrs?
Alexander Gallego commented
yeah something like this
namespace smf {
enum class rpc_server_bitflags : uint32_t { disable_http_server = 1 };
struct rpc_server_args {
seastar::ipv4_addr http;
seastar::ipv4_addr rpc;
/// \brief see enum rpc_server_flags
uint32_t bitflags = 0;
/// \ brief The default timeout PER connection body. After we parse the
/// header of the connection we need to make sure that we at some point
/// receive some bytes or expire the connection.
///
typename seastar::timer<>::duration recv_timeout = std::chrono::minutes(1);
/// \brief 4GB usually. After this limit, each connection to this
/// server-core will block until there are enough bytes free in memory to
/// continue
///
uint64_t memory_avail_per_core = uint64_t(1) << 31 /*2GB per core*/;
// i.e.: /proc/sys/net/ipv4/tcp_keepalive_time
int32_t keepalive_idle_secs = 5;
// i.e: /proc/sys/net/ipv4/tcp_keepalive_intvl
int32_t keepalive_interval_secs = 75;
// i.e: /proc/sys/net/ipv4/tcp_keepalive_probes
int32_t keepalive_prob_count = 9;
bool nodelay = true;
bool enable_keepalive = true;
};
Alexander Gallego commented
this will also solve the problem that @nacl was suggesting w/ idl secs & keep alive.
just about threading those through and through.
Alexander Gallego commented
#118 - i think was this.
Alexander Gallego commented
err this: #335