acelyc111 commented on code in PR #1132: URL: https://github.com/apache/incubator-pegasus/pull/1132#discussion_r952119615
########## src/server/config.ini: ########## @@ -94,6 +94,7 @@ io_service_worker_count = 4 ; how many connections can be established from one ip address to a server(both replica and meta), 0 means no threshold conn_threshold_per_ip = 0 + enable_udp = false Review Comment: UDP is enabled before, the default value would better to be `true` to keep compatiblity, you can define it what ever you like in your own envs. ########## src/server/config.ini: ########## @@ -708,12 +709,10 @@ [task.RPC_FD_FAILURE_DETECTOR_PING] rpc_call_header_format = NET_HDR_DSN - rpc_call_channel = RPC_CHANNEL_UDP Review Comment: same, not remove it. ########## src/rdsn/src/runtime/nativerun.cpp: ########## @@ -59,19 +60,22 @@ void nativerun::install(service_spec &spec) cs2.message_buffer_block_size = 1024 * 64; spec.network_default_server_cfs[cs2] = cs2; } - { - network_client_config cs; - cs.factory_name = "dsn::tools::asio_udp_provider"; - cs.message_buffer_block_size = 1024 * 64; - spec.network_default_client_cfs[RPC_CHANNEL_UDP] = cs; - } - { - network_server_config cs2; - cs2.port = 0; - cs2.channel = RPC_CHANNEL_UDP; - cs2.factory_name = "dsn::tools::asio_udp_provider"; - cs2.message_buffer_block_size = 1024 * 64; - spec.network_default_server_cfs[cs2] = cs2; + if (dsn_config_get_value_bool( Review Comment: use the recommend new style DSN_DECLARE_bool, FLAGS_enable_udp ########## src/rdsn/src/runtime/providers.common.cpp: ########## @@ -64,8 +64,11 @@ void register_common_providers() register_std_lock_providers(); + if (dsn_config_get_value_bool( Review Comment: use the new config framework `DSN_DEFINE_bool(...)` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: dev-unsubscr...@pegasus.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@pegasus.apache.org For additional commands, e-mail: dev-h...@pegasus.apache.org