grpc 1.65.0 → 1.65.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (66) hide show
  1. checksums.yaml +4 -4
  2. data/Makefile +1 -1
  3. data/src/core/client_channel/subchannel.cc +10 -7
  4. data/src/core/ext/transport/chttp2/client/chttp2_connector.cc +3 -1
  5. data/src/core/ext/transport/chttp2/transport/chttp2_transport.cc +6 -6
  6. data/src/core/ext/transport/inproc/inproc_transport.cc +2 -2
  7. data/src/core/handshaker/http_connect/http_connect_handshaker.cc +2 -2
  8. data/src/core/handshaker/http_connect/http_proxy_mapper.cc +7 -10
  9. data/src/core/lib/compression/message_compress.cc +3 -3
  10. data/src/core/lib/event_engine/posix_engine/ev_epoll1_linux.cc +2 -1
  11. data/src/core/lib/event_engine/posix_engine/posix_endpoint.cc +3 -3
  12. data/src/core/lib/event_engine/posix_engine/posix_endpoint.h +1 -1
  13. data/src/core/lib/event_engine/posix_engine/posix_engine_listener_utils.cc +6 -6
  14. data/src/core/lib/event_engine/posix_engine/tcp_socket_utils.cc +12 -6
  15. data/src/core/lib/event_engine/thread_pool/work_stealing_thread_pool.cc +3 -2
  16. data/src/core/lib/event_engine/windows/win_socket.cc +4 -2
  17. data/src/core/lib/event_engine/windows/windows_endpoint.cc +5 -4
  18. data/src/core/lib/experiments/config.cc +11 -9
  19. data/src/core/lib/experiments/experiments.cc +1 -1
  20. data/src/core/lib/experiments/experiments.h +1 -2
  21. data/src/core/lib/gprpp/dual_ref_counted.h +30 -30
  22. data/src/core/lib/iomgr/endpoint_pair_windows.cc +4 -4
  23. data/src/core/lib/iomgr/ev_epoll1_linux.cc +1 -1
  24. data/src/core/lib/iomgr/socket_utils_common_posix.cc +16 -17
  25. data/src/core/lib/iomgr/socket_windows.cc +3 -3
  26. data/src/core/lib/iomgr/tcp_posix.cc +2 -2
  27. data/src/core/lib/iomgr/tcp_server_posix.cc +9 -12
  28. data/src/core/lib/iomgr/tcp_server_windows.cc +2 -2
  29. data/src/core/lib/promise/party.cc +4 -4
  30. data/src/core/lib/security/security_connector/tls/tls_security_connector.cc +2 -2
  31. data/src/core/load_balancing/grpclb/grpclb.cc +14 -15
  32. data/src/core/server/server.cc +1 -1
  33. data/src/core/util/log.cc +10 -8
  34. data/src/ruby/lib/grpc/version.rb +1 -1
  35. data/third_party/boringssl-with-bazel/src/crypto/bytestring/cbs.c +3 -5
  36. data/third_party/boringssl-with-bazel/src/crypto/cipher_extra/e_chacha20poly1305.c +7 -0
  37. data/third_party/boringssl-with-bazel/src/crypto/cpu_arm_linux.c +4 -1
  38. data/third_party/boringssl-with-bazel/src/crypto/cpu_intel.c +0 -15
  39. data/third_party/boringssl-with-bazel/src/crypto/crypto.c +7 -61
  40. data/third_party/boringssl-with-bazel/src/crypto/dilithium/dilithium.c +43 -1
  41. data/third_party/boringssl-with-bazel/src/crypto/fipsmodule/aes/aes.c +21 -0
  42. data/third_party/boringssl-with-bazel/src/crypto/fipsmodule/aes/internal.h +31 -7
  43. data/third_party/boringssl-with-bazel/src/crypto/fipsmodule/bcm.c +0 -2
  44. data/third_party/boringssl-with-bazel/src/crypto/fipsmodule/ec/p256-nistz.c +5 -0
  45. data/third_party/boringssl-with-bazel/src/crypto/fipsmodule/self_check/fips.c +6 -4
  46. data/third_party/boringssl-with-bazel/src/crypto/internal.h +22 -10
  47. data/third_party/boringssl-with-bazel/src/crypto/kyber/kyber.c +1 -0
  48. data/third_party/boringssl-with-bazel/src/include/openssl/crypto.h +6 -11
  49. data/third_party/boringssl-with-bazel/src/include/openssl/experimental/dilithium.h +6 -0
  50. data/third_party/boringssl-with-bazel/src/include/openssl/experimental/kyber.h +10 -0
  51. data/third_party/boringssl-with-bazel/src/include/openssl/span.h +26 -12
  52. data/third_party/boringssl-with-bazel/src/include/openssl/ssl.h +83 -33
  53. data/third_party/boringssl-with-bazel/src/ssl/d1_both.cc +6 -8
  54. data/third_party/boringssl-with-bazel/src/ssl/d1_pkt.cc +4 -4
  55. data/third_party/boringssl-with-bazel/src/ssl/dtls_record.cc +14 -13
  56. data/third_party/boringssl-with-bazel/src/ssl/extensions.cc +22 -16
  57. data/third_party/boringssl-with-bazel/src/ssl/handshake_client.cc +2 -1
  58. data/third_party/boringssl-with-bazel/src/ssl/handshake_server.cc +2 -1
  59. data/third_party/boringssl-with-bazel/src/ssl/internal.h +15 -15
  60. data/third_party/boringssl-with-bazel/src/ssl/ssl_key_share.cc +1 -0
  61. data/third_party/boringssl-with-bazel/src/ssl/ssl_lib.cc +38 -27
  62. data/third_party/boringssl-with-bazel/src/ssl/ssl_privkey.cc +59 -20
  63. data/third_party/boringssl-with-bazel/src/ssl/ssl_versions.cc +1 -1
  64. data/third_party/boringssl-with-bazel/src/ssl/tls13_both.cc +2 -1
  65. data/third_party/boringssl-with-bazel/src/ssl/tls_record.cc +1 -1
  66. metadata +3 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 61336feda513285da8764e06e3d85c83ad801afbecec8c71d2d7fd1d80dcde69
