-
Notifications
You must be signed in to change notification settings - Fork 438
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[EXPORTER] Gzip compression support for OTLP/HTTP and OTLP/gRPC expor…
…ter (#2530)
- Loading branch information
1 parent
eaaf6cd
commit 07f6cb5
Showing
39 changed files
with
402 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
# Copyright The OpenTelemetry Authors | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
# Builds ZLIB from a distribution. | ||
# Copied from https://github.com/protocolbuffers/protobuf/blob/master/third_party/zlib.BUILD | ||
|
||
licenses(["notice"]) # BSD/MIT-like license (for zlib) | ||
|
||
exports_files(["zlib.BUILD"]) | ||
|
||
_ZLIB_HEADERS = [ | ||
"crc32.h", | ||
"deflate.h", | ||
"gzguts.h", | ||
"inffast.h", | ||
"inffixed.h", | ||
"inflate.h", | ||
"inftrees.h", | ||
"trees.h", | ||
"zconf.h", | ||
"zlib.h", | ||
"zutil.h", | ||
] | ||
|
||
_ZLIB_PREFIXED_HEADERS = ["zlib/include/" + hdr for hdr in _ZLIB_HEADERS] | ||
|
||
# In order to limit the damage from the `includes` propagation | ||
# via `:zlib`, copy the public headers to a subdirectory and | ||
# expose those. | ||
genrule( | ||
name = "copy_public_headers", | ||
srcs = _ZLIB_HEADERS, | ||
outs = _ZLIB_PREFIXED_HEADERS, | ||
cmd_bash = "cp $(SRCS) $(@D)/zlib/include/", | ||
cmd_bat = " && ".join( | ||
["@copy /Y $(location %s) $(@D)\\zlib\\include\\ >NUL" % | ||
s for s in _ZLIB_HEADERS], | ||
), | ||
) | ||
|
||
cc_library( | ||
name = "zlib", | ||
srcs = [ | ||
"adler32.c", | ||
"compress.c", | ||
"crc32.c", | ||
"deflate.c", | ||
"gzclose.c", | ||
"gzlib.c", | ||
"gzread.c", | ||
"gzwrite.c", | ||
"infback.c", | ||
"inffast.c", | ||
"inflate.c", | ||
"inftrees.c", | ||
"trees.c", | ||
"uncompr.c", | ||
"zutil.c", | ||
# Include the un-prefixed headers in srcs to work | ||
# around the fact that zlib isn't consistent in its | ||
# choice of <> or "" delimiter when including itself. | ||
] + _ZLIB_HEADERS, | ||
hdrs = _ZLIB_PREFIXED_HEADERS, | ||
copts = select({ | ||
"@platforms//os:windows": [], | ||
"//conditions:default": [ | ||
"-Wno-deprecated-non-prototype", | ||
"-Wno-unused-variable", | ||
"-Wno-implicit-function-declaration", | ||
], | ||
}), | ||
includes = ["zlib/include/"], | ||
visibility = ["//visibility:public"], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
07f6cb5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Possible performance regression was detected for benchmark 'OpenTelemetry-cpp exporters Benchmark'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold
2
.BM_OtlpExporterSparseSpans
191.85832504635312
ns/iter93.81658777414067
ns/iter2.05
BM_OtlpExporterDenseSpans
1331.227440987864
ns/iter639.1109396877898
ns/iter2.08
This comment was automatically generated by workflow using github-action-benchmark.
07f6cb5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Possible performance regression was detected for benchmark 'OpenTelemetry-cpp sdk Benchmark'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold
2
.BM_BaselineBuffer/1
5855917.930603027
ns/iter1993003.6067962646
ns/iter2.94
This comment was automatically generated by workflow using github-action-benchmark.