5 Commits

Author SHA1 Message Date
Craig Tiller 339906443b [clang-format] Match include file ordering to internal clang-format (#40905)
gRPC is currently getting formatted with two different clang-format implementations, and due to some weirdness they have different include file orderings. This change introduces clang-format configuration to ensure that the two systems align - it's *highly* expected that this will need some maintenance going forward as the two systems evolve.

Closes #40905

PiperOrigin-RevId: 819606209
2025-10-15 00:24:11 -07:00
Mark D. Roth 0bf60a425e [metrics] pass StatsPluginGroup down via channel args (#39130)
Closes #39130

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/39130 from markdroth:stats_plugin_group_propagation 82b43c6adc1f007fe213cdf3d15b7647a3e39383
PiperOrigin-RevId: 743240083
2025-04-02 12:39:19 -07:00
Craig Tiller dbb5164ac7 [clang-format] Remove custom clang-format rules for include ordering (#37820)
Closes #37820

PiperOrigin-RevId: 682352913
2024-10-04 09:44:20 -07:00
Yash Tibrewal 25dea6e8cc [StatsPlugin] Some more benchmarks and fixes (#37299)
```
-------------------------------------------------------------------------------------
Benchmark                                           Time             CPU   Iterations
-------------------------------------------------------------------------------------
BM_AddCounterWithFakeStatsPlugin                 36.9 ns         36.9 ns     18606645
BM_AddCounterWithLabelsWithFakeStatsPlugin        407 ns          407 ns      1712866
BM_AddCounterWithOTelPlugin                      46.6 ns         46.6 ns     15022711
BM_AddCounterWithLabelsWithOTelPlugin             142 ns          142 ns      4957733
BM_AddCounterWithNoPlugin                       0.313 ns        0.313 ns   1000000000
BM_AddCounterWithLabelsWithNoPlugin              1.96 ns         1.96 ns    356217818
```

Closes #37299

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/37299 from yashykt:BMStatsPlugin b4ad53e22ba6924e6bdf8944b9110765b6b37266
PiperOrigin-RevId: 655361009
2024-07-23 17:33:03 -07:00
Yijie Ma eb2ed3e4da [Performance] Benchmark AddCounter with FakeStatsPlugin and OTelPlugin (#37282)
Sample output:

```
➜  grpc git:(otel-metrics-benchmark) ✗ bazel-bin/test/cpp/microbenchmarks/bm_stats_plugin
WARNING: All log messages before absl::InitializeLog() is called are written to STDERR
I0000 00:00:1721695619.615582 2126186 config.cc:257] gRPC experiments enabled: call_status_override_on_cancellation, call_tracer_in_transport, event_engine_dns, event_engine_listener, monitoring_experiment, pick_first_new, trace_record_callops, work_serializer_clears_time_cache
2024-07-22T17:46:59-07:00
Running bazel-bin/test/cpp/microbenchmarks/bm_stats_plugin
Run on (48 X 2450 MHz CPU s)
CPU Caches:
  L1 Data 32 KiB (x24)
  L1 Instruction 32 KiB (x24)
  L2 Unified 512 KiB (x24)
  L3 Unified 32768 KiB (x3)
Load Average: 1.16, 0.85, 0.85
***WARNING*** Library was built as DEBUG. Timings may be affected.
---------------------------------------------------------------------------
Benchmark                                 Time             CPU   Iterations
---------------------------------------------------------------------------
BM_AddCounterWithFakeStatsPlugin       1738 ns         1738 ns       404265
BM_AddCounterWithOTelPlugin             757 ns          757 ns       928142
I0000 00:00:1721695621.304593 2126186 test_config.cc:186] TestEnvironment ends
```

<!--

If you know who should review your pull request, please assign it to that
person, otherwise the pull request would get assigned randomly.

If your pull request is for a specific language, please add the appropriate
lang label.

-->

Closes #37282

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/37282 from yijiem:otel-metrics-benchmark eeba3dfb5e2991e7093bfaa613ac89e9215043f5
PiperOrigin-RevId: 655286398
2024-07-23 13:40:22 -07:00