diff options
author | Craig Tiller <ctiller@google.com> | 2016-05-18 09:45:45 -0700 |
---|---|---|
committer | Craig Tiller <ctiller@google.com> | 2016-05-18 09:45:45 -0700 |
commit | 01fb04d740e0b4cdbf82c3859427059f6f83a993 (patch) | |
tree | f7f6187b5628e7f97cb62fea4eb6f91f4bdae0ff /src/core/lib/channel | |
parent | ba4a862b2c5c1a5e16261c427790a18c7d95aa2f (diff) | |
parent | fcbe7daf832dcb616fc93ca59c3b1aab279f510e (diff) |
Merge github.com:grpc/grpc into error
Diffstat (limited to 'src/core/lib/channel')
-rw-r--r-- | src/core/lib/channel/compress_filter.c | 12 | ||||
-rw-r--r-- | src/core/lib/channel/compress_filter.h | 2 |
2 files changed, 8 insertions, 6 deletions
diff --git a/src/core/lib/channel/compress_filter.c b/src/core/lib/channel/compress_filter.c index e029ec54be..27a87db0c2 100644 --- a/src/core/lib/channel/compress_filter.c +++ b/src/core/lib/channel/compress_filter.c @@ -47,7 +47,7 @@ #include "src/core/lib/support/string.h" #include "src/core/lib/transport/static_metadata.h" -int grpc_compress_filter_trace = 0; +int grpc_compression_trace = 0; typedef struct call_data { gpr_slice_buffer slices; /**< Buffers up input slices to be compressed */ @@ -171,7 +171,7 @@ static void finish_send_message(grpc_exec_ctx *exec_ctx, did_compress = grpc_msg_compress(calld->compression_algorithm, &calld->slices, &tmp); if (did_compress) { - if (grpc_compress_filter_trace) { + if (grpc_compression_trace) { char *algo_name; const size_t before_size = calld->slices.length; const size_t after_size = tmp.length; @@ -185,12 +185,14 @@ static void finish_send_message(grpc_exec_ctx *exec_ctx, gpr_slice_buffer_swap(&calld->slices, &tmp); calld->send_flags |= GRPC_WRITE_INTERNAL_COMPRESS; } else { - if (grpc_compress_filter_trace) { + if (grpc_compression_trace) { char *algo_name; GPR_ASSERT(grpc_compression_algorithm_name(calld->compression_algorithm, &algo_name)); - gpr_log(GPR_DEBUG, "Algorithm '%s' enabled but decided not to compress.", - algo_name); + gpr_log( + GPR_DEBUG, + "Algorithm '%s' enabled but decided not to compress. Input size: %d", + algo_name, calld->slices.length); } } diff --git a/src/core/lib/channel/compress_filter.h b/src/core/lib/channel/compress_filter.h index cf5879d82e..0ce5d08837 100644 --- a/src/core/lib/channel/compress_filter.h +++ b/src/core/lib/channel/compress_filter.h @@ -38,7 +38,7 @@ #define GRPC_COMPRESS_REQUEST_ALGORITHM_KEY "grpc-internal-encoding-request" -extern int grpc_compress_filter_trace; +extern int grpc_compression_trace; /** Compression filter for outgoing data. * |