4
- data.tar.gz: a26e0c5d13589d8f218b4b5f50e72b8c00bce163942714475030e815745bc7e4
3
+ metadata.gz: 0f7fb00b001baa72da1610e37b806197d5be662256faa1fe7b48a6f7f5c27017
4
+ data.tar.gz: b36119a3b270a2a66827949490d9e708ac3df7abbbb55dc74e55ea6bc3157f58
5
5
  SHA512:
6
- metadata.gz: 1109d522211ac31b0c0a713cf9008425320639161243c1b9e452dca00cc825b539a5600dc40770a8810ecc31b31c5b4b5a2b1079f91f3e8eb72ef7d390b8a475
7
- data.tar.gz: 52c87db782a5c5cec3c19f6ea9267cf01bcf7dabcccc23fb30beb960dd4d00a3aac74462ebfd373188a1776360503a1dd34ad1665b67afb1a0188895c4cc98f7
6
+ metadata.gz: 55ff653a9ed98a3d3122ca80187d6a8897e40b998bd0ad6e68007244939a789fb9f11733784018456e312120c75926530936bc897980aa9dde6485fa1da37ed4
7
+ data.tar.gz: a20230c8357f4909d26c4f92818d4caa276660b8ee6d668b41c58fe835da6fca97ba75f9a1c98e569c62f699c8acbcddf4c50382a38695b5dbc69188ad07dbcd
data/Makefile CHANGED
@@ -368,7 +368,7 @@ Q = @
368
368
  endif
369
369
 
370
370
  CORE_VERSION = 42.0.0
371
- CPP_VERSION = 1.65.0
371
+ CPP_VERSION = 1.65.2
372
372
 
373
373
  CPPFLAGS_NO_ARCH += $(addprefix -I, $(INCLUDES)) $(addprefix -D, $(DEFINES))
374
374
  CPPFLAGS += $(CPPFLAGS_NO_ARCH) $(ARCH_FLAGS)
@@ -758,8 +758,10 @@ void Subchannel::OnRetryTimer() {
758
758
 
759
759
  void Subchannel::OnRetryTimerLocked() {
760
760
  if (shutdown_) return;
761
- gpr_log(GPR_INFO, "subchannel %p %s: backoff delay elapsed, reporting IDLE",
762
- this, key_.ToString().c_str());
761
+ if (GRPC_TRACE_FLAG_ENABLED(subchannel)) {
762
+ LOG(INFO) << "subchannel " << this << " " << key_.ToString()
763
+ << ": backoff delay elapsed, reporting IDLE";
764
+ }
763
765
  SetConnectivityStateLocked(GRPC_CHANNEL_IDLE, absl::OkStatus());
764
766
  }
765
767
 
@@ -803,11 +805,12 @@ void Subchannel::OnConnectingFinishedLocked(grpc_error_handle error) {
803
805
  if (connecting_result_.transport == nullptr || !PublishTransportLocked()) {
804
806
  const Duration time_until_next_attempt =
805
807
  next_attempt_time_ - Timestamp::Now();
806
- gpr_log(GPR_INFO,
807
- "subchannel %p %s: connect failed (%s), backing off for %" PRId64
808
- " ms",
809
- this, key_.ToString().c_str(), StatusToString(error).c_str(),
810
- time_until_next_attempt.millis());
808
+ if (GRPC_TRACE_FLAG_ENABLED(subchannel)) {
809
+ LOG(INFO) << "subchannel " << this << " " << key_.ToString()
810
+ << ": connect failed (" << StatusToString(error)
811
+ << "), backing off for " << time_until_next_attempt.millis()
812
+ << " ms";
813
+ }
811
814
  SetConnectivityStateLocked(GRPC_CHANNEL_TRANSIENT_FAILURE,
812
815
  grpc_error_to_absl_status(error));
813
816
  retry_timer_handle_ = event_engine_->RunAfter(
@@ -168,10 +168,12 @@ void Chttp2Connector::OnHandshakeDone(void* arg, grpc_error_handle error) {
168
168
  &self->on_receive_settings_, self->args_.interested_parties, nullptr);
169
169
  self->timer_handle_ = self->event_engine_->RunAfter(
170
170
  self->args_.deadline - Timestamp::Now(),
171
- [self = self->RefAsSubclass<Chttp2Connector>()] {
171
+ [self = self->RefAsSubclass<Chttp2Connector>()]() mutable {
172
172
  ApplicationCallbackExecCtx callback_exec_ctx;
173
173
  ExecCtx exec_ctx;
174
174
  self->OnTimeout();
175
+ // Ensure the Chttp2Connector is deleted under an ExecCtx.
176
+ self.reset();
175
177
  });
176
178
  } else {
177
179
  // If the handshaking succeeded but there is no endpoint, then the
@@ -1735,8 +1735,8 @@ void grpc_chttp2_keepalive_timeout(
1735
1735
  grpc_core::RefCountedPtr<grpc_chttp2_transport> t) {
1736
1736
  t->combiner->Run(
1737
1737
  grpc_core::NewClosure([t](grpc_error_handle) {
1738
- gpr_log(GPR_INFO, "%s: Keepalive timeout. Closing transport.",
1739
- std::string(t->peer_string.as_string_view()).c_str());
1738
+ GRPC_TRACE_LOG(http, INFO) << t->peer_string.as_string_view()
1739
+ << ": Keepalive timeout. Closing transport.";
1740
1740
  send_goaway(
1741
1741
  t.get(),
1742
1742
  grpc_error_set_int(GRPC_ERROR_CREATE("keepalive_timeout"),
@@ -1756,8 +1756,8 @@ void grpc_chttp2_ping_timeout(
1756
1756
  grpc_core::RefCountedPtr<grpc_chttp2_transport> t) {
1757
1757
  t->combiner->Run(
1758
1758
  grpc_core::NewClosure([t](grpc_error_handle) {
1759
- gpr_log(GPR_INFO, "%s: Ping timeout. Closing transport.",
1760
- std::string(t->peer_string.as_string_view()).c_str());
1759
+ GRPC_TRACE_LOG(http, INFO) << t->peer_string.as_string_view()
1760
+ << ": Ping timeout. Closing transport.";
1761
1761
  send_goaway(
1762
1762
  t.get(),
1763
1763
  grpc_error_set_int(GRPC_ERROR_CREATE("ping_timeout"),
@@ -1777,8 +1777,8 @@ void grpc_chttp2_settings_timeout(
1777
1777
  grpc_core::RefCountedPtr<grpc_chttp2_transport> t) {
1778
1778
  t->combiner->Run(
1779
1779
  grpc_core::NewClosure([t](grpc_error_handle) {
1780
- gpr_log(GPR_INFO, "%s: Settings timeout. Closing transport.",
1781
- std::string(t->peer_string.as_string_view()).c_str());
1780
+ GRPC_TRACE_LOG(http, INFO) << t->peer_string.as_string_view()
1781
+ << ": Settings timeout. Closing transport.";
1782
1782
  send_goaway(
1783
1783
  t.get(),
1784
1784
  grpc_error_set_int(GRPC_ERROR_CREATE("settings_timeout"),
@@ -70,8 +70,8 @@ class InprocServerTransport final : public ServerTransport {
70
70
  void SetPollset(grpc_stream*, grpc_pollset*) override {}
71
71
  void SetPollsetSet(grpc_stream*, grpc_pollset_set*) override {}
72
72
  void PerformOp(grpc_transport_op* op) override {
73
- gpr_log(GPR_INFO, "inproc server op: %s",
74
- grpc_transport_op_string(op).c_str());
73
+ GRPC_TRACE_LOG(inproc, INFO)
74
+ << "inproc server op: " << grpc_transport_op_string(op);
75
75
  if (op->start_connectivity_watch != nullptr) {
76
76
  MutexLock lock(&state_tracker_mu_);
77
77
  state_tracker_.AddWatcher(op->start_connectivity_watch_state,
@@ -330,8 +330,8 @@ void HttpConnectHandshaker::DoHandshake(grpc_tcp_server_acceptor* /*acceptor*/,
330
330
  // Log connection via proxy.
331
331
  std::string proxy_name(grpc_endpoint_get_peer(args->endpoint));
332
332
  std::string server_name_string(*server_name);
333
- gpr_log(GPR_INFO, "Connecting to server %s via HTTP proxy %s",
334
- server_name_string.c_str(), proxy_name.c_str());
333
+ VLOG(2) << "Connecting to server " << server_name_string << " via HTTP proxy "
334
+ << proxy_name;
335
335
  // Construct HTTP CONNECT request.
336
336
  grpc_http_request request;
337
337
  request.method = const_cast<char*>("CONNECT");
@@ -220,13 +220,11 @@ absl::optional<std::string> HttpProxyMapper::MapName(
220
220
  return absl::nullopt;
221
221
  }
222
222
  if (uri->scheme() == "unix") {
223
- gpr_log(GPR_INFO, "not using proxy for Unix domain socket '%s'",
224
- std::string(server_uri).c_str());
223
+ VLOG(2) << "not using proxy for Unix domain socket '" << server_uri << "'";
225
224
  return absl::nullopt;
226
225
  }
227
226
  if (uri->scheme() == "vsock") {
228
- gpr_log(GPR_INFO, "not using proxy for VSock '%s'",
229
- std::string(server_uri).c_str());
227
+ VLOG(2) << "not using proxy for VSock '" << server_uri << "'";
230
228
  return absl::nullopt;
231
229
  }
232
230
  // Prefer using 'no_grpc_proxy'. Fallback on 'no_proxy' if it is not set.
@@ -239,18 +237,17 @@ absl::optional<std::string> HttpProxyMapper::MapName(
239
237
  std::string server_port;
240
238
  if (!SplitHostPort(absl::StripPrefix(uri->path(), "/"), &server_host,
241
239
  &server_port)) {
242
- gpr_log(GPR_INFO,
243
- "unable to split host and port, not checking no_proxy list for "
244
- "host '%s'",
245
- std::string(server_uri).c_str());
240
+ VLOG(2) << "unable to split host and port, not checking no_proxy list "
241
+ "for host '"
242
+ << server_uri << "'";
246
243
  } else {
247
244
  auto address = StringToSockaddr(server_host, 0);
248
245
  if (AddressIncluded(address.ok()
249
246
  ? absl::optional<grpc_resolved_address>(*address)
250
247
  : absl::nullopt,
251
248
  server_host, *no_proxy_str)) {
252
- gpr_log(GPR_INFO, "not using proxy for host in no_proxy list '%s'",
253
- std::string(server_uri).c_str());
249
+ VLOG(2) << "not using proxy for host in no_proxy list '" << server_uri
250
+ << "'";
254
251
  return absl::nullopt;
255
252
  }
256
253
  }
@@ -62,17 +62,17 @@ static int zlib_body(z_stream* zs, grpc_slice_buffer* input,
62
62
  }
63
63
  r = flate(zs, flush);
64
64
  if (r < 0 && r != Z_BUF_ERROR /* not fatal */) {
65
- LOG(INFO) << "zlib error (" << r << ")";
65
+ VLOG(2) << "zlib error (" << r << ")";
66
66
  goto error;
67
67
  }
68
68
  } while (zs->avail_out == 0);
69
69
  if (zs->avail_in) {
70
- LOG(INFO) << "zlib: not all input consumed";
70
+ VLOG(2) << "zlib: not all input consumed";
71
71
  goto error;
72
72
  }
73
73
  }
74
74
  if (r != Z_STREAM_END) {
75
- LOG(INFO) << "zlib: Data error";
75
+ VLOG(2) << "zlib: Data error";
76
76
  goto error;
77
77
  }
78
78
 
@@ -356,7 +356,8 @@ Epoll1Poller::Epoll1Poller(Scheduler* scheduler)
356
356
  wakeup_fd_ = *CreateWakeupFd();
357
357
  CHECK(wakeup_fd_ != nullptr);
358
358
  CHECK_GE(g_epoll_set_.epfd, 0);
359
- LOG(INFO) << "grpc epoll fd: " << g_epoll_set_.epfd;
359
+ GRPC_TRACE_LOG(event_engine_poller, INFO)
360
+ << "grpc epoll fd: " << g_epoll_set_.epfd;
360
361
  struct epoll_event ev;
361
362
  ev.events = static_cast<uint32_t>(EPOLLIN | EPOLLET);
362
363
  ev.data.ptr = wakeup_fd_.get();
@@ -1295,9 +1295,9 @@ PosixEndpointImpl::PosixEndpointImpl(EventHandle* handle,
1295
1295
  }
1296
1296
 
1297
1297
  if (zerocopy_enabled) {
1298
- LOG(INFO) << "Tx-zero copy enabled for gRPC sends. RLIMIT_MEMLOCK value "
1299
- << "=" << GetRLimitMemLockMax()
1300
- << ",ulimit hard memlock value = " << GetUlimitHardMemLock();
1298
+ VLOG(2) << "Tx-zero copy enabled for gRPC sends. RLIMIT_MEMLOCK value "
1299
+ << "=" << GetRLimitMemLockMax()
1300
+ << ",ulimit hard memlock value = " << GetUlimitHardMemLock();
1301
1301
  }
1302
1302
  }
1303
1303
  #endif // GRPC_LINUX_ERRQUEUE
@@ -184,7 +184,7 @@ class TcpZerocopySendCtx {
184
184
  if (send_records_ == nullptr || free_send_records_ == nullptr) {
185
185
  gpr_free(send_records_);
186
186
  gpr_free(free_send_records_);
187
- LOG(INFO) << "Disabling TCP TX zerocopy due to memory pressure.\n";
187
+ VLOG(2) << "Disabling TCP TX zerocopy due to memory pressure.\n";
188
188
  memory_limited_ = true;
189
189
  enabled_ = false;
190
190
  } else {
@@ -345,14 +345,14 @@ absl::StatusOr<int> ListenerContainerAddWildcardAddresses(
345
345
  }
346
346
  if (assigned_port > 0) {
347
347
  if (!v6_sock.ok()) {
348
- LOG(INFO) << "Failed to add :: listener, the environment may not support "
349
- "IPv6: "
350
- << v6_sock.status();
348
+ VLOG(2) << "Failed to add :: listener, the environment may not support "
349
+ "IPv6: "
350
+ << v6_sock.status();
351
351
  }
352
352
  if (!v4_sock.ok()) {
353
- LOG(INFO) << "Failed to add 0.0.0.0 listener, "
354
- "the environment may not support IPv4: "
355
- << v4_sock.status();
353
+ VLOG(2) << "Failed to add 0.0.0.0 listener, "
354
+ "the environment may not support IPv4: "
355
+ << v4_sock.status();
356
356
  }
357
357
  return assigned_port;
358
358
  } else {
@@ -627,12 +627,16 @@ void PosixSocketWrapper::TrySetSocketTcpUserTimeout(
627
627
  // if it is available.
628
628
  if (g_socket_supports_tcp_user_timeout.load() == 0) {
629
629
  if (0 != getsockopt(fd_, IPPROTO_TCP, TCP_USER_TIMEOUT, &newval, &len)) {
630
- LOG(INFO) << "TCP_USER_TIMEOUT is not available. TCP_USER_TIMEOUT "
631
- "won't be used thereafter";
630
+ // This log is intentionally not protected behind a flag, so that users
631
+ // know that TCP_USER_TIMEOUT is not being used.
632
+ GRPC_TRACE_LOG(tcp, INFO)
633
+ << "TCP_USER_TIMEOUT is not available. TCP_USER_TIMEOUT "
634
+ "won't be used thereafter";
632
635
  g_socket_supports_tcp_user_timeout.store(-1);
633
636
  } else {
634
- LOG(INFO) << "TCP_USER_TIMEOUT is available. TCP_USER_TIMEOUT will be "
635
- "used thereafter";
637
+ GRPC_TRACE_LOG(tcp, INFO)
638
+ << "TCP_USER_TIMEOUT is available. TCP_USER_TIMEOUT will be "
639
+ "used thereafter";
636
640
  g_socket_supports_tcp_user_timeout.store(1);
637
641
  }
638
642
  }
@@ -681,7 +685,8 @@ bool PosixSocketWrapper::IsIpv6LoopbackAvailable() {
681
685
  int fd = socket(AF_INET6, SOCK_STREAM, 0);
682
686
  bool loopback_available = false;
683
687
  if (fd < 0) {
684
- LOG(INFO) << "Disabling AF_INET6 sockets because socket() failed.";
688
+ GRPC_TRACE_LOG(tcp, INFO)
689
+ << "Disabling AF_INET6 sockets because socket() failed.";
685
690
  } else {
686
691
  sockaddr_in6 addr;
687
692
  memset(&addr, 0, sizeof(addr));
@@ -690,7 +695,8 @@ bool PosixSocketWrapper::IsIpv6LoopbackAvailable() {
690
695
  if (bind(fd, reinterpret_cast<sockaddr*>(&addr), sizeof(addr)) == 0) {
691
696
  loopback_available = true;
692
697
  } else {
693
- LOG(INFO) << "Disabling AF_INET6 sockets because ::1 is not available.";
698
+ GRPC_TRACE_LOG(tcp, INFO)
699
+ << "Disabling AF_INET6 sockets because ::1 is not available.";
694
700
  }
695
701
  close(fd);
696
702
  }
@@ -36,6 +36,7 @@
36
36
  #include <grpc/support/thd_id.h>
37
37
 
38
38
  #include "src/core/lib/backoff/backoff.h"
39
+ #include "src/core/lib/debug/trace_impl.h"
39
40
  #include "src/core/lib/event_engine/common_closures.h"
40
41
  #include "src/core/lib/event_engine/thread_local.h"
41
42
  #include "src/core/lib/event_engine/trace.h"
@@ -266,7 +267,6 @@ void WorkStealingThreadPool::WorkStealingThreadPoolImpl::StartThread() {
266
267
  }
267
268
 
268
269
  void WorkStealingThreadPool::WorkStealingThreadPoolImpl::Quiesce() {
269
- LOG(INFO) << "WorkStealingThreadPoolImpl::Quiesce";
270
270
  SetShutdown(true);
271
271
  // Wait until all threads have exited.
272
272
  // Note that if this is a threadpool thread then we won't exit this thread
@@ -318,7 +318,8 @@ bool WorkStealingThreadPool::WorkStealingThreadPoolImpl::IsQuiesced() {
318
318
  }
319
319
 
320
320
  void WorkStealingThreadPool::WorkStealingThreadPoolImpl::PrepareFork() {
321
- LOG(INFO) << "WorkStealingThreadPoolImpl::PrepareFork";
321
+ LOG_IF(INFO, GRPC_TRACE_FLAG_ENABLED(event_engine))
322
+ << "WorkStealingThreadPoolImpl::PrepareFork";
322
323
  SetForking(true);
323
324
  work_signal_.SignalAll();
324
325
  auto threads_were_shut_down = living_thread_count_.BlockUntilThreadCount(
@@ -71,7 +71,8 @@ void WinSocket::Shutdown() {
71
71
  &ioctl_num_bytes, NULL, NULL);
72
72
  if (status != 0) {
73
73
  char* utf8_message = gpr_format_message(WSAGetLastError());
74
- LOG(INFO) << "Unable to retrieve DisconnectEx pointer : " << utf8_message;
74
+ GRPC_TRACE_LOG(event_engine_endpoint, INFO)
75
+ << "Unable to retrieve DisconnectEx pointer : " << utf8_message;
75
76
  gpr_free(utf8_message);
76
77
  } else if (DisconnectEx(socket_, NULL, 0, 0) == FALSE) {
77
78
  auto last_error = WSAGetLastError();
@@ -79,7 +80,8 @@ void WinSocket::Shutdown() {
79
80
  // error, and log all others.
80
81
  if (last_error != WSAENOTCONN) {
81
82
  char* utf8_message = gpr_format_message(last_error);
82
- LOG(INFO) << "DisconnectEx failed: " << utf8_message;
83
+ GRPC_TRACE_LOG(event_engine_endpoint, INFO)
84
+ << "DisconnectEx failed: " << utf8_message;
83
85
  gpr_free(utf8_message);
84
86
  }
85
87
  }
@@ -42,8 +42,8 @@ constexpr int kMaxWSABUFCount = 16;
42
42
  void DumpSliceBuffer(SliceBuffer* buffer, absl::string_view context_string) {
43
43
  for (size_t i = 0; i < buffer->Count(); i++) {
44
44
  auto str = buffer->MutableSliceAt(i).as_string_view();
45
- gpr_log(GPR_INFO, "%s: %.*s", context_string.data(), str.length(),
46
- str.data());
45
+ GRPC_TRACE_LOG(event_engine_endpoint, INFO)
46
+ << context_string << ": " << str;
47
47
  }
48
48
  }
49
49
 
@@ -159,8 +159,9 @@ bool WindowsEndpoint::Write(absl::AnyInvocable<void(absl::Status)> on_writable,
159
159
  if (GRPC_TRACE_FLAG_ENABLED(event_engine_endpoint_data)) {
160
160
  for (size_t i = 0; i < data->Count(); i++) {
161
161
  auto str = data->RefSlice(i).as_string_view();
162
- gpr_log(GPR_INFO, "WindowsEndpoint::%p WRITE (peer=%s): %.*s", this,
163
- peer_address_string_.c_str(), str.length(), str.data());
162
+ GRPC_TRACE_LOG(event_engine_endpoint, INFO)
163
+ << "WindowsEndpoint::" << this
164
+ << " WRITE (peer=" << peer_address_string_ << "): " << str;
164
165
  }
165
166
  }
166
167
  CHECK(data->Count() <= UINT_MAX);
@@ -24,6 +24,7 @@
24
24
 
25
25
  #include "absl/functional/any_invocable.h"
26
26
  #include "absl/log/check.h"
27
+ #include "absl/log/log.h"
27
28
  #include "absl/strings/str_join.h"
28
29
  #include "absl/strings/str_split.h"
29
30
  #include "absl/strings/string_view.h"
@@ -227,19 +228,20 @@ void PrintExperimentsList() {
227
228
  }
228
229
  if (experiment_status.empty()) {
229
230
  if (!defaulted_on_experiments.empty()) {
230
- gpr_log(GPR_INFO, "gRPC experiments enabled: %s",
231
- absl::StrJoin(defaulted_on_experiments, ", ").c_str());
231
+ VLOG(2) << "gRPC experiments enabled: "
232
+ << absl::StrJoin(defaulted_on_experiments, ", ");
232
233
  }
233
234
  } else {
234
235
  if (defaulted_on_experiments.empty()) {
235
- gpr_log(GPR_INFO, "gRPC experiments: %s",
236
- absl::StrJoin(experiment_status, ", ", absl::PairFormatter(":"))
237
- .c_str());
236
+ VLOG(2) << "gRPC experiments: "
237
+ << absl::StrJoin(experiment_status, ", ",
238
+ absl::PairFormatter(":"));
238
239
  } else {
239
- gpr_log(GPR_INFO, "gRPC experiments: %s; default-enabled: %s",
240
- absl::StrJoin(experiment_status, ", ", absl::PairFormatter(":"))
241
- .c_str(),
242
- absl::StrJoin(defaulted_on_experiments, ", ").c_str());
240
+ VLOG(2) << "gRPC experiments: "
241
+ << absl::StrJoin(experiment_status, ", ",
242
+ absl::PairFormatter(":"))
243
+ << "; default-enabled: "
244
+ << absl::StrJoin(defaulted_on_experiments, ", ");
243
245
  }
244
246
  }
245
247
  }
@@ -501,7 +501,7 @@ const ExperimentMetadata g_experiment_metadata[] = {
501
501
  additional_constraints_work_serializer_clears_time_cache, nullptr, 0, true,
502
502
  true},
503
503
  {"work_serializer_dispatch", description_work_serializer_dispatch,
504
- additional_constraints_work_serializer_dispatch, nullptr, 0, true, true},
504
+ additional_constraints_work_serializer_dispatch, nullptr, 0, false, true},
505
505
  };
506
506
 
507
507
  } // namespace grpc_core
@@ -158,8 +158,7 @@ inline bool IsTraceRecordCallopsEnabled() { return true; }
158
158
  inline bool IsUnconstrainedMaxQuotaBufferSizeEnabled() { return false; }
159
159
  #define GRPC_EXPERIMENT_IS_INCLUDED_WORK_SERIALIZER_CLEARS_TIME_CACHE
160
160
  inline bool IsWorkSerializerClearsTimeCacheEnabled() { return true; }
161
- #define GRPC_EXPERIMENT_IS_INCLUDED_WORK_SERIALIZER_DISPATCH
162
- inline bool IsWorkSerializerDispatchEnabled() { return true; }
161
+ inline bool IsWorkSerializerDispatchEnabled() { return false; }
163
162
  #endif
164
163
 
165
164
  #else
@@ -93,9 +93,9 @@ class DualRefCounted : public Impl {
93
93
  #ifndef NDEBUG
94
94
  const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
95
95
  if (trace_ != nullptr) {
96
- LOG(INFO) << trace_ << ":" << this << " unref " << strong_refs << " -> "
97
- << strong_refs - 1 << ", weak_ref " << weak_refs << " -> "
98
- << weak_refs + 1;
96
+ VLOG(2) << trace_ << ":" << this << " unref " << strong_refs << " -> "
97
+ << strong_refs - 1 << ", weak_ref " << weak_refs << " -> "
98
+ << weak_refs + 1;
99
99
  }
100
100
  CHECK_GT(strong_refs, 0u);
101
101
  #endif
@@ -112,10 +112,10 @@ class DualRefCounted : public Impl {
112
112
  #ifndef NDEBUG
113
113
  const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
114
114
  if (trace_ != nullptr) {
115
- LOG(INFO) << trace_ << ":" << this << " " << location.file() << ":"
116
- << location.line() << " unref " << strong_refs << " -> "
117
- << strong_refs - 1 << ", weak_ref " << weak_refs << " -> "
118
- << weak_refs + 1 << ") " << reason;
115
+ VLOG(2) << trace_ << ":" << this << " " << location.file() << ":"
116
+ << location.line() << " unref " << strong_refs << " -> "
117
+ << strong_refs - 1 << ", weak_ref " << weak_refs << " -> "
118
+ << weak_refs + 1 << ") " << reason;
119
119
  }
120
120
  CHECK_GT(strong_refs, 0u);
121
121
  #else
@@ -137,9 +137,9 @@ class DualRefCounted : public Impl {
137
137
  #ifndef NDEBUG
138
138
  const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
139
139
  if (trace_ != nullptr) {
140
- LOG(INFO) << trace_ << ":" << this << " ref_if_non_zero " << strong_refs
141
- << " -> " << strong_refs + 1 << " (weak_refs=" << weak_refs
142
- << ")";
140
+ VLOG(2) << trace_ << ":" << this << " ref_if_non_zero " << strong_refs
141
+ << " -> " << strong_refs + 1 << " (weak_refs=" << weak_refs
142
+ << ")";
143
143
  }
144
144
  #endif
145
145
  if (strong_refs == 0) return nullptr;
@@ -156,10 +156,10 @@ class DualRefCounted : public Impl {
156
156
  #ifndef NDEBUG
157
157
  const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
158
158
  if (trace_ != nullptr) {
159
- LOG(INFO) << trace_ << ":" << this << " " << location.file() << ":"
160
- << location.line() << " ref_if_non_zero " << strong_refs
161
- << " -> " << strong_refs + 1 << " (weak_refs=" << weak_refs
162
- << ") " << reason;
159
+ VLOG(2) << trace_ << ":" << this << " " << location.file() << ":"
160
+ << location.line() << " ref_if_non_zero " << strong_refs
161
+ << " -> " << strong_refs + 1 << " (weak_refs=" << weak_refs
162
+ << ") " << reason;
163
163
  }
164
164
  #else
165
165
  // Avoid unused-parameter warnings for debug-only parameters
@@ -214,8 +214,8 @@ class DualRefCounted : public Impl {
214
214
  const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
215
215
  const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
216
216
  if (trace != nullptr) {
217
- LOG(INFO) << trace << ":" << this << " weak_unref " << weak_refs << " -> "
218
- << weak_refs - 1 << " (refs=" << strong_refs << ")";
217
+ VLOG(2) << trace << ":" << this << " weak_unref " << weak_refs << " -> "
218
+ << weak_refs - 1 << " (refs=" << strong_refs << ")";
219
219
  }
220
220
  CHECK_GT(weak_refs, 0u);
221
221
  #endif
@@ -236,9 +236,9 @@ class DualRefCounted : public Impl {
236
236
  const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
237
237
  const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
238
238
  if (trace != nullptr) {
239
- LOG(INFO) << trace << ":" << this << " " << location.file() << ":"
240
- << location.line() << " weak_unref " << weak_refs << " -> "
241
- << weak_refs - 1 << " (refs=" << strong_refs << ") " << reason;
239
+ VLOG(2) << trace << ":" << this << " " << location.file() << ":"
240
+ << location.line() << " weak_unref " << weak_refs << " -> "
241
+ << weak_refs - 1 << " (refs=" << strong_refs << ") " << reason;
242
242
  }
243
243
  CHECK_GT(weak_refs, 0u);
244
244
  #else
@@ -301,8 +301,8 @@ class DualRefCounted : public Impl {
301
301
  const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
302
302
  CHECK_NE(strong_refs, 0u);
303
303
  if (trace_ != nullptr) {
304
- LOG(INFO) << trace_ << ":" << this << " ref " << strong_refs << " -> "
305
- << strong_refs + 1 << "; (weak_refs=" << weak_refs << ")";
304
+ VLOG(2) << trace_ << ":" << this << " ref " << strong_refs << " -> "
305
+ << strong_refs + 1 << "; (weak_refs=" << weak_refs << ")";
306
306
  }
307
307
  #else
308
308
  refs_.fetch_add(MakeRefPair(1, 0), std::memory_order_relaxed);
@@ -316,10 +316,10 @@ class DualRefCounted : public Impl {
316
316
  const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
317
317
  CHECK_NE(strong_refs, 0u);
318
318
  if (trace_ != nullptr) {
319
- LOG(INFO) << trace_ << ":" << this << " " << location.file() << ":"
320
- << location.line() << " ref " << strong_refs << " -> "
321
- << strong_refs + 1 << " (weak_refs=" << weak_refs << ") "
322
- << reason;
319
+ VLOG(2) << trace_ << ":" << this << " " << location.file() << ":"
320
+ << location.line() << " ref " << strong_refs << " -> "
321
+ << strong_refs + 1 << " (weak_refs=" << weak_refs << ") "
322
+ << reason;
323
323
  }
324
324
  #else
325
325
  // Use conditionally-important parameters
@@ -336,8 +336,8 @@ class DualRefCounted : public Impl {
336
336
  const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
337
337
  const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
338
338
  if (trace_ != nullptr) {
339
- LOG(INFO) << trace_ << ":" << this << " weak_ref " << weak_refs << " -> "
340
- << weak_refs + 1 << "; (refs=" << strong_refs << ")";
339
+ VLOG(2) << trace_ << ":" << this << " weak_ref " << weak_refs << " -> "
340
+ << weak_refs + 1 << "; (refs=" << strong_refs << ")";
341
341
  }
342
342
  if (strong_refs == 0) CHECK_NE(weak_refs, 0u);
343
343
  #else
@@ -352,9 +352,9 @@ class DualRefCounted : public Impl {
352
352
  const uint32_t strong_refs = GetStrongRefs(prev_ref_pair);
353
353
  const uint32_t weak_refs = GetWeakRefs(prev_ref_pair);
354
354
  if (trace_ != nullptr) {
355
- LOG(INFO) << trace_ << ":" << this << " " << location.file() << ":"
356
- << location.line() << " weak_ref " << weak_refs << " -> "
357
- << weak_refs + 1 << " (refs=" << strong_refs << ") " << reason;
355
+ VLOG(2) << trace_ << ":" << this << " " << location.file() << ":"
356
+ << location.line() << " weak_ref " << weak_refs << " -> "
357
+ << weak_refs + 1 << " (refs=" << strong_refs << ") " << reason;
358
358
  }
359
359
  if (strong_refs == 0) CHECK_NE(weak_refs, 0u);
360
360
  #else
@@ -66,13 +66,13 @@ static void create_sockets(SOCKET sv[2]) {
66
66
  closesocket(lst_sock);
67
67
  grpc_error_handle error = grpc_tcp_prepare_socket(cli_sock);
68
68
  if (!error.ok()) {
69
- LOG(INFO) << "Prepare cli_sock failed with error: "
70
- << grpc_core::StatusToString(error);
69
+ VLOG(2) << "Prepare cli_sock failed with error: "
70
+ << grpc_core::StatusToString(error);
71
71
  }
72
72
  error = grpc_tcp_prepare_socket(svr_sock);
73
73
  if (!error.ok()) {
74
- LOG(INFO) << "Prepare svr_sock failed with error: "
75
- << grpc_core::StatusToString(error);
74
+ VLOG(2) << "Prepare svr_sock failed with error: "
75
+ << grpc_core::StatusToString(error);
76
76
  }
77
77
 
78
78
  sv[1] = cli_sock;
@@ -122,7 +122,7 @@ static bool epoll_set_init() {
122
122
  return false;
123
123
  }
124
124
 
125
- gpr_log(GPR_INFO, "grpc epoll fd: %d", g_epoll_set.epfd);
125
+ GRPC_TRACE_LOG(polling, INFO) << "grpc epoll fd: " << g_epoll_set.epfd;
126
126
  gpr_atm_no_barrier_store(&g_epoll_set.num_events, 0);
127
127
  gpr_atm_no_barrier_store(&g_epoll_set.cursor, 0);
128
128
  return true;