aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/lib')
-rw-r--r--src/core/lib/channel/channel_args.c98
-rw-r--r--src/core/lib/channel/channel_args.h31
-rw-r--r--src/core/lib/compression/algorithm_metadata.h18
-rw-r--r--src/core/lib/compression/compression.c281
-rw-r--r--src/core/lib/compression/compression_internal.c310
-rw-r--r--src/core/lib/compression/compression_internal.h110
-rw-r--r--src/core/lib/compression/message_compress.c22
-rw-r--r--src/core/lib/compression/message_compress.h7
-rw-r--r--src/core/lib/slice/slice_string_helpers.c41
-rw-r--r--src/core/lib/slice/slice_string_helpers.h5
-rw-r--r--src/core/lib/surface/byte_buffer_reader.c2
-rw-r--r--src/core/lib/surface/call.c301
-rw-r--r--src/core/lib/surface/call_test_only.h14
-rw-r--r--src/core/lib/surface/channel.c29
-rw-r--r--src/core/lib/transport/static_metadata.c867
-rw-r--r--src/core/lib/transport/static_metadata.h499
16 files changed, 1225 insertions, 1410 deletions
diff --git a/src/core/lib/channel/channel_args.c b/src/core/lib/channel/channel_args.c
index 30248b3c60..69980586aa 100644
--- a/src/core/lib/channel/channel_args.c
+++ b/src/core/lib/channel/channel_args.c
@@ -223,21 +223,6 @@ grpc_compression_algorithm grpc_channel_args_get_compression_algorithm(
return GRPC_COMPRESS_NONE;
}
-grpc_stream_compression_algorithm
-grpc_channel_args_get_stream_compression_algorithm(const grpc_channel_args *a) {
- size_t i;
- if (a == NULL) return GRPC_STREAM_COMPRESS_NONE;
- for (i = 0; i < a->num_args; ++i) {
- if (a->args[i].type == GRPC_ARG_INTEGER &&
- !strcmp(GRPC_STREAM_COMPRESSION_CHANNEL_DEFAULT_ALGORITHM,
- a->args[i].key)) {
- return (grpc_stream_compression_algorithm)a->args[i].value.integer;
- break;
- }
- }
- return GRPC_STREAM_COMPRESS_NONE;
-}
-
grpc_channel_args *grpc_channel_args_set_compression_algorithm(
grpc_channel_args *a, grpc_compression_algorithm algorithm) {
GPR_ASSERT(algorithm < GRPC_COMPRESS_ALGORITHMS_COUNT);
@@ -248,16 +233,6 @@ grpc_channel_args *grpc_channel_args_set_compression_algorithm(
return grpc_channel_args_copy_and_add(a, &tmp, 1);
}
-grpc_channel_args *grpc_channel_args_set_stream_compression_algorithm(
- grpc_channel_args *a, grpc_stream_compression_algorithm algorithm) {
- GPR_ASSERT(algorithm < GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT);
- grpc_arg tmp;
- tmp.type = GRPC_ARG_INTEGER;
- tmp.key = (char *)GRPC_STREAM_COMPRESSION_CHANNEL_DEFAULT_ALGORITHM;
- tmp.value.integer = algorithm;
- return grpc_channel_args_copy_and_add(a, &tmp, 1);
-}
-
/** Returns 1 if the argument for compression algorithm's enabled states bitset
* was found in \a a, returning the arg's value in \a states. Otherwise, returns
* 0. */
@@ -278,26 +253,6 @@ static int find_compression_algorithm_states_bitset(const grpc_channel_args *a,
return 0; /* GPR_FALSE */
}
-/** Returns 1 if the argument for compression algorithm's enabled states bitset
- * was found in \a a, returning the arg's value in \a states. Otherwise, returns
- * 0. */
-static int find_stream_compression_algorithm_states_bitset(
- const grpc_channel_args *a, int **states_arg) {
- if (a != NULL) {
- size_t i;
- for (i = 0; i < a->num_args; ++i) {
- if (a->args[i].type == GRPC_ARG_INTEGER &&
- !strcmp(GRPC_STREAM_COMPRESSION_CHANNEL_ENABLED_ALGORITHMS_BITSET,
- a->args[i].key)) {
- *states_arg = &a->args[i].value.integer;
- **states_arg |= 0x1; /* forcefully enable support for no compression */
- return 1;
- }
- }
- }
- return 0; /* GPR_FALSE */
-}
-
grpc_channel_args *grpc_channel_args_compression_algorithm_set_state(
grpc_exec_ctx *exec_ctx, grpc_channel_args **a,
grpc_compression_algorithm algorithm, int state) {
@@ -339,48 +294,6 @@ grpc_channel_args *grpc_channel_args_compression_algorithm_set_state(
return result;
}
-grpc_channel_args *grpc_channel_args_stream_compression_algorithm_set_state(
- grpc_exec_ctx *exec_ctx, grpc_channel_args **a,
- grpc_stream_compression_algorithm algorithm, int state) {
- int *states_arg = NULL;
- grpc_channel_args *result = *a;
- const int states_arg_found =
- find_stream_compression_algorithm_states_bitset(*a, &states_arg);
-
- if (grpc_channel_args_get_stream_compression_algorithm(*a) == algorithm &&
- state == 0) {
- const char *algo_name = NULL;
- GPR_ASSERT(grpc_stream_compression_algorithm_name(algorithm, &algo_name) !=
- 0);
- gpr_log(GPR_ERROR,
- "Tried to disable default stream compression algorithm '%s'. The "
- "operation has been ignored.",
- algo_name);
- } else if (states_arg_found) {
- if (state != 0) {
- GPR_BITSET((unsigned *)states_arg, algorithm);
- } else if (algorithm != GRPC_STREAM_COMPRESS_NONE) {
- GPR_BITCLEAR((unsigned *)states_arg, algorithm);
- }
- } else {
- /* create a new arg */
- grpc_arg tmp;
- tmp.type = GRPC_ARG_INTEGER;
- tmp.key = (char *)GRPC_STREAM_COMPRESSION_CHANNEL_ENABLED_ALGORITHMS_BITSET;
- /* all enabled by default */
- tmp.value.integer = (1u << GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT) - 1;
- if (state != 0) {
- GPR_BITSET((unsigned *)&tmp.value.integer, algorithm);
- } else if (algorithm != GRPC_STREAM_COMPRESS_NONE) {
- GPR_BITCLEAR((unsigned *)&tmp.value.integer, algorithm);
- }
- result = grpc_channel_args_copy_and_add(*a, &tmp, 1);
- grpc_channel_args_destroy(exec_ctx, *a);
- *a = result;
- }
- return result;
-}
-
uint32_t grpc_channel_args_compression_algorithm_get_states(
const grpc_channel_args *a) {
int *states_arg;
@@ -391,17 +304,6 @@ uint32_t grpc_channel_args_compression_algorithm_get_states(
}
}
-uint32_t grpc_channel_args_stream_compression_algorithm_get_states(
- const grpc_channel_args *a) {
- int *states_arg;
- if (find_stream_compression_algorithm_states_bitset(a, &states_arg)) {
- return (uint32_t)*states_arg;
- } else {
- return (1u << GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT) -
- 1; /* All algs. enabled */
- }
-}
-
grpc_channel_args *grpc_channel_args_set_socket_mutator(
grpc_channel_args *a, grpc_socket_mutator *mutator) {
grpc_arg tmp = grpc_socket_mutator_to_arg(mutator);
diff --git a/src/core/lib/channel/channel_args.h b/src/core/lib/channel/channel_args.h
index 0599e189c3..f649a8d9ec 100644
--- a/src/core/lib/channel/channel_args.h
+++ b/src/core/lib/channel/channel_args.h
@@ -59,24 +59,12 @@ void grpc_channel_args_destroy(grpc_exec_ctx *exec_ctx, grpc_channel_args *a);
grpc_compression_algorithm grpc_channel_args_get_compression_algorithm(
const grpc_channel_args *a);
-/** Returns the stream compression algorithm set in \a a. */
-grpc_stream_compression_algorithm
-grpc_channel_args_get_stream_compression_algorithm(const grpc_channel_args *a);
-
/** Returns a channel arg instance with compression enabled. If \a a is
* non-NULL, its args are copied. N.B. GRPC_COMPRESS_NONE disables compression
* for the channel. */
grpc_channel_args *grpc_channel_args_set_compression_algorithm(
grpc_channel_args *a, grpc_compression_algorithm algorithm);
-/** Returns a channel arg instance with stream compression enabled. If \a a is
- * non-NULL, its args are copied. N.B. GRPC_STREAM_COMPRESS_NONE disables
- * stream compression for the channel. If a value other than
- * GRPC_STREAM_COMPRESS_NONE is set, it takes precedence over message-wise
- * compression algorithms. */
-grpc_channel_args *grpc_channel_args_set_stream_compression_algorithm(
- grpc_channel_args *a, grpc_stream_compression_algorithm algorithm);
-
/** Sets the support for the given compression algorithm. By default, all
* compression algorithms are enabled. It's an error to disable an algorithm set
* by grpc_channel_args_set_compression_algorithm.
@@ -88,17 +76,6 @@ grpc_channel_args *grpc_channel_args_compression_algorithm_set_state(
grpc_exec_ctx *exec_ctx, grpc_channel_args **a,
grpc_compression_algorithm algorithm, int enabled);
-/** Sets the support for the given stream compression algorithm. By default, all
- * stream compression algorithms are enabled. It's an error to disable an
- * algorithm set by grpc_channel_args_set_stream_compression_algorithm.
- *
- * Returns an instance with the updated algorithm states. The \a a pointer is
- * modified to point to the returned instance (which may be different from the
- * input value of \a a). */
-grpc_channel_args *grpc_channel_args_stream_compression_algorithm_set_state(
- grpc_exec_ctx *exec_ctx, grpc_channel_args **a,
- grpc_stream_compression_algorithm algorithm, int enabled);
-
/** Returns the bitset representing the support state (true for enabled, false
* for disabled) for compression algorithms.
*
@@ -107,14 +84,6 @@ grpc_channel_args *grpc_channel_args_stream_compression_algorithm_set_state(
uint32_t grpc_channel_args_compression_algorithm_get_states(
const grpc_channel_args *a);
-/** Returns the bitset representing the support state (true for enabled, false
- * for disabled) for stream compression algorithms.
- *
- * The i-th bit of the returned bitset corresponds to the i-th entry in the
- * grpc_stream_compression_algorithm enum. */
-uint32_t grpc_channel_args_stream_compression_algorithm_get_states(
- const grpc_channel_args *a);
-
int grpc_channel_args_compare(const grpc_channel_args *a,
const grpc_channel_args *b);
diff --git a/src/core/lib/compression/algorithm_metadata.h b/src/core/lib/compression/algorithm_metadata.h
index 08feafc1bb..3e90ca637d 100644
--- a/src/core/lib/compression/algorithm_metadata.h
+++ b/src/core/lib/compression/algorithm_metadata.h
@@ -20,20 +20,26 @@
#define GRPC_CORE_LIB_COMPRESSION_ALGORITHM_METADATA_H
#include <grpc/compression.h>
+#include "src/core/lib/compression/compression_internal.h"
#include "src/core/lib/transport/metadata.h"
/** Return compression algorithm based metadata value */
grpc_slice grpc_compression_algorithm_slice(
grpc_compression_algorithm algorithm);
-/** Return stream compression algorithm based metadata value */
-grpc_slice grpc_stream_compression_algorithm_slice(
- grpc_stream_compression_algorithm algorithm);
+/** Find compression algorithm based on passed in mdstr - returns
+ * GRPC_COMPRESS_ALGORITHM_COUNT on failure */
+grpc_compression_algorithm grpc_compression_algorithm_from_slice(
+ grpc_slice str);
-/** Return compression algorithm based metadata element (grpc-encoding: xxx) */
+/** Return compression algorithm based metadata element */
grpc_mdelem grpc_compression_encoding_mdelem(
grpc_compression_algorithm algorithm);
+/** Return message compression algorithm based metadata element (grpc-encoding: xxx) */
+grpc_mdelem grpc_message_compression_encoding_mdelem(
+ grpc_message_compression_algorithm algorithm);
+
/** Return stream compression algorithm based metadata element
* (content-encoding: xxx) */
grpc_mdelem grpc_stream_compression_encoding_mdelem(
@@ -41,8 +47,8 @@ grpc_mdelem grpc_stream_compression_encoding_mdelem(
/** Find compression algorithm based on passed in mdstr - returns
* GRPC_COMPRESS_ALGORITHM_COUNT on failure */
-grpc_compression_algorithm grpc_compression_algorithm_from_slice(
- grpc_slice str);
+grpc_message_compression_algorithm
+grpc_message_compression_algorithm_from_slice(grpc_slice str);
/** Find stream compression algorithm based on passed in mdstr - returns
* GRPC_STREAM_COMPRESS_ALGORITHM_COUNT on failure */
diff --git a/src/core/lib/compression/compression.c b/src/core/lib/compression/compression.c
index 1cfac23129..97a63654f3 100644
--- a/src/core/lib/compression/compression.c
+++ b/src/core/lib/compression/compression.c
@@ -23,40 +23,39 @@
#include <grpc/support/useful.h>
#include "src/core/lib/compression/algorithm_metadata.h"
+#include "src/core/lib/compression/compression_internal.h"
#include "src/core/lib/surface/api_trace.h"
#include "src/core/lib/transport/static_metadata.h"
+int grpc_compression_algorithm_is_message(
+ grpc_compression_algorithm algorithm) {
+ return (algorithm >= GRPC_COMPRESS_MESSAGE_DEFLATE &&
+ algorithm <= GRPC_COMPRESS_MESSAGE_GZIP) ? 1 : 0;
+}
+
+int grpc_compression_algorithm_is_stream(
+ grpc_compression_algorithm algorithm) {
+ return (algorithm == GRPC_COMPRESS_STREAM_GZIP) ? 1 : 0;
+}
+
int grpc_compression_algorithm_parse(grpc_slice name,
grpc_compression_algorithm *algorithm) {
- /* we use strncmp not only because it's safer (even though in this case it
- * doesn't matter, given that we are comparing against string literals, but
- * because this way we needn't have "name" nil-terminated (useful for slice
- * data, for example) */
if (grpc_slice_eq(name, GRPC_MDSTR_IDENTITY)) {
*algorithm = GRPC_COMPRESS_NONE;
return 1;
- } else if (grpc_slice_eq(name, GRPC_MDSTR_GZIP)) {
- *algorithm = GRPC_COMPRESS_GZIP;
- return 1;
- } else if (grpc_slice_eq(name, GRPC_MDSTR_DEFLATE)) {
- *algorithm = GRPC_COMPRESS_DEFLATE;
+ } else if (grpc_slice_eq(name, GRPC_MDSTR_MESSAGE_SLASH_DEFLATE)) {
+ *algorithm = GRPC_COMPRESS_MESSAGE_DEFLATE;
return 1;
- } else {
- return 0;
- }
-}
-
-int grpc_stream_compression_algorithm_parse(
- grpc_slice name, grpc_stream_compression_algorithm *algorithm) {
- if (grpc_slice_eq(name, GRPC_MDSTR_IDENTITY)) {
- *algorithm = GRPC_STREAM_COMPRESS_NONE;
+ } else if (grpc_slice_eq(name, GRPC_MDSTR_MESSAGE_SLASH_GZIP)) {
+ *algorithm = GRPC_COMPRESS_MESSAGE_GZIP;
return 1;
- } else if (grpc_slice_eq(name, GRPC_MDSTR_GZIP)) {
- *algorithm = GRPC_STREAM_COMPRESS_GZIP;
+ } else if (grpc_slice_eq(name, GRPC_MDSTR_STREAM_SLASH_GZIP)) {
+ *algorithm = GRPC_COMPRESS_STREAM_GZIP;
return 1;
} else {
return 0;
}
+ return 0;
}
int grpc_compression_algorithm_name(grpc_compression_algorithm algorithm,
@@ -67,11 +66,14 @@ int grpc_compression_algorithm_name(grpc_compression_algorithm algorithm,
case GRPC_COMPRESS_NONE:
*name = "identity";
return 1;
- case GRPC_COMPRESS_DEFLATE:
- *name = "deflate";
+ case GRPC_COMPRESS_MESSAGE_DEFLATE:
+ *name = "message/deflate";
return 1;
- case GRPC_COMPRESS_GZIP:
- *name = "gzip";
+ case GRPC_COMPRESS_MESSAGE_GZIP:
+ *name = "message/gzip";
+ return 1;
+ case GRPC_COMPRESS_STREAM_GZIP:
+ *name = "stream/gzip";
return 1;
case GRPC_COMPRESS_ALGORITHMS_COUNT:
return 0;
@@ -79,37 +81,56 @@ int grpc_compression_algorithm_name(grpc_compression_algorithm algorithm,
return 0;
}
-int grpc_stream_compression_algorithm_name(
- grpc_stream_compression_algorithm algorithm, const char **name) {
- GRPC_API_TRACE(
- "grpc_stream_compression_algorithm_parse(algorithm=%d, name=%p)", 2,
- ((int)algorithm, name));
- switch (algorithm) {
- case GRPC_STREAM_COMPRESS_NONE:
- *name = "identity";
- return 1;
- case GRPC_STREAM_COMPRESS_GZIP:
- *name = "gzip";
- return 1;
- case GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT:
- return 0;
+grpc_compression_algorithm grpc_compression_algorithm_for_level(
+ grpc_compression_level level, uint32_t accepted_encodings) {
+ grpc_compression_algorithm algo;
+ if (level == GRPC_COMPRESS_LEVEL_NONE) {
+ return GRPC_COMPRESS_NONE;
+ } else if (level <= GRPC_COMPRESS_LEVEL_MESSAGE_HIGH) {
+ GPR_ASSERT(
+ grpc_compression_algorithm_from_message_stream_compression_algorithm(
+ &algo,
+ grpc_message_compression_algorithm_for_level(
+ grpc_compression_level_to_message_compression_level(level),
+ grpc_compression_bitset_to_message_bitset(
+ accepted_encodings)),
+ 0));
+ return algo;
+ } else if (level <= GRPC_COMPRESS_LEVEL_STREAM_HIGH) {
+ GPR_ASSERT(
+ grpc_compression_algorithm_from_message_stream_compression_algorithm(
+ &algo, 0,
+ grpc_stream_compression_algorithm_for_level(
+ grpc_compression_level_to_stream_compression_level(level),
+ grpc_compression_bitset_to_stream_bitset(
+ accepted_encodings))));
+ return algo;
+ } else {
+ gpr_log(GPR_ERROR, "Unknown compression level: %d", level);
+ return GRPC_COMPRESS_NONE;
}
- return 0;
}
-grpc_compression_algorithm grpc_compression_algorithm_from_slice(
- grpc_slice str) {
- if (grpc_slice_eq(str, GRPC_MDSTR_IDENTITY)) return GRPC_COMPRESS_NONE;
- if (grpc_slice_eq(str, GRPC_MDSTR_DEFLATE)) return GRPC_COMPRESS_DEFLATE;
- if (grpc_slice_eq(str, GRPC_MDSTR_GZIP)) return GRPC_COMPRESS_GZIP;
- return GRPC_COMPRESS_ALGORITHMS_COUNT;
+void grpc_compression_options_init(grpc_compression_options *opts) {
+ memset(opts, 0, sizeof(*opts));
+ /* all enabled by default */
+ opts->enabled_algorithms_bitset = (1u << GRPC_COMPRESS_ALGORITHMS_COUNT) - 1;
+}
+
+void grpc_compression_options_enable_algorithm(
+ grpc_compression_options *opts, grpc_compression_algorithm algorithm) {
+ GPR_BITSET(&opts->enabled_algorithms_bitset, algorithm);
}
-grpc_stream_compression_algorithm grpc_stream_compression_algorithm_from_slice(
- grpc_slice str) {
- if (grpc_slice_eq(str, GRPC_MDSTR_IDENTITY)) return GRPC_STREAM_COMPRESS_NONE;
- if (grpc_slice_eq(str, GRPC_MDSTR_GZIP)) return GRPC_STREAM_COMPRESS_GZIP;
- return GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT;
+void grpc_compression_options_disable_algorithm(
+ grpc_compression_options *opts, grpc_compression_algorithm algorithm) {
+ GPR_BITCLEAR(&opts->enabled_algorithms_bitset, algorithm);
+}
+
+int grpc_compression_options_is_algorithm_enabled(
+ const grpc_compression_options *opts,
+ grpc_compression_algorithm algorithm) {
+ return GPR_BITGET(opts->enabled_algorithms_bitset, algorithm);
}
grpc_slice grpc_compression_algorithm_slice(
@@ -117,27 +138,25 @@ grpc_slice grpc_compression_algorithm_slice(
switch (algorithm) {
case GRPC_COMPRESS_NONE:
return GRPC_MDSTR_IDENTITY;
- case GRPC_COMPRESS_DEFLATE:
- return GRPC_MDSTR_DEFLATE;
- case GRPC_COMPRESS_GZIP:
- return GRPC_MDSTR_GZIP;
+ case GRPC_COMPRESS_MESSAGE_DEFLATE:
+ return GRPC_MDSTR_MESSAGE_SLASH_DEFLATE;
+ case GRPC_COMPRESS_MESSAGE_GZIP:
+ return GRPC_MDSTR_MESSAGE_SLASH_GZIP;
+ case GRPC_COMPRESS_STREAM_GZIP:
+ return GRPC_MDSTR_STREAM_SLASH_GZIP;
case GRPC_COMPRESS_ALGORITHMS_COUNT:
return grpc_empty_slice();
}
return grpc_empty_slice();
}
-grpc_slice grpc_stream_compression_algorithm_slice(
- grpc_stream_compression_algorithm algorithm) {
- switch (algorithm) {
- case GRPC_STREAM_COMPRESS_NONE:
- return GRPC_MDSTR_IDENTITY;
- case GRPC_STREAM_COMPRESS_GZIP:
- return GRPC_MDSTR_GZIP;
- case GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT:
- return grpc_empty_slice();
- }
- return grpc_empty_slice();
+grpc_compression_algorithm grpc_compression_algorithm_from_slice(
+ grpc_slice str) {
+ if (grpc_slice_eq(str, GRPC_MDSTR_IDENTITY)) return GRPC_COMPRESS_NONE;
+ if (grpc_slice_eq(str, GRPC_MDSTR_MESSAGE_SLASH_DEFLATE)) return GRPC_COMPRESS_MESSAGE_DEFLATE;
+ if (grpc_slice_eq(str, GRPC_MDSTR_MESSAGE_SLASH_GZIP)) return GRPC_COMPRESS_MESSAGE_GZIP;
+ if (grpc_slice_eq(str, GRPC_MDSTR_STREAM_SLASH_GZIP)) return GRPC_COMPRESS_STREAM_GZIP;
+ return GRPC_COMPRESS_ALGORITHMS_COUNT;
}
grpc_mdelem grpc_compression_encoding_mdelem(
@@ -145,9 +164,11 @@ grpc_mdelem grpc_compression_encoding_mdelem(
switch (algorithm) {
case GRPC_COMPRESS_NONE:
return GRPC_MDELEM_GRPC_ENCODING_IDENTITY;
- case GRPC_COMPRESS_DEFLATE:
+ case GRPC_COMPRESS_MESSAGE_DEFLATE:
return GRPC_MDELEM_GRPC_ENCODING_DEFLATE;
- case GRPC_COMPRESS_GZIP:
+ case GRPC_COMPRESS_MESSAGE_GZIP:
+ return GRPC_MDELEM_GRPC_ENCODING_GZIP;
+ case GRPC_COMPRESS_STREAM_GZIP:
return GRPC_MDELEM_GRPC_ENCODING_GZIP;
default:
break;
@@ -155,129 +176,3 @@ grpc_mdelem grpc_compression_encoding_mdelem(
return GRPC_MDNULL;
}
-grpc_mdelem grpc_stream_compression_encoding_mdelem(
- grpc_stream_compression_algorithm algorithm) {
- switch (algorithm) {
- case GRPC_STREAM_COMPRESS_NONE:
- return GRPC_MDELEM_CONTENT_ENCODING_IDENTITY;
- case GRPC_STREAM_COMPRESS_GZIP:
- return GRPC_MDELEM_CONTENT_ENCODING_GZIP;
- default:
- break;
- }
- return GRPC_MDNULL;
-}
-
-void grpc_compression_options_init(grpc_compression_options *opts) {
- memset(opts, 0, sizeof(*opts));
- /* all enabled by default */
- opts->enabled_algorithms_bitset = (1u << GRPC_COMPRESS_ALGORITHMS_COUNT) - 1;
- opts->enabled_stream_compression_algorithms_bitset =
- (1u << GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT) - 1;
-}
-
-void grpc_compression_options_enable_algorithm(
- grpc_compression_options *opts, grpc_compression_algorithm algorithm) {
- GPR_BITSET(&opts->enabled_algorithms_bitset, algorithm);
-}
-
-void grpc_compression_options_disable_algorithm(
- grpc_compression_options *opts, grpc_compression_algorithm algorithm) {
- GPR_BITCLEAR(&opts->enabled_algorithms_bitset, algorithm);
-}
-
-int grpc_compression_options_is_algorithm_enabled(
- const grpc_compression_options *opts,
- grpc_compression_algorithm algorithm) {
- return GPR_BITGET(opts->enabled_algorithms_bitset, algorithm);
-}
-
-int grpc_compression_options_is_stream_compression_algorithm_enabled(
- const grpc_compression_options *opts,
- grpc_stream_compression_algorithm algorithm) {
- return GPR_BITGET(opts->enabled_stream_compression_algorithms_bitset,
- algorithm);
-}
-
-/* TODO(dgq): Add the ability to specify parameters to the individual
- * compression algorithms */
-grpc_compression_algorithm grpc_compression_algorithm_for_level(
- grpc_compression_level level, uint32_t accepted_encodings) {
- GRPC_API_TRACE("grpc_compression_algorithm_for_level(level=%d)", 1,
- ((int)level));
- if (level > GRPC_COMPRESS_LEVEL_HIGH) {
- gpr_log(GPR_ERROR, "Unknown compression level %d.", (int)level);
- abort();
- }
-
- const size_t num_supported =
- GPR_BITCOUNT(accepted_encodings) - 1; /* discard NONE */
- if (level == GRPC_COMPRESS_LEVEL_NONE || num_supported == 0) {
- return GRPC_COMPRESS_NONE;
- }
-
- GPR_ASSERT(level > 0);
-
- /* Establish a "ranking" or compression algorithms in increasing order of
- * compression.
- * This is simplistic and we will probably want to introduce other dimensions
- * in the future (cpu/memory cost, etc). */
- const grpc_compression_algorithm algos_ranking[] = {GRPC_COMPRESS_GZIP,
- GRPC_COMPRESS_DEFLATE};
-
- /* intersect algos_ranking with the supported ones keeping the ranked order */
- grpc_compression_algorithm
- sorted_supported_algos[GRPC_COMPRESS_ALGORITHMS_COUNT];
- size_t algos_supported_idx = 0;
- for (size_t i = 0; i < GPR_ARRAY_SIZE(algos_ranking); i++) {
- const grpc_compression_algorithm alg = algos_ranking[i];
- for (size_t j = 0; j < num_supported; j++) {
- if (GPR_BITGET(accepted_encodings, alg) == 1) {
- /* if \a alg in supported */
- sorted_supported_algos[algos_supported_idx++] = alg;
- break;
- }
- }
- if (algos_supported_idx == num_supported) break;
- }
-
- switch (level) {
- case GRPC_COMPRESS_LEVEL_NONE:
- abort(); /* should have been handled already */
- case GRPC_COMPRESS_LEVEL_LOW:
- return sorted_supported_algos[0];
- case GRPC_COMPRESS_LEVEL_MED:
- return sorted_supported_algos[num_supported / 2];
- case GRPC_COMPRESS_LEVEL_HIGH:
- return sorted_supported_algos[num_supported - 1];
- default:
- abort();
- };
-}
-
-GRPCAPI grpc_stream_compression_algorithm
-grpc_stream_compression_algorithm_for_level(
- grpc_stream_compression_level level, uint32_t accepted_stream_encodings) {
- GRPC_API_TRACE("grpc_stream_compression_algorithm_for_level(level=%d)", 1,
- ((int)level));
- if (level > GRPC_STREAM_COMPRESS_LEVEL_HIGH) {
- gpr_log(GPR_ERROR, "Unknown compression level %d.", (int)level);
- abort();
- }
-
- switch (level) {
- case GRPC_STREAM_COMPRESS_LEVEL_NONE:
- return GRPC_STREAM_COMPRESS_NONE;
- case GRPC_STREAM_COMPRESS_LEVEL_LOW:
- case GRPC_STREAM_COMPRESS_LEVEL_MED:
- case GRPC_STREAM_COMPRESS_LEVEL_HIGH:
- if (GPR_BITGET(accepted_stream_encodings, GRPC_STREAM_COMPRESS_GZIP) ==
- 1) {
- return GRPC_STREAM_COMPRESS_GZIP;
- } else {
- return GRPC_STREAM_COMPRESS_NONE;
- }
- default:
- abort();
- }
-}
diff --git a/src/core/lib/compression/compression_internal.c b/src/core/lib/compression/compression_internal.c
new file mode 100644
index 0000000000..8e0a14dead
--- /dev/null
+++ b/src/core/lib/compression/compression_internal.c
@@ -0,0 +1,310 @@
+/*
+ *
+ * Copyright 2015 gRPC authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+#include <stdlib.h>
+#include <string.h>
+
+#include <grpc/compression.h>
+#include <grpc/support/useful.h>
+
+#include "src/core/lib/compression/algorithm_metadata.h"
+#include "src/core/lib/compression/compression_internal.h"
+#include "src/core/lib/surface/api_trace.h"
+#include "src/core/lib/transport/static_metadata.h"
+
+/* Interfaces related to MD */
+
+grpc_message_compression_algorithm
+grpc_message_compression_algorithm_from_slice(grpc_slice str) {
+ if (grpc_slice_eq(str, GRPC_MDSTR_IDENTITY))
+ return GRPC_MESSAGE_COMPRESS_NONE;
+ if (grpc_slice_eq(str, GRPC_MDSTR_DEFLATE))
+ return GRPC_MESSAGE_COMPRESS_DEFLATE;
+ if (grpc_slice_eq(str, GRPC_MDSTR_GZIP)) return GRPC_MESSAGE_COMPRESS_GZIP;
+ return GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT;
+}
+
+grpc_stream_compression_algorithm grpc_stream_compression_algorithm_from_slice(
+ grpc_slice str) {
+ if (grpc_slice_eq(str, GRPC_MDSTR_IDENTITY)) return GRPC_STREAM_COMPRESS_NONE;
+ if (grpc_slice_eq(str, GRPC_MDSTR_GZIP)) return GRPC_STREAM_COMPRESS_GZIP;
+ return GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT;
+}
+
+grpc_mdelem grpc_message_compression_encoding_mdelem(
+ grpc_message_compression_algorithm algorithm) {
+ switch (algorithm) {
+ case GRPC_MESSAGE_COMPRESS_NONE:
+ return GRPC_MDELEM_GRPC_ENCODING_IDENTITY;
+ case GRPC_MESSAGE_COMPRESS_DEFLATE:
+ return GRPC_MDELEM_GRPC_ENCODING_DEFLATE;
+ case GRPC_MESSAGE_COMPRESS_GZIP:
+ return GRPC_MDELEM_GRPC_ENCODING_GZIP;
+ default:
+ break;
+ }
+ return GRPC_MDNULL;
+}
+
+grpc_mdelem grpc_stream_compression_encoding_mdelem(
+ grpc_stream_compression_algorithm algorithm) {
+ switch (algorithm) {
+ case GRPC_STREAM_COMPRESS_NONE:
+ return GRPC_MDELEM_CONTENT_ENCODING_IDENTITY;
+ case GRPC_STREAM_COMPRESS_GZIP:
+ return GRPC_MDELEM_CONTENT_ENCODING_GZIP;
+ default:
+ break;
+ }
+ return GRPC_MDNULL;
+}
+
+/* Interfaces performing transformation between compression algorithms and
+ * levels. */
+grpc_message_compression_level
+grpc_compression_level_to_message_compression_level(
+ grpc_compression_level level) {
+ if (level >= GRPC_COMPRESS_LEVEL_COUNT) {
+ return GRPC_MESSAGE_COMPRESS_LEVEL_NONE;
+ }
+ return (grpc_message_compression_level)(
+ (uint32_t)(level - GRPC_COMPRESS_LEVEL_NONE) +
+ (uint32_t)GRPC_MESSAGE_COMPRESS_LEVEL_NONE);
+}
+
+grpc_stream_compression_level
+grpc_compression_level_to_stream_compression_level(
+ grpc_compression_level level) {
+ if (level >= GRPC_COMPRESS_LEVEL_COUNT) {
+ return GRPC_STREAM_COMPRESS_LEVEL_NONE;
+ }
+ return (grpc_stream_compression_level)(
+ (uint32_t)(level - (GRPC_MESSAGE_COMPRESS_LEVEL_COUNT - 1) - GRPC_COMPRESS_LEVEL_NONE) +
+ (uint32_t)GRPC_STREAM_COMPRESS_LEVEL_NONE);
+}
+
+grpc_message_compression_algorithm
+grpc_compression_algorithm_to_message_compression_algorithm(
+ grpc_compression_algorithm algo) {
+ switch (algo) {
+ case GRPC_COMPRESS_MESSAGE_DEFLATE:
+ return GRPC_MESSAGE_COMPRESS_DEFLATE;
+ case GRPC_COMPRESS_MESSAGE_GZIP:
+ return GRPC_MESSAGE_COMPRESS_GZIP;
+ default:
+ return GRPC_MESSAGE_COMPRESS_NONE;
+ }
+}
+
+grpc_stream_compression_algorithm
+grpc_compression_algorithm_to_stream_compression_algorithm(
+ grpc_compression_algorithm algo) {
+ switch (algo) {
+ case GRPC_COMPRESS_STREAM_GZIP:
+ return GRPC_STREAM_COMPRESS_GZIP;
+ default:
+ return GRPC_STREAM_COMPRESS_NONE;
+ }
+}
+
+uint32_t grpc_compression_bitset_to_message_bitset(uint32_t bitset) {
+ return bitset & ((1u << GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT) - 1);
+}
+
+uint32_t grpc_compression_bitset_to_stream_bitset(uint32_t bitset) {
+ uint32_t identity = (bitset & 1u);
+ uint32_t other_bits =
+ (bitset >> (GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT - 1)) &
+ ((1u << GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT) - 2);
+ return identity | other_bits;
+}
+
+uint32_t grpc_compression_bitset_from_message_stream_compression_bitset(
+ uint32_t message_bitset, uint32_t stream_bitset) {
+ uint32_t offset_stream_bitset = (stream_bitset & 1u) | ((stream_bitset & (~1u)) << (GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT - 1));
+ return message_bitset | offset_stream_bitset;
+}
+
+int grpc_compression_algorithm_from_message_stream_compression_algorithm(
+ grpc_compression_algorithm *algorithm,
+ grpc_message_compression_algorithm message_algorithm,
+ grpc_stream_compression_algorithm stream_algorithm) {
+ if (message_algorithm != GRPC_MESSAGE_COMPRESS_NONE &&
+ stream_algorithm != GRPC_STREAM_COMPRESS_NONE) {
+ *algorithm = GRPC_COMPRESS_NONE;
+ return 0;
+ }
+ if (message_algorithm == GRPC_MESSAGE_COMPRESS_NONE) {
+ switch (stream_algorithm) {
+ case GRPC_STREAM_COMPRESS_NONE:
+ *algorithm = GRPC_COMPRESS_NONE;
+ return 1;
+ case GRPC_STREAM_COMPRESS_GZIP:
+ *algorithm = GRPC_COMPRESS_STREAM_GZIP;
+ return 1;
+ default:
+ *algorithm = GRPC_COMPRESS_NONE;
+ return 0;
+ }
+ } else {
+ switch (message_algorithm) {
+ case GRPC_MESSAGE_COMPRESS_NONE:
+ *algorithm = GRPC_COMPRESS_NONE;
+ return 1;
+ case GRPC_MESSAGE_COMPRESS_DEFLATE:
+ *algorithm = GRPC_COMPRESS_MESSAGE_DEFLATE;
+ return 1;
+ case GRPC_MESSAGE_COMPRESS_GZIP:
+ *algorithm = GRPC_COMPRESS_MESSAGE_GZIP;
+ return 1;
+ default:
+ *algorithm = GRPC_COMPRESS_NONE;
+ return 0;
+ }
+ }
+ return 0;
+}
+
+/* Interfaces for message compression. */
+
+int grpc_message_compression_algorithm_name(
+ grpc_message_compression_algorithm algorithm, const char **name) {
+ GRPC_API_TRACE("grpc_message_compression_algorithm_parse(algorithm=%d, name=%p)", 2,
+ ((int)algorithm, name));
+ switch (algorithm) {
+ case GRPC_MESSAGE_COMPRESS_NONE:
+ *name = "identity";
+ return 1;
+ case GRPC_MESSAGE_COMPRESS_DEFLATE:
+ *name = "deflate";
+ return 1;
+ case GRPC_MESSAGE_COMPRESS_GZIP:
+ *name = "gzip";
+ return 1;
+ case GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT:
+ return 0;
+ }
+ return 0;
+}
+
+/* TODO(dgq): Add the ability to specify parameters to the individual
+ * compression algorithms */
+grpc_message_compression_algorithm grpc_message_compression_algorithm_for_level(
+ grpc_message_compression_level level, uint32_t accepted_encodings) {
+ GRPC_API_TRACE("grpc_message_compression_algorithm_for_level(level=%d)", 1,
+ ((int)level));
+ if (level > GRPC_MESSAGE_COMPRESS_LEVEL_HIGH) {
+ gpr_log(GPR_ERROR, "Unknown message compression level %d.", (int)level);
+ abort();
+ }
+
+ const size_t num_supported =
+ GPR_BITCOUNT(accepted_encodings) - 1; /* discard NONE */
+ if (level == GRPC_MESSAGE_COMPRESS_LEVEL_NONE || num_supported == 0) {
+ return GRPC_MESSAGE_COMPRESS_NONE;
+ }
+
+ GPR_ASSERT(level > 0);
+
+ /* Establish a "ranking" or compression algorithms in increasing order of
+ * compression.
+ * This is simplistic and we will probably want to introduce other dimensions
+ * in the future (cpu/memory cost, etc). */
+ const grpc_message_compression_algorithm algos_ranking[] = {
+ GRPC_MESSAGE_COMPRESS_GZIP, GRPC_MESSAGE_COMPRESS_DEFLATE};
+
+ /* intersect algos_ranking with the supported ones keeping the ranked order */
+ grpc_message_compression_algorithm
+ sorted_supported_algos[GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT];
+ size_t algos_supported_idx = 0;
+ for (size_t i = 0; i < GPR_ARRAY_SIZE(algos_ranking); i++) {
+ const grpc_message_compression_algorithm alg = algos_ranking[i];
+ for (size_t j = 0; j < num_supported; j++) {
+ if (GPR_BITGET(accepted_encodings, alg) == 1) {
+ /* if \a alg in supported */
+ sorted_supported_algos[algos_supported_idx++] = alg;
+ break;
+ }
+ }
+ if (algos_supported_idx == num_supported) break;
+ }
+
+ switch (level) {
+ case GRPC_MESSAGE_COMPRESS_LEVEL_NONE:
+ abort(); /* should have been handled already */
+ case GRPC_MESSAGE_COMPRESS_LEVEL_LOW:
+ return sorted_supported_algos[0];
+ case GRPC_MESSAGE_COMPRESS_LEVEL_MED:
+ return sorted_supported_algos[num_supported / 2];
+ case GRPC_MESSAGE_COMPRESS_LEVEL_HIGH:
+ return sorted_supported_algos[num_supported - 1];
+ default:
+ abort();
+ };
+}
+
+int grpc_message_compression_algorithm_parse(
+ grpc_slice value, grpc_message_compression_algorithm *algorithm) {
+ if (grpc_slice_eq(value, GRPC_MDSTR_IDENTITY)) {
+ *algorithm = GRPC_MESSAGE_COMPRESS_NONE;
+ return 1;
+ } else if (grpc_slice_eq(value, GRPC_MDSTR_DEFLATE)) {
+ *algorithm = GRPC_MESSAGE_COMPRESS_DEFLATE;
+ return 1;
+ } else if (grpc_slice_eq(value, GRPC_MDSTR_GZIP)) {
+ *algorithm = GRPC_MESSAGE_COMPRESS_GZIP;
+ return 1;
+ } else {
+ return 0;
+ }
+ return 0;
+}
+
+/* Interfaces for stream compression. */
+
+grpc_stream_compression_algorithm grpc_stream_compression_algorithm_for_level(
+ grpc_stream_compression_level level, uint32_t accepted_encodings) {
+ GRPC_API_TRACE("grpc_stream_compression_algorithm_for_level(level=%d)", 1,
+ ((int)level));
+ if (level > GRPC_STREAM_COMPRESS_LEVEL_HIGH) {
+ gpr_log(GPR_ERROR, "Unknown stream compression level %d.", (int)level);
+ abort();
+ }
+
+ /* TODO(mxyan): Use more sophisticated scheme when more algorithms added. */
+ if (level != GRPC_STREAM_COMPRESS_LEVEL_NONE &&
+ GPR_BITGET(accepted_encodings, GRPC_STREAM_COMPRESS_GZIP)) {
+ return GRPC_STREAM_COMPRESS_GZIP;
+ }
+ return GRPC_STREAM_COMPRESS_NONE;
+}
+
+int grpc_stream_compression_algorithm_parse(
+ grpc_slice value, grpc_stream_compression_algorithm *algorithm) {
+ if (grpc_slice_eq(value, GRPC_MDSTR_IDENTITY)) {
+ *algorithm = GRPC_STREAM_COMPRESS_NONE;
+ return 1;
+ } else if (grpc_slice_eq(value, GRPC_MDSTR_GZIP)) {
+ *algorithm = GRPC_STREAM_COMPRESS_GZIP;
+ return 1;
+ } else {
+ return 0;
+ }
+ return 0;
+}
+
diff --git a/src/core/lib/compression/compression_internal.h b/src/core/lib/compression/compression_internal.h
new file mode 100644
index 0000000000..dcd49c8c11
--- /dev/null
+++ b/src/core/lib/compression/compression_internal.h
@@ -0,0 +1,110 @@
+/*
+ *
+ * Copyright 2017 gRPC authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+#ifndef GRPC_CORE_LIB_COMPRESSION_COMPRESSION_INTERNAL_H
+#define GRPC_CORE_LIB_COMPRESSION_COMPRESSION_INTERNAL_H
+
+#include <grpc/impl/codegen/compression_types.h>
+
+typedef enum {
+ GRPC_MESSAGE_COMPRESS_NONE = 0,
+ GRPC_MESSAGE_COMPRESS_DEFLATE,
+ GRPC_MESSAGE_COMPRESS_GZIP,
+ /* TODO(ctiller): snappy */
+ GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT
+} grpc_message_compression_algorithm;
+
+/** Stream compresssion algorithms supported by gRPC */
+typedef enum {
+ GRPC_STREAM_COMPRESS_NONE = 0,
+ GRPC_STREAM_COMPRESS_GZIP,
+ GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT
+} grpc_stream_compression_algorithm;
+
+/** Compression levels allow a party with knowledge of its peer's accepted
+ * encodings to request compression in an abstract way. The level-algorithm
+ * mapping is performed internally and depends on the peer's supported
+ * compression algorithms. */
+typedef enum {
+ GRPC_MESSAGE_COMPRESS_LEVEL_NONE = 0,
+ GRPC_MESSAGE_COMPRESS_LEVEL_LOW,
+ GRPC_MESSAGE_COMPRESS_LEVEL_MED,
+ GRPC_MESSAGE_COMPRESS_LEVEL_HIGH,
+ GRPC_MESSAGE_COMPRESS_LEVEL_COUNT
+} grpc_message_compression_level;
+
+/** Compression levels for stream compression algorithms */
+typedef enum {
+ GRPC_STREAM_COMPRESS_LEVEL_NONE = 0,
+ GRPC_STREAM_COMPRESS_LEVEL_LOW,
+ GRPC_STREAM_COMPRESS_LEVEL_MED,
+ GRPC_STREAM_COMPRESS_LEVEL_HIGH,
+ GRPC_STREAM_COMPRESS_LEVEL_COUNT
+} grpc_stream_compression_level;
+
+/* Interfaces performing transformation between compression algorithms and
+ * levels. */
+
+grpc_message_compression_level
+grpc_compression_level_to_message_compression_level(
+ grpc_compression_level level);
+
+grpc_stream_compression_level
+grpc_compression_level_to_stream_compression_level(
+ grpc_compression_level level);
+
+grpc_message_compression_algorithm
+grpc_compression_algorithm_to_message_compression_algorithm(
+ grpc_compression_algorithm algo);
+
+grpc_stream_compression_algorithm
+grpc_compression_algorithm_to_stream_compression_algorithm(
+ grpc_compression_algorithm algo);
+
+uint32_t grpc_compression_bitset_to_message_bitset(uint32_t bitset);
+
+uint32_t grpc_compression_bitset_to_stream_bitset(uint32_t bitset);
+
+uint32_t grpc_compression_bitset_from_message_stream_compression_bitset(
+ uint32_t message_bitset, uint32_t stream_bitset);
+
+int grpc_compression_algorithm_from_message_stream_compression_algorithm(
+ grpc_compression_algorithm *algorithm,
+ grpc_message_compression_algorithm message_algorithm,
+ grpc_stream_compression_algorithm stream_algorithm);
+
+/* Interfaces for message compression. */
+
+int grpc_message_compression_algorithm_name(
+ grpc_message_compression_algorithm algorithm, const char **name);
+
+grpc_message_compression_algorithm grpc_message_compression_algorithm_for_level(
+ grpc_message_compression_level level, uint32_t accepted_encodings);
+
+int grpc_message_compression_algorithm_parse(
+ grpc_slice value, grpc_message_compression_algorithm *algorithm);
+
+/* Interfaces for stream compression. */
+
+grpc_stream_compression_algorithm grpc_stream_compression_algorithm_for_level(
+ grpc_stream_compression_level level, uint32_t accepted_encodings);
+
+int grpc_stream_compression_algorithm_parse(
+ grpc_slice value, grpc_stream_compression_algorithm *algorithm);
+
+#endif /* GRPC_CORE_LIB_COMPRESSION_COMPRESSION_INTERNAL_H */
diff --git a/src/core/lib/compression/message_compress.c b/src/core/lib/compression/message_compress.c
index c051e28864..d174992355 100644
--- a/src/core/lib/compression/message_compress.c
+++ b/src/core/lib/compression/message_compress.c
@@ -143,18 +143,18 @@ static int copy(grpc_slice_buffer* input, grpc_slice_buffer* output) {
}
static int compress_inner(grpc_exec_ctx* exec_ctx,
- grpc_compression_algorithm algorithm,
+ grpc_message_compression_algorithm algorithm,
grpc_slice_buffer* input, grpc_slice_buffer* output) {
switch (algorithm) {
- case GRPC_COMPRESS_NONE:
+ case GRPC_MESSAGE_COMPRESS_NONE:
/* the fallback path always needs to be send uncompressed: we simply
rely on that here */
return 0;
- case GRPC_COMPRESS_DEFLATE:
+ case GRPC_MESSAGE_COMPRESS_DEFLATE:
return zlib_compress(exec_ctx, input, output, 0);
- case GRPC_COMPRESS_GZIP:
+ case GRPC_MESSAGE_COMPRESS_GZIP:
return zlib_compress(exec_ctx, input, output, 1);
- case GRPC_COMPRESS_ALGORITHMS_COUNT:
+ case GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT:
break;
}
gpr_log(GPR_ERROR, "invalid compression algorithm %d", algorithm);
@@ -162,7 +162,7 @@ static int compress_inner(grpc_exec_ctx* exec_ctx,
}
int grpc_msg_compress(grpc_exec_ctx* exec_ctx,
- grpc_compression_algorithm algorithm,
+ grpc_message_compression_algorithm algorithm,
grpc_slice_buffer* input, grpc_slice_buffer* output) {
if (!compress_inner(exec_ctx, algorithm, input, output)) {
copy(input, output);
@@ -172,16 +172,16 @@ int grpc_msg_compress(grpc_exec_ctx* exec_ctx,
}
int grpc_msg_decompress(grpc_exec_ctx* exec_ctx,
- grpc_compression_algorithm algorithm,
+ grpc_message_compression_algorithm algorithm,
grpc_slice_buffer* input, grpc_slice_buffer* output) {
switch (algorithm) {
- case GRPC_COMPRESS_NONE:
+ case GRPC_MESSAGE_COMPRESS_NONE:
return copy(input, output);
- case GRPC_COMPRESS_DEFLATE:
+ case GRPC_MESSAGE_COMPRESS_DEFLATE:
return zlib_decompress(exec_ctx, input, output, 0);
- case GRPC_COMPRESS_GZIP:
+ case GRPC_MESSAGE_COMPRESS_GZIP:
return zlib_decompress(exec_ctx, input, output, 1);
- case GRPC_COMPRESS_ALGORITHMS_COUNT:
+ case GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT:
break;
}
gpr_log(GPR_ERROR, "invalid compression algorithm %d", algorithm);
diff --git a/src/core/lib/compression/message_compress.h b/src/core/lib/compression/message_compress.h
index ca8ca37f8e..2882bf7075 100644
--- a/src/core/lib/compression/message_compress.h
+++ b/src/core/lib/compression/message_compress.h
@@ -19,21 +19,22 @@
#ifndef GRPC_CORE_LIB_COMPRESSION_MESSAGE_COMPRESS_H
#define GRPC_CORE_LIB_COMPRESSION_MESSAGE_COMPRESS_H
-#include <grpc/compression.h>
#include <grpc/slice_buffer.h>
+#include "src/core/lib/compression/compression_internal.h"
+
/* compress 'input' to 'output' using 'algorithm'.
On success, appends compressed slices to output and returns 1.
On failure, appends uncompressed slices to output and returns 0. */
int grpc_msg_compress(grpc_exec_ctx* exec_ctx,
- grpc_compression_algorithm algorithm,
+ grpc_message_compression_algorithm algorithm,
grpc_slice_buffer* input, grpc_slice_buffer* output);
/* decompress 'input' to 'output' using 'algorithm'.
On success, appends slices to output and returns 1.
On failure, output is unchanged, and returns 0. */
int grpc_msg_decompress(grpc_exec_ctx* exec_ctx,
- grpc_compression_algorithm algorithm,
+ grpc_message_compression_algorithm algorithm,
grpc_slice_buffer* input, grpc_slice_buffer* output);
#endif /* GRPC_CORE_LIB_COMPRESSION_MESSAGE_COMPRESS_H */
diff --git a/src/core/lib/slice/slice_string_helpers.c b/src/core/lib/slice/slice_string_helpers.c
index d461c474d2..e2d8c662f3 100644
--- a/src/core/lib/slice/slice_string_helpers.c
+++ b/src/core/lib/slice/slice_string_helpers.c
@@ -56,24 +56,57 @@ static int slice_find_separator_offset(const grpc_slice str, const char *sep,
return 0;
}
-void grpc_slice_split(grpc_slice str, const char *sep, grpc_slice_buffer *dst) {
+static void skip_leading_trailing_spaces(const uint8_t *str_buffer, size_t *begin, size_t *end) {
+ while (*begin < *end && str_buffer[*begin] == ' ') {
+ (*begin)++;
+ }
+ while (*begin < *end && str_buffer[*end - 1] == ' ') {
+ (*end)--;
+ }
+}
+
+static void grpc_slice_split_inner(grpc_slice str, const char *sep, grpc_slice_buffer *dst, bool no_space) {
const size_t sep_len = strlen(sep);
size_t begin, end;
+ const uint8_t *str_buffer = GRPC_SLICE_START_PTR(str);
+ size_t sep_pos;
GPR_ASSERT(sep_len > 0);
if (slice_find_separator_offset(str, sep, 0, &begin, &end) != 0) {
do {
+ sep_pos = end;
+ if (no_space) {
+ skip_leading_trailing_spaces(str_buffer, &begin, &end);
+ }
grpc_slice_buffer_add_indexed(dst, grpc_slice_sub(str, begin, end));
- } while (slice_find_separator_offset(str, sep, end + sep_len, &begin,
+ } while (slice_find_separator_offset(str, sep, sep_pos + sep_len, &begin,
&end) != 0);
+ begin = sep_pos + sep_len;
+ end = GRPC_SLICE_LENGTH(str);
+ if (no_space) {
+ skip_leading_trailing_spaces(str_buffer, &begin, &end);
+ }
grpc_slice_buffer_add_indexed(
- dst, grpc_slice_sub(str, end + sep_len, GRPC_SLICE_LENGTH(str)));
+ dst, grpc_slice_sub(str, begin, end));
} else { /* no sep found, add whole input */
- grpc_slice_buffer_add_indexed(dst, grpc_slice_ref_internal(str));
+ begin = 0;
+ end = GRPC_SLICE_LENGTH(str);
+ if (no_space) {
+ skip_leading_trailing_spaces(str_buffer, &begin, &end);
+ }
+ grpc_slice_buffer_add_indexed(dst, grpc_slice_sub(str, begin, end));
}
}
+void grpc_slice_split(grpc_slice str, const char *sep, grpc_slice_buffer *dst) {
+ grpc_slice_split_inner(str, sep, dst, false);
+}
+
+void grpc_slice_split_without_space(grpc_slice str, const char *sep, grpc_slice_buffer *dst) {
+ grpc_slice_split_inner(str, sep, dst, true);
+}
+
bool grpc_parse_slice_to_uint32(grpc_slice str, uint32_t *result) {
return gpr_parse_bytes_to_uint32((const char *)GRPC_SLICE_START_PTR(str),
GRPC_SLICE_LENGTH(str), result) != 0;
diff --git a/src/core/lib/slice/slice_string_helpers.h b/src/core/lib/slice/slice_string_helpers.h
index bcfb33bfb3..86125abec3 100644
--- a/src/core/lib/slice/slice_string_helpers.h
+++ b/src/core/lib/slice/slice_string_helpers.h
@@ -39,6 +39,11 @@ char *grpc_dump_slice(grpc_slice slice, uint32_t flags);
* should be a properly initialized instance. */
void grpc_slice_split(grpc_slice str, const char *sep, grpc_slice_buffer *dst);
+/** Split \a str by the separator \a sep and remove the leading and trailing
+ * spaces of each resulting token. Results are stored in \a dst, which should be
+ * a properly initialized instance. */
+void grpc_slice_split_without_space(grpc_slice str, const char *sep, grpc_slice_buffer *dst);
+
bool grpc_parse_slice_to_uint32(grpc_slice str, uint32_t *result);
#ifdef __cplusplus
diff --git a/src/core/lib/surface/byte_buffer_reader.c b/src/core/lib/surface/byte_buffer_reader.c
index 87bd3239c0..58fb46a67d 100644
--- a/src/core/lib/surface/byte_buffer_reader.c
+++ b/src/core/lib/surface/byte_buffer_reader.c
@@ -50,7 +50,7 @@ int grpc_byte_buffer_reader_init(grpc_byte_buffer_reader *reader,
grpc_slice_buffer_init(&decompressed_slices_buffer);
if (is_compressed(reader->buffer_in)) {
if (grpc_msg_decompress(&exec_ctx,
- reader->buffer_in->data.raw.compression,
+ grpc_compression_algorithm_to_message_compression_algorithm(reader->buffer_in->data.raw.compression),
&reader->buffer_in->data.raw.slice_buffer,
&decompressed_slices_buffer) == 0) {
gpr_log(GPR_ERROR,
diff --git a/src/core/lib/surface/call.c b/src/core/lib/surface/call.c
index 03f47553a1..7bc49ce1a3 100644
--- a/src/core/lib/surface/call.c
+++ b/src/core/lib/surface/call.c
@@ -199,7 +199,7 @@ struct grpc_call {
grpc_call_final_info final_info;
/* Compression algorithm for *incoming* data */
- grpc_compression_algorithm incoming_compression_algorithm;
+ grpc_message_compression_algorithm incoming_message_compression_algorithm;
/* Stream compression algorithm for *incoming* data */
grpc_stream_compression_algorithm incoming_stream_compression_algorithm;
/* Supported encodings (compression algorithms), a bitset */
@@ -343,7 +343,7 @@ grpc_error *grpc_call_create(grpc_exec_ctx *exec_ctx,
call->cq = args->cq;
call->start_time = gpr_now(GPR_CLOCK_MONOTONIC);
/* Always support no compression */
- GPR_BITSET(&call->encodings_accepted_by_peer, GRPC_COMPRESS_NONE);
+ GPR_BITSET(&call->encodings_accepted_by_peer, GRPC_MESSAGE_COMPRESS_NONE);
call->is_client = args->server_transport_data == NULL;
if (call->is_client) {
GRPC_STATS_INC_CLIENT_CALLS_CREATED(exec_ctx);
@@ -819,10 +819,10 @@ static void set_status_from_error(grpc_exec_ctx *exec_ctx, grpc_call *call,
* COMPRESSION
*/
-static void set_incoming_compression_algorithm(
- grpc_call *call, grpc_compression_algorithm algo) {
- GPR_ASSERT(algo < GRPC_COMPRESS_ALGORITHMS_COUNT);
- call->incoming_compression_algorithm = algo;
+static void set_incoming_message_compression_algorithm(
+ grpc_call *call, grpc_message_compression_algorithm algo) {
+ GPR_ASSERT(algo < GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT);
+ call->incoming_message_compression_algorithm = algo;
}
static void set_incoming_stream_compression_algorithm(
@@ -831,10 +831,12 @@ static void set_incoming_stream_compression_algorithm(
call->incoming_stream_compression_algorithm = algo;
}
-grpc_compression_algorithm grpc_call_test_only_get_compression_algorithm(
- grpc_call *call) {
- grpc_compression_algorithm algorithm;
- algorithm = call->incoming_compression_algorithm;
+grpc_compression_algorithm
+grpc_call_test_only_get_compression_algorithm(grpc_call *call) {
+ grpc_compression_algorithm algorithm = GRPC_COMPRESS_NONE;
+ grpc_compression_algorithm_from_message_stream_compression_algorithm(
+ &algorithm, call->incoming_message_compression_algorithm,
+ call->incoming_stream_compression_algorithm);
return algorithm;
}
@@ -844,13 +846,6 @@ static grpc_compression_algorithm compression_algorithm_for_level_locked(
call->encodings_accepted_by_peer);
}
-static grpc_stream_compression_algorithm
-stream_compression_algorithm_for_level_locked(
- grpc_call *call, grpc_stream_compression_level level) {
- return grpc_stream_compression_algorithm_for_level(
- level, call->stream_encodings_accepted_by_peer);
-}
-
uint32_t grpc_call_test_only_get_message_flags(grpc_call *call) {
uint32_t flags;
flags = call->test_only_last_message_flags;
@@ -860,9 +855,11 @@ uint32_t grpc_call_test_only_get_message_flags(grpc_call *call) {
static void destroy_encodings_accepted_by_peer(void *p) { return; }
static void set_encodings_accepted_by_peer(grpc_exec_ctx *exec_ctx,
- grpc_call *call, grpc_mdelem mdel) {
+ grpc_call *call, grpc_mdelem mdel,
+ uint32_t *encodings_accepted_by_peer,
+ bool stream_encoding) {
size_t i;
- grpc_compression_algorithm algorithm;
+ uint32_t algorithm;
grpc_slice_buffer accept_encoding_parts;
grpc_slice accept_encoding_slice;
void *accepted_user_data;
@@ -870,70 +867,32 @@ static void set_encodings_accepted_by_peer(grpc_exec_ctx *exec_ctx,
accepted_user_data =
grpc_mdelem_get_user_data(mdel, destroy_encodings_accepted_by_peer);
if (accepted_user_data != NULL) {
- call->encodings_accepted_by_peer =
+ *encodings_accepted_by_peer =
(uint32_t)(((uintptr_t)accepted_user_data) - 1);
return;
}
+ *encodings_accepted_by_peer = 0;
+
accept_encoding_slice = GRPC_MDVALUE(mdel);
grpc_slice_buffer_init(&accept_encoding_parts);
- grpc_slice_split(accept_encoding_slice, ",", &accept_encoding_parts);
+ grpc_slice_split_without_space(accept_encoding_slice, ",", &accept_encoding_parts);
- /* No need to zero call->encodings_accepted_by_peer: grpc_call_create already
- * zeroes the whole grpc_call */
- /* Always support no compression */
- GPR_BITSET(&call->encodings_accepted_by_peer, GRPC_COMPRESS_NONE);
+ GPR_BITSET(encodings_accepted_by_peer, GRPC_COMPRESS_NONE);
for (i = 0; i < accept_encoding_parts.count; i++) {
+ int r;
grpc_slice accept_encoding_entry_slice = accept_encoding_parts.slices[i];
- if (grpc_compression_algorithm_parse(accept_encoding_entry_slice,
- &algorithm)) {
- GPR_BITSET(&call->encodings_accepted_by_peer, algorithm);
+ if (!stream_encoding) {
+ r = grpc_message_compression_algorithm_parse(
+ accept_encoding_entry_slice,
+ (grpc_message_compression_algorithm *)&algorithm);
} else {
- char *accept_encoding_entry_str =
- grpc_slice_to_c_string(accept_encoding_entry_slice);
- gpr_log(GPR_ERROR,
- "Invalid entry in accept encoding metadata: '%s'. Ignoring.",
- accept_encoding_entry_str);
- gpr_free(accept_encoding_entry_str);
+ r = grpc_stream_compression_algorithm_parse(
+ accept_encoding_entry_slice,
+ (grpc_stream_compression_algorithm *)&algorithm);
}
- }
-
- grpc_slice_buffer_destroy_internal(exec_ctx, &accept_encoding_parts);
-
- grpc_mdelem_set_user_data(
- mdel, destroy_encodings_accepted_by_peer,
- (void *)(((uintptr_t)call->encodings_accepted_by_peer) + 1));
-}
-
-static void set_stream_encodings_accepted_by_peer(grpc_exec_ctx *exec_ctx,
- grpc_call *call,
- grpc_mdelem mdel) {
- size_t i;
- grpc_stream_compression_algorithm algorithm;
- grpc_slice_buffer accept_encoding_parts;
- grpc_slice accept_encoding_slice;
- void *accepted_user_data;
-
- accepted_user_data =
- grpc_mdelem_get_user_data(mdel, destroy_encodings_accepted_by_peer);
- if (accepted_user_data != NULL) {
- call->stream_encodings_accepted_by_peer =
- (uint32_t)(((uintptr_t)accepted_user_data) - 1);
- return;
- }
-
- accept_encoding_slice = GRPC_MDVALUE(mdel);
- grpc_slice_buffer_init(&accept_encoding_parts);
- grpc_slice_split(accept_encoding_slice, ",", &accept_encoding_parts);
-
- /* Always support no compression */
- GPR_BITSET(&call->stream_encodings_accepted_by_peer,
- GRPC_STREAM_COMPRESS_NONE);
- for (i = 0; i < accept_encoding_parts.count; i++) {
- grpc_slice accept_encoding_entry_slice = accept_encoding_parts.slices[i];
- if (grpc_stream_compression_algorithm_parse(accept_encoding_entry_slice,
- &algorithm)) {
- GPR_BITSET(&call->stream_encodings_accepted_by_peer, algorithm);
+ if (r) {
+ GPR_BITSET(encodings_accepted_by_peer, algorithm);
} else {
char *accept_encoding_entry_str =
grpc_slice_to_c_string(accept_encoding_entry_slice);
@@ -948,7 +907,7 @@ static void set_stream_encodings_accepted_by_peer(grpc_exec_ctx *exec_ctx,
grpc_mdelem_set_user_data(
mdel, destroy_encodings_accepted_by_peer,
- (void *)(((uintptr_t)call->stream_encodings_accepted_by_peer) + 1));
+ (void *)(((uintptr_t)(*encodings_accepted_by_peer)) + 1));
}
uint32_t grpc_call_test_only_get_encodings_accepted_by_peer(grpc_call *call) {
@@ -957,13 +916,6 @@ uint32_t grpc_call_test_only_get_encodings_accepted_by_peer(grpc_call *call) {
return encodings_accepted_by_peer;
}
-uint32_t grpc_call_test_only_get_stream_encodings_accepted_by_peer(
- grpc_call *call) {
- uint32_t stream_encodings_accepted_by_peer;
- stream_encodings_accepted_by_peer = call->stream_encodings_accepted_by_peer;
- return stream_encodings_accepted_by_peer;
-}
-
grpc_stream_compression_algorithm
grpc_call_test_only_get_incoming_stream_encodings(grpc_call *call) {
return call->incoming_stream_compression_algorithm;
@@ -1065,17 +1017,17 @@ static uint32_t decode_status(grpc_mdelem md) {
return status;
}
-static grpc_compression_algorithm decode_compression(grpc_mdelem md) {
- grpc_compression_algorithm algorithm =
- grpc_compression_algorithm_from_slice(GRPC_MDVALUE(md));
- if (algorithm == GRPC_COMPRESS_ALGORITHMS_COUNT) {
+static grpc_message_compression_algorithm decode_message_compression(grpc_mdelem md) {
+ grpc_message_compression_algorithm algorithm =
+ grpc_message_compression_algorithm_from_slice(GRPC_MDVALUE(md));
+ if (algorithm == GRPC_MESSAGE_COMPRESS_ALGORITHMS_COUNT) {
char *md_c_str = grpc_slice_to_c_string(GRPC_MDVALUE(md));
gpr_log(GPR_ERROR,
- "Invalid incoming compression algorithm: '%s'. Interpreting "
- "incoming data as uncompressed.",
+ "Invalid incoming message compression algorithm: '%s'. "
+ "Interpreting incoming data as uncompressed.",
md_c_str);
gpr_free(md_c_str);
- return GRPC_COMPRESS_NONE;
+ return GRPC_MESSAGE_COMPRESS_NONE;
}
return algorithm;
}
@@ -1121,38 +1073,41 @@ static void publish_app_metadata(grpc_call *call, grpc_metadata_batch *b,
static void recv_initial_filter(grpc_exec_ctx *exec_ctx, grpc_call *call,
grpc_metadata_batch *b) {
if (b->idx.named.content_encoding != NULL) {
- if (b->idx.named.grpc_encoding != NULL) {
- gpr_log(GPR_ERROR,
- "Received both content-encoding and grpc-encoding header. "
- "Ignoring grpc-encoding.");
- grpc_metadata_batch_remove(exec_ctx, b, b->idx.named.grpc_encoding);
- }
GPR_TIMER_BEGIN("incoming_stream_compression_algorithm", 0);
set_incoming_stream_compression_algorithm(
call, decode_stream_compression(b->idx.named.content_encoding->md));
GPR_TIMER_END("incoming_stream_compression_algorithm", 0);
grpc_metadata_batch_remove(exec_ctx, b, b->idx.named.content_encoding);
- } else if (b->idx.named.grpc_encoding != NULL) {
- GPR_TIMER_BEGIN("incoming_compression_algorithm", 0);
- set_incoming_compression_algorithm(
- call, decode_compression(b->idx.named.grpc_encoding->md));
- GPR_TIMER_END("incoming_compression_algorithm", 0);
+ }
+ if (b->idx.named.grpc_encoding != NULL) {
+ GPR_TIMER_BEGIN("incoming_message_compression_algorithm", 0);
+ set_incoming_message_compression_algorithm(
+ call, decode_message_compression(b->idx.named.grpc_encoding->md));
+ GPR_TIMER_END("incoming_message_compression_algorithm", 0);
grpc_metadata_batch_remove(exec_ctx, b, b->idx.named.grpc_encoding);
}
+ uint32_t message_encodings_accepted_by_peer = 1u;
+ uint32_t stream_encodings_accepted_by_peer = 1u;
if (b->idx.named.grpc_accept_encoding != NULL) {
GPR_TIMER_BEGIN("encodings_accepted_by_peer", 0);
set_encodings_accepted_by_peer(exec_ctx, call,
- b->idx.named.grpc_accept_encoding->md);
+ b->idx.named.grpc_accept_encoding->md,
+ &message_encodings_accepted_by_peer, false);
grpc_metadata_batch_remove(exec_ctx, b, b->idx.named.grpc_accept_encoding);
GPR_TIMER_END("encodings_accepted_by_peer", 0);
}
if (b->idx.named.accept_encoding != NULL) {
GPR_TIMER_BEGIN("stream_encodings_accepted_by_peer", 0);
- set_stream_encodings_accepted_by_peer(exec_ctx, call,
- b->idx.named.accept_encoding->md);
+ set_encodings_accepted_by_peer(exec_ctx, call,
+ b->idx.named.accept_encoding->md,
+ &stream_encodings_accepted_by_peer, true);
grpc_metadata_batch_remove(exec_ctx, b, b->idx.named.accept_encoding);
GPR_TIMER_END("stream_encodings_accepted_by_peer", 0);
}
+ call->encodings_accepted_by_peer =
+ grpc_compression_bitset_from_message_stream_compression_bitset(
+ message_encodings_accepted_by_peer,
+ stream_encodings_accepted_by_peer);
publish_app_metadata(call, b, false);
}
@@ -1446,9 +1401,12 @@ static void process_data_after_md(grpc_exec_ctx *exec_ctx,
} else {
call->test_only_last_message_flags = call->receiving_stream->flags;
if ((call->receiving_stream->flags & GRPC_WRITE_INTERNAL_COMPRESS) &&
- (call->incoming_compression_algorithm > GRPC_COMPRESS_NONE)) {
+ (call->incoming_message_compression_algorithm > GRPC_MESSAGE_COMPRESS_NONE)) {
+ grpc_compression_algorithm algo;
+ GPR_ASSERT(grpc_compression_algorithm_from_message_stream_compression_algorithm(
+ &algo, call->incoming_message_compression_algorithm, 0));
*call->receiving_buffer = grpc_raw_compressed_byte_buffer_create(
- NULL, 0, call->incoming_compression_algorithm);
+ NULL, 0, algo);
} else {
*call->receiving_buffer = grpc_raw_byte_buffer_create(NULL, 0);
}
@@ -1494,88 +1452,65 @@ static void receiving_stream_ready_in_call_combiner(grpc_exec_ctx *exec_ctx,
static void validate_filtered_metadata(grpc_exec_ctx *exec_ctx,
batch_control *bctl) {
+ grpc_compression_algorithm compression_algorithm;
grpc_call *call = bctl->call;
- /* validate compression algorithms */
if (call->incoming_stream_compression_algorithm !=
- GRPC_STREAM_COMPRESS_NONE) {
- const grpc_stream_compression_algorithm algo =
- call->incoming_stream_compression_algorithm;
+ GRPC_STREAM_COMPRESS_NONE &&
+ call->incoming_message_compression_algorithm != GRPC_MESSAGE_COMPRESS_NONE) {
char *error_msg = NULL;
- const grpc_compression_options compression_options =
- grpc_channel_compression_options(call->channel);
- if (algo >= GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT) {
- gpr_asprintf(&error_msg,
- "Invalid stream compression algorithm value '%d'.", algo);
- gpr_log(GPR_ERROR, "%s", error_msg);
- cancel_with_status(exec_ctx, call, STATUS_FROM_SURFACE,
- GRPC_STATUS_UNIMPLEMENTED, error_msg);
- } else if (grpc_compression_options_is_stream_compression_algorithm_enabled(
- &compression_options, algo) == 0) {
- /* check if algorithm is supported by current channel config */
- const char *algo_name = NULL;
- grpc_stream_compression_algorithm_name(algo, &algo_name);
- gpr_asprintf(&error_msg, "Stream compression algorithm '%s' is disabled.",
- algo_name);
- gpr_log(GPR_ERROR, "%s", error_msg);
- cancel_with_status(exec_ctx, call, STATUS_FROM_SURFACE,
- GRPC_STATUS_UNIMPLEMENTED, error_msg);
- }
+ gpr_asprintf(&error_msg,
+ "Incoming stream has both stream compression (%d) and message "
+ "compression (%d).",
+ call->incoming_stream_compression_algorithm,
+ call->incoming_message_compression_algorithm);
+ gpr_log(GPR_ERROR, "%s", error_msg);
+ cancel_with_status(exec_ctx, call, STATUS_FROM_SURFACE,
+ GRPC_STATUS_INTERNAL, error_msg);
gpr_free(error_msg);
-
- GPR_ASSERT(call->stream_encodings_accepted_by_peer != 0);
- if (!GPR_BITGET(call->stream_encodings_accepted_by_peer,
- call->incoming_stream_compression_algorithm)) {
- if (GRPC_TRACER_ON(grpc_compression_trace)) {
- const char *algo_name = NULL;
- grpc_stream_compression_algorithm_name(
- call->incoming_stream_compression_algorithm, &algo_name);
- gpr_log(
- GPR_ERROR,
- "Stream compression algorithm (content-encoding = '%s') not "
- "present in the bitset of accepted encodings (accept-encodings: "
- "'0x%x')",
- algo_name, call->stream_encodings_accepted_by_peer);
- }
- }
- } else if (call->incoming_compression_algorithm != GRPC_COMPRESS_NONE) {
- const grpc_compression_algorithm algo =
- call->incoming_compression_algorithm;
+ } else if (
+ grpc_compression_algorithm_from_message_stream_compression_algorithm(
+ &compression_algorithm, call->incoming_message_compression_algorithm,
+ call->incoming_stream_compression_algorithm) == 0) {
+ char *error_msg = NULL;
+ gpr_asprintf(&error_msg,
+ "Error in incoming message compression (%d) or stream "
+ "compression (%d).",
+ call->incoming_stream_compression_algorithm,
+ call->incoming_message_compression_algorithm);
+ cancel_with_status(exec_ctx, call, STATUS_FROM_SURFACE,
+ GRPC_STATUS_INTERNAL, error_msg);
+ gpr_free(error_msg);
+ } else {
char *error_msg = NULL;
const grpc_compression_options compression_options =
grpc_channel_compression_options(call->channel);
- /* check if algorithm is known */
- if (algo >= GRPC_COMPRESS_ALGORITHMS_COUNT) {
+ if (compression_algorithm >= GRPC_COMPRESS_ALGORITHMS_COUNT) {
gpr_asprintf(&error_msg, "Invalid compression algorithm value '%d'.",
- algo);
+ compression_algorithm);
gpr_log(GPR_ERROR, "%s", error_msg);
cancel_with_status(exec_ctx, call, STATUS_FROM_SURFACE,
GRPC_STATUS_UNIMPLEMENTED, error_msg);
} else if (grpc_compression_options_is_algorithm_enabled(
- &compression_options, algo) == 0) {
+ &compression_options, compression_algorithm) == 0) {
/* check if algorithm is supported by current channel config */
const char *algo_name = NULL;
- grpc_compression_algorithm_name(algo, &algo_name);
+ grpc_compression_algorithm_name(compression_algorithm, &algo_name);
gpr_asprintf(&error_msg, "Compression algorithm '%s' is disabled.",
algo_name);
gpr_log(GPR_ERROR, "%s", error_msg);
cancel_with_status(exec_ctx, call, STATUS_FROM_SURFACE,
GRPC_STATUS_UNIMPLEMENTED, error_msg);
- } else {
- call->incoming_compression_algorithm = algo;
}
gpr_free(error_msg);
GPR_ASSERT(call->encodings_accepted_by_peer != 0);
- if (!GPR_BITGET(call->encodings_accepted_by_peer,
- call->incoming_compression_algorithm)) {
+ if (!GPR_BITGET(call->encodings_accepted_by_peer, compression_algorithm)) {
if (GRPC_TRACER_ON(grpc_compression_trace)) {
const char *algo_name = NULL;
- grpc_compression_algorithm_name(call->incoming_compression_algorithm,
- &algo_name);
+ grpc_compression_algorithm_name(compression_algorithm, &algo_name);
gpr_log(GPR_ERROR,
- "Compression algorithm (grpc-encoding = '%s') not present in "
- "the bitset of accepted encodings (grpc-accept-encodings: "
- "'0x%x')",
+ "Compression algorithm ('%s') not present in the bitset of "
+ "accepted encodings ('0x%x')",
algo_name, call->encodings_accepted_by_peer);
}
}
@@ -1728,56 +1663,28 @@ static grpc_call_error call_start_batch(grpc_exec_ctx *exec_ctx,
size_t additional_metadata_count = 0;
grpc_compression_level effective_compression_level =
GRPC_COMPRESS_LEVEL_NONE;
- grpc_stream_compression_level effective_stream_compression_level =
- GRPC_STREAM_COMPRESS_LEVEL_NONE;
bool level_set = false;
- bool stream_compression = false;
- if (op->data.send_initial_metadata.maybe_stream_compression_level
- .is_set) {
- effective_stream_compression_level =
- op->data.send_initial_metadata.maybe_stream_compression_level
- .level;
- level_set = true;
- stream_compression = true;
- } else if (op->data.send_initial_metadata.maybe_compression_level
- .is_set) {
+ if (op->data.send_initial_metadata.maybe_compression_level.is_set) {
effective_compression_level =
op->data.send_initial_metadata.maybe_compression_level.level;
level_set = true;
} else {
const grpc_compression_options copts =
grpc_channel_compression_options(call->channel);
- if (copts.default_stream_compression_level.is_set) {
- level_set = true;
- effective_stream_compression_level =
- copts.default_stream_compression_level.level;
- stream_compression = true;
- } else if (copts.default_level.is_set) {
+ if (copts.default_level.is_set) {
level_set = true;
effective_compression_level = copts.default_level.level;
}
}
if (level_set && !call->is_client) {
- if (stream_compression) {
- const grpc_stream_compression_algorithm calgo =
- stream_compression_algorithm_for_level_locked(
- call, effective_stream_compression_level);
- call->compression_md.key =
- GRPC_MDSTR_GRPC_INTERNAL_STREAM_ENCODING_REQUEST;
- call->compression_md.value =
- grpc_stream_compression_algorithm_slice(calgo);
- } else {
- const grpc_compression_algorithm calgo =
- compression_algorithm_for_level_locked(
- call, effective_compression_level);
- /* the following will be picked up by the compress filter and used
- * as the call's compression algorithm. */
- call->compression_md.key =
- GRPC_MDSTR_GRPC_INTERNAL_ENCODING_REQUEST;
- call->compression_md.value =
- grpc_compression_algorithm_slice(calgo);
- additional_metadata_count++;
- }
+ const grpc_compression_algorithm calgo =
+ compression_algorithm_for_level_locked(
+ call, effective_compression_level);
+ /* the following will be picked up by the compress filter and used
+ * as the call's compression algorithm. */
+ call->compression_md.key = GRPC_MDSTR_GRPC_INTERNAL_ENCODING_REQUEST;
+ call->compression_md.value = grpc_compression_algorithm_slice(calgo);
+ additional_metadata_count++;
}
if (op->data.send_initial_metadata.count + additional_metadata_count >
diff --git a/src/core/lib/surface/call_test_only.h b/src/core/lib/surface/call_test_only.h
index a5a01b3679..e0f4ba31af 100644
--- a/src/core/lib/surface/call_test_only.h
+++ b/src/core/lib/surface/call_test_only.h
@@ -25,7 +25,7 @@
extern "C" {
#endif
-/** Return the compression algorithm from \a call.
+/** Return the message compression algorithm from \a call.
*
* \warning This function should \b only be used in test code. */
grpc_compression_algorithm grpc_call_test_only_get_compression_algorithm(
@@ -42,18 +42,6 @@ uint32_t grpc_call_test_only_get_message_flags(grpc_call *call);
* To be indexed by grpc_compression_algorithm enum values. */
uint32_t grpc_call_test_only_get_encodings_accepted_by_peer(grpc_call *call);
-/** Returns a bitset for the stream encodings (stream compression algorithms)
- * supported by \a call's peer.
- *
- * To be indexed by grpc_stream_compression_algorithm enum values. */
-uint32_t grpc_call_test_only_get_stream_encodings_accepted_by_peer(
- grpc_call *call);
-
-/** Returns the incoming stream compression algorithm (content-encoding header)
- * received by a call. */
-grpc_stream_compression_algorithm
-grpc_call_test_only_get_incoming_stream_encodings(grpc_call *call);
-
#ifdef __cplusplus
}
#endif
diff --git a/src/core/lib/surface/channel.c b/src/core/lib/surface/channel.c
index 48962e5e45..fc7d745463 100644
--- a/src/core/lib/surface/channel.c
+++ b/src/core/lib/surface/channel.c
@@ -148,16 +148,6 @@ grpc_channel *grpc_channel_create_with_builder(
GRPC_COMPRESS_LEVEL_NONE,
GRPC_COMPRESS_LEVEL_COUNT - 1});
} else if (0 == strcmp(args->args[i].key,
- GRPC_STREAM_COMPRESSION_CHANNEL_DEFAULT_LEVEL)) {
- channel->compression_options.default_stream_compression_level.is_set =
- true;
- channel->compression_options.default_stream_compression_level.level =
- (grpc_stream_compression_level)grpc_channel_arg_get_integer(
- &args->args[i],
- (grpc_integer_options){GRPC_STREAM_COMPRESS_LEVEL_NONE,
- GRPC_STREAM_COMPRESS_LEVEL_NONE,
- GRPC_STREAM_COMPRESS_LEVEL_COUNT - 1});
- } else if (0 == strcmp(args->args[i].key,
GRPC_COMPRESSION_CHANNEL_DEFAULT_ALGORITHM)) {
channel->compression_options.default_algorithm.is_set = true;
channel->compression_options.default_algorithm.algorithm =
@@ -165,31 +155,12 @@ grpc_channel *grpc_channel_create_with_builder(
&args->args[i],
(grpc_integer_options){GRPC_COMPRESS_NONE, GRPC_COMPRESS_NONE,
GRPC_COMPRESS_ALGORITHMS_COUNT - 1});
- } else if (0 == strcmp(args->args[i].key,
- GRPC_STREAM_COMPRESSION_CHANNEL_DEFAULT_ALGORITHM)) {
- channel->compression_options.default_stream_compression_algorithm.is_set =
- true;
- channel->compression_options.default_stream_compression_algorithm
- .algorithm =
- (grpc_stream_compression_algorithm)grpc_channel_arg_get_integer(
- &args->args[i],
- (grpc_integer_options){
- GRPC_STREAM_COMPRESS_NONE, GRPC_STREAM_COMPRESS_NONE,
- GRPC_STREAM_COMPRESS_ALGORITHMS_COUNT - 1});
} else if (0 ==
strcmp(args->args[i].key,
GRPC_COMPRESSION_CHANNEL_ENABLED_ALGORITHMS_BITSET)) {
channel->compression_options.enabled_algorithms_bitset =
(uint32_t)args->args[i].value.integer |
0x1; /* always support no compression */
- } else if (0 ==
- strcmp(
- args->args[i].key,
- GRPC_STREAM_COMPRESSION_CHANNEL_ENABLED_ALGORITHMS_BITSET)) {
- channel->compression_options
- .enabled_stream_compression_algorithms_bitset =
- (uint32_t)args->args[i].value.integer |
- 0x1; /* always support no compression */
}
}
diff --git a/src/core/lib/transport/static_metadata.c b/src/core/lib/transport/static_metadata.c
index 472cf888ea..1adf00895f 100644
--- a/src/core/lib/transport/static_metadata.c
+++ b/src/core/lib/transport/static_metadata.c
@@ -1,12 +1,12 @@
/*
* Copyright 2015 gRPC authors.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,10 +16,10 @@
/*
* WARNING: Auto-generated code.
- *
+ *
* To make changes to this file, change
* tools/codegen/core/gen_static_metadata.py, and then re-run it.
- *
+ *
* See metadata.h for an explanation of the interface here, and metadata.c for
* an explanation of what's going on.
*/
@@ -28,313 +28,235 @@
#include "src/core/lib/slice/slice_internal.h"
-static uint8_t g_bytes[] = {
- 58, 112, 97, 116, 104, 58, 109, 101, 116, 104, 111, 100, 58, 115, 116,
- 97, 116, 117, 115, 58, 97, 117, 116, 104, 111, 114, 105, 116, 121, 58,
- 115, 99, 104, 101, 109, 101, 116, 101, 103, 114, 112, 99, 45, 109, 101,
- 115, 115, 97, 103, 101, 103, 114, 112, 99, 45, 115, 116, 97, 116, 117,
- 115, 103, 114, 112, 99, 45, 112, 97, 121, 108, 111, 97, 100, 45, 98,
- 105, 110, 103, 114, 112, 99, 45, 101, 110, 99, 111, 100, 105, 110, 103,
- 103, 114, 112, 99, 45, 97, 99, 99, 101, 112, 116, 45, 101, 110, 99,
- 111, 100, 105, 110, 103, 103, 114, 112, 99, 45, 115, 101, 114, 118, 101,
- 114, 45, 115, 116, 97, 116, 115, 45, 98, 105, 110, 103, 114, 112, 99,
- 45, 116, 97, 103, 115, 45, 98, 105, 110, 103, 114, 112, 99, 45, 116,
- 114, 97, 99, 101, 45, 98, 105, 110, 99, 111, 110, 116, 101, 110, 116,
- 45, 116, 121, 112, 101, 99, 111, 110, 116, 101, 110, 116, 45, 101, 110,
- 99, 111, 100, 105, 110, 103, 97, 99, 99, 101, 112, 116, 45, 101, 110,
- 99, 111, 100, 105, 110, 103, 103, 114, 112, 99, 45, 105, 110, 116, 101,
- 114, 110, 97, 108, 45, 101, 110, 99, 111, 100, 105, 110, 103, 45, 114,
- 101, 113, 117, 101, 115, 116, 103, 114, 112, 99, 45, 105, 110, 116, 101,
- 114, 110, 97, 108, 45, 115, 116, 114, 101, 97, 109, 45, 101, 110, 99,
- 111, 100, 105, 110, 103, 45, 114, 101, 113, 117, 101, 115, 116, 117, 115,
- 101, 114, 45, 97, 103, 101, 110, 116, 104, 111, 115, 116, 108, 98, 45,
- 116, 111, 107, 101, 110, 103, 114, 112, 99, 45, 116, 105, 109, 101, 111,
- 117, 116, 103, 114, 112, 99, 46, 119, 97, 105, 116, 95, 102, 111, 114,
- 95, 114, 101, 97, 100, 121, 103, 114, 112, 99, 46, 116, 105, 109, 101,
- 111, 117, 116, 103, 114, 112, 99, 46, 109, 97, 120, 95, 114, 101, 113,
- 117, 101, 115, 116, 95, 109, 101, 115, 115, 97, 103, 101, 95, 98, 121,
- 116, 101, 115, 103, 114, 112, 99, 46, 109, 97, 120, 95, 114, 101, 115,
- 112, 111, 110, 115, 101, 95, 109, 101, 115, 115, 97, 103, 101, 95, 98,
- 121, 116, 101, 115, 47, 103, 114, 112, 99, 46, 108, 98, 46, 118, 49,
- 46, 76, 111, 97, 100, 66, 97, 108, 97, 110, 99, 101, 114, 47, 66,
- 97, 108, 97, 110, 99, 101, 76, 111, 97, 100, 48, 49, 50, 105, 100,
- 101, 110, 116, 105, 116, 121, 103, 122, 105, 112, 100, 101, 102, 108, 97,
- 116, 101, 116, 114, 97, 105, 108, 101, 114, 115, 97, 112, 112, 108, 105,
- 99, 97, 116, 105, 111, 110, 47, 103, 114, 112, 99, 80, 79, 83, 84,
- 50, 48, 48, 52, 48, 52, 104, 116, 116, 112, 104, 116, 116, 112, 115,
- 103, 114, 112, 99, 71, 69, 84, 80, 85, 84, 47, 47, 105, 110, 100,
- 101, 120, 46, 104, 116, 109, 108, 50, 48, 52, 50, 48, 54, 51, 48,
- 52, 52, 48, 48, 53, 48, 48, 97, 99, 99, 101, 112, 116, 45, 99,
- 104, 97, 114, 115, 101, 116, 103, 122, 105, 112, 44, 32, 100, 101, 102,
- 108, 97, 116, 101, 97, 99, 99, 101, 112, 116, 45, 108, 97, 110, 103,
- 117, 97, 103, 101, 97, 99, 99, 101, 112, 116, 45, 114, 97, 110, 103,
- 101, 115, 97, 99, 99, 101, 112, 116, 97, 99, 99, 101, 115, 115, 45,
- 99, 111, 110, 116, 114, 111, 108, 45, 97, 108, 108, 111, 119, 45, 111,
- 114, 105, 103, 105, 110, 97, 103, 101, 97, 108, 108, 111, 119, 97, 117,
- 116, 104, 111, 114, 105, 122, 97, 116, 105, 111, 110, 99, 97, 99, 104,
- 101, 45, 99, 111, 110, 116, 114, 111, 108, 99, 111, 110, 116, 101, 110,
- 116, 45, 100, 105, 115, 112, 111, 115, 105, 116, 105, 111, 110, 99, 111,
- 110, 116, 101, 110, 116, 45, 108, 97, 110, 103, 117, 97, 103, 101, 99,
- 111, 110, 116, 101, 110, 116, 45, 108, 101, 110, 103, 116, 104, 99, 111,
- 110, 116, 101, 110, 116, 45, 108, 111, 99, 97, 116, 105, 111, 110, 99,
- 111, 110, 116, 101, 110, 116, 45, 114, 97, 110, 103, 101, 99, 111, 111,
- 107, 105, 101, 100, 97, 116, 101, 101, 116, 97, 103, 101, 120, 112, 101,
- 99, 116, 101, 120, 112, 105, 114, 101, 115, 102, 114, 111, 109, 105, 102,
- 45, 109, 97, 116, 99, 104, 105, 102, 45, 109, 111, 100, 105, 102, 105,
- 101, 100, 45, 115, 105, 110, 99, 101, 105, 102, 45, 110, 111, 110, 101,
- 45, 109, 97, 116, 99, 104, 105, 102, 45, 114, 97, 110, 103, 101, 105,
- 102, 45, 117, 110, 109, 111, 100, 105, 102, 105, 101, 100, 45, 115, 105,
- 110, 99, 101, 108, 97, 115, 116, 45, 109, 111, 100, 105, 102, 105, 101,
- 100, 108, 98, 45, 99, 111, 115, 116, 45, 98, 105, 110, 108, 105, 110,
- 107, 108, 111, 99, 97, 116, 105, 111, 110, 109, 97, 120, 45, 102, 111,
- 114, 119, 97, 114, 100, 115, 112, 114, 111, 120, 121, 45, 97, 117, 116,
- 104, 101, 110, 116, 105, 99, 97, 116, 101, 112, 114, 111, 120, 121, 45,
- 97, 117, 116, 104, 111, 114, 105, 122, 97, 116, 105, 111, 110, 114, 97,
- 110, 103, 101, 114, 101, 102, 101, 114, 101, 114, 114, 101, 102, 114, 101,
- 115, 104, 114, 101, 116, 114, 121, 45, 97, 102, 116, 101, 114, 115, 101,
- 114, 118, 101, 114, 115, 101, 116, 45, 99, 111, 111, 107, 105, 101, 115,
- 116, 114, 105, 99, 116, 45, 116, 114, 97, 110, 115, 112, 111, 114, 116,
- 45, 115, 101, 99, 117, 114, 105, 116, 121, 116, 114, 97, 110, 115, 102,
- 101, 114, 45, 101, 110, 99, 111, 100, 105, 110, 103, 118, 97, 114, 121,
- 118, 105, 97, 119, 119, 119, 45, 97, 117, 116, 104, 101, 110, 116, 105,
- 99, 97, 116, 101, 105, 100, 101, 110, 116, 105, 116, 121, 44, 100, 101,
- 102, 108, 97, 116, 101, 105, 100, 101, 110, 116, 105, 116, 121, 44, 103,
- 122, 105, 112, 100, 101, 102, 108, 97, 116, 101, 44, 103, 122, 105, 112,
- 105, 100, 101, 110, 116, 105, 116, 121, 44, 100, 101, 102, 108, 97, 116,
- 101, 44, 103, 122, 105, 112};
+static uint8_t g_bytes[] = {58,112,97,116,104,58,109,101,116,104,111,100,58,115,116,97,116,117,115,58,97,117,116,104,111,114,105,116,121,58,115,99,104,101,109,101,116,101,103,114,112,99,45,109,101,115,115,97,103,101,103,114,112,99,45,115,116,97,116,117,115,103,114,112,99,45,112,97,121,108,111,97,100,45,98,105,110,103,114,112,99,45,101,110,99,111,100,105,110,103,103,114,112,99,45,97,99,99,101,112,116,45,101,110,99,111,100,105,110,103,103,114,112,99,45,115,101,114,118,101,114,45,115,116,97,116,115,45,98,105,110,103,114,112,99,45,116,97,103,115,45,98,105,110,103,114,112,99,45,116,114,97,99,101,45,98,105,110,99,111,110,116,101,110,116,45,116,121,112,101,99,111,110,116,101,110,116,45,101,110,99,111,100,105,110,103,97,99,99,101,112,116,45,101,110,99,111,100,105,110,103,103,114,112,99,45,105,110,116,101,114,110,97,108,45,101,110,99,111,100,105,110,103,45,114,101,113,117,101,115,116,103,114,112,99,45,105,110,116,101,114,110,97,108,45,115,116,114,101,97,109,45,101,110,99,111,100,105,110,103,45,114,101,113,117,101,115,116,117,115,101,114,45,97,103,101,110,116,104,111,115,116,108,98,45,116,111,107,101,110,103,114,112,99,45,116,105,109,101,111,117,116,103,114,112,99,46,119,97,105,116,95,102,111,114,95,114,101,97,100,121,103,114,112,99,46,116,105,109,101,111,117,116,103,114,112,99,46,109,97,120,95,114,101,113,117,101,115,116,95,109,101,115,115,97,103,101,95,98,121,116,101,115,103,114,112,99,46,109,97,120,95,114,101,115,112,111,110,115,101,95,109,101,115,115,97,103,101,95,98,121,116,101,115,47,103,114,112,99,46,108,98,46,118,49,46,76,111,97,100,66,97,108,97,110,99,101,114,47,66,97,108,97,110,99,101,76,111,97,100,109,101,115,115,97,103,101,47,100,101,102,108,97,116,101,109,101,115,115,97,103,101,47,103,122,105,112,115,116,114,101,97,109,47,103,122,105,112,48,49,50,105,100,101,110,116,105,116,121,103,122,105,112,100,101,102,108,97,116,101,116,114,97,105,108,101,114,115,97,112,112,108,105,99,97,116,105,111,110,47,103,114,112,99,80,79,83,84,50,48,48,52,48,52,104,116,116,112,104,116,116,112,115,103,114,112,99,71,69,84,80,85,84,47,47,105,110,100,101,120,46,104,116,109,108,50,48,52,50,48,54,51,48,52,52,48,48,53,48,48,97,99,99,101,112,116,45,99,104,97,114,115,101,116,103,122,105,112,44,32,100,101,102,108,97,116,101,97,99,99,101,112,116,45,108,97,110,103,117,97,103,101,97,99,99,101,112,116,45,114,97,110,103,101,115,97,99,99,101,112,116,97,99,99,101,115,115,45,99,111,110,116,114,111,108,45,97,108,108,111,119,45,111,114,105,103,105,110,97,103,101,97,108,108,111,119,97,117,116,104,111,114,105,122,97,116,105,111,110,99,97,99,104,101,45,99,111,110,116,114,111,108,99,111,110,116,101,110,116,45,100,105,115,112,111,115,105,116,105,111,110,99,111,110,116,101,110,116,45,108,97,110,103,117,97,103,101,99,111,110,116,101,110,116,45,108,101,110,103,116,104,99,111,110,116,101,110,116,45,108,111,99,97,116,105,111,110,99,111,110,116,101,110,116,45,114,97,110,103,101,99,111,111,107,105,101,100,97,116,101,101,116,97,103,101,120,112,101,99,116,101,120,112,105,114,101,115,102,114,111,109,105,102,45,109,97,116,99,104,105,102,45,109,111,100,105,102,105,101,100,45,115,105,110,99,101,105,102,45,110,111,110,101,45,109,97,116,99,104,105,102,45,114,97,110,103,101,105,102,45,117,110,109,111,100,105,102,105,101,100,45,115,105,110,99,101,108,97,115,116,45,109,111,100,105,102,105,101,100,108,98,45,99,111,115,116,45,98,105,110,108,105,110,107,108,111,99,97,116,105,111,110,109,97,120,45,102,111,114,119,97,114,100,115,112,114,111,120,121,45,97,117,116,104,101,110,116,105,99,97,116,101,112,114,111,120,121,45,97,117,116,104,111,114,105,122,97,116,105,111,110,114,97,110,103,101,114,101,102,101,114,101,114,114,101,102,114,101,115,104,114,101,116,114,121,45,97,102,116,101,114,115,101,114,118,101,114,115,101,116,45,99,111,111,107,105,101,115,116,114,105,99,116,45,116,114,97,110,115,112,111,114,116,45,115,101,99,117,114,105,116,121,116,114,97,110,115,102,101,114,45,101,110,99,111,100,105,110,103,118,97,114,121,118,105,97,119,119,119,45,97,117,116,104,101,110,116,105,99,97,116,101,105,100,101,110,116,105,116,121,44,100,101,102,108,97,116,101,105,100,101,110,116,105,116,121,44,103,122,105,112,100,101,102,108,97,116,101,44,103,122,105,112,105,100,101,110,116,105,116,121,44,100,101,102,108,97,116,101,44,103,122,105,112};
static void static_ref(void *unused) {}
static void static_unref(grpc_exec_ctx *exec_ctx, void *unused) {}
-static const grpc_slice_refcount_vtable static_sub_vtable = {
- static_ref, static_unref, grpc_slice_default_eq_impl,
- grpc_slice_default_hash_impl};
-const grpc_slice_refcount_vtable grpc_static_metadata_vtable = {
- static_ref, static_unref, grpc_static_slice_eq, grpc_static_slice_hash};
-static grpc_slice_refcount static_sub_refcnt = {&static_sub_vtable,
- &static_sub_refcnt};
+static const grpc_slice_refcount_vtable static_sub_vtable = {static_ref, static_unref, grpc_slice_default_eq_impl, grpc_slice_default_hash_impl};
+const grpc_slice_refcount_vtable grpc_static_metadata_vtable = {static_ref, static_unref, grpc_static_slice_eq, grpc_static_slice_hash};
+static grpc_slice_refcount static_sub_refcnt = {&static_sub_vtable, &static_sub_refcnt};
grpc_slice_refcount grpc_static_metadata_refcounts[GRPC_STATIC_MDSTR_COUNT] = {
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
- {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
+ {&grpc_static_metadata_vtable, &static_sub_refcnt},
};
const grpc_slice grpc_static_slice_table[GRPC_STATIC_MDSTR_COUNT] = {
- {&grpc_static_metadata_refcounts[0], {{g_bytes + 0, 5}}},
- {&grpc_static_metadata_refcounts[1], {{g_bytes + 5, 7}}},
- {&grpc_static_metadata_refcounts[2], {{g_bytes + 12, 7}}},
- {&grpc_static_metadata_refcounts[3], {{g_bytes + 19, 10}}},
- {&grpc_static_metadata_refcounts[4], {{g_bytes + 29, 7}}},
- {&grpc_static_metadata_refcounts[5], {{g_bytes + 36, 2}}},
- {&grpc_static_metadata_refcounts[6], {{g_bytes + 38, 12}}},
- {&grpc_static_metadata_refcounts[7], {{g_bytes + 50, 11}}},
- {&grpc_static_metadata_refcounts[8], {{g_bytes + 61, 16}}},
- {&grpc_static_metadata_refcounts[9], {{g_bytes + 77, 13}}},
- {&grpc_static_metadata_refcounts[10], {{g_bytes + 90, 20}}},
- {&grpc_static_metadata_refcounts[11], {{g_bytes + 110, 21}}},
- {&grpc_static_metadata_refcounts[12], {{g_bytes + 131, 13}}},
- {&grpc_static_metadata_refcounts[13], {{g_bytes + 144, 14}}},
- {&grpc_static_metadata_refcounts[14], {{g_bytes + 158, 12}}},
- {&grpc_static_metadata_refcounts[15], {{g_bytes + 170, 16}}},
- {&grpc_static_metadata_refcounts[16], {{g_bytes + 186, 15}}},
- {&grpc_static_metadata_refcounts[17], {{g_bytes + 201, 30}}},
- {&grpc_static_metadata_refcounts[18], {{g_bytes + 231, 37}}},
- {&grpc_static_metadata_refcounts[19], {{g_bytes + 268, 10}}},
- {&grpc_static_metadata_refcounts[20], {{g_bytes + 278, 4}}},
- {&grpc_static_metadata_refcounts[21], {{g_bytes + 282, 8}}},
- {&grpc_static_metadata_refcounts[22], {{g_bytes + 290, 12}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}},
- {&grpc_static_metadata_refcounts[24], {{g_bytes + 302, 19}}},
- {&grpc_static_metadata_refcounts[25], {{g_bytes + 321, 12}}},
- {&grpc_static_metadata_refcounts[26], {{g_bytes + 333, 30}}},
- {&grpc_static_metadata_refcounts[27], {{g_bytes + 363, 31}}},
- {&grpc_static_metadata_refcounts[28], {{g_bytes + 394, 36}}},
- {&grpc_static_metadata_refcounts[29], {{g_bytes + 430, 1}}},
- {&grpc_static_metadata_refcounts[30], {{g_bytes + 431, 1}}},
- {&grpc_static_metadata_refcounts[31], {{g_bytes + 432, 1}}},
- {&grpc_static_metadata_refcounts[32], {{g_bytes + 433, 8}}},
- {&grpc_static_metadata_refcounts[33], {{g_bytes + 441, 4}}},
- {&grpc_static_metadata_refcounts[34], {{g_bytes + 445, 7}}},
- {&grpc_static_metadata_refcounts[35], {{g_bytes + 452, 8}}},
- {&grpc_static_metadata_refcounts[36], {{g_bytes + 460, 16}}},
- {&grpc_static_metadata_refcounts[37], {{g_bytes + 476, 4}}},
- {&grpc_static_metadata_refcounts[38], {{g_bytes + 480, 3}}},
- {&grpc_static_metadata_refcounts[39], {{g_bytes + 483, 3}}},
- {&grpc_static_metadata_refcounts[40], {{g_bytes + 486, 4}}},
- {&grpc_static_metadata_refcounts[41], {{g_bytes + 490, 5}}},
- {&grpc_static_metadata_refcounts[42], {{g_bytes + 495, 4}}},
- {&grpc_static_metadata_refcounts[43], {{g_bytes + 499, 3}}},
- {&grpc_static_metadata_refcounts[44], {{g_bytes + 502, 3}}},
- {&grpc_static_metadata_refcounts[45], {{g_bytes + 505, 1}}},
- {&grpc_static_metadata_refcounts[46], {{g_bytes + 506, 11}}},
- {&grpc_static_metadata_refcounts[47], {{g_bytes + 517, 3}}},
- {&grpc_static_metadata_refcounts[48], {{g_bytes + 520, 3}}},
- {&grpc_static_metadata_refcounts[49], {{g_bytes + 523, 3}}},
- {&grpc_static_metadata_refcounts[50], {{g_bytes + 526, 3}}},
- {&grpc_static_metadata_refcounts[51], {{g_bytes + 529, 3}}},
- {&grpc_static_metadata_refcounts[52], {{g_bytes + 532, 14}}},
- {&grpc_static_metadata_refcounts[53], {{g_bytes + 546, 13}}},
- {&grpc_static_metadata_refcounts[54], {{g_bytes + 559, 15}}},
- {&grpc_static_metadata_refcounts[55], {{g_bytes + 574, 13}}},
- {&grpc_static_metadata_refcounts[56], {{g_bytes + 587, 6}}},
- {&grpc_static_metadata_refcounts[57], {{g_bytes + 593, 27}}},
- {&grpc_static_metadata_refcounts[58], {{g_bytes + 620, 3}}},
- {&grpc_static_metadata_refcounts[59], {{g_bytes + 623, 5}}},
- {&grpc_static_metadata_refcounts[60], {{g_bytes + 628, 13}}},
- {&grpc_static_metadata_refcounts[61], {{g_bytes + 641, 13}}},
- {&grpc_static_metadata_refcounts[62], {{g_bytes + 654, 19}}},
- {&grpc_static_metadata_refcounts[63], {{g_bytes + 673, 16}}},
- {&grpc_static_metadata_refcounts[64], {{g_bytes + 689, 14}}},
- {&grpc_static_metadata_refcounts[65], {{g_bytes + 703, 16}}},
- {&grpc_static_metadata_refcounts[66], {{g_bytes + 719, 13}}},
- {&grpc_static_metadata_refcounts[67], {{g_bytes + 732, 6}}},
- {&grpc_static_metadata_refcounts[68], {{g_bytes + 738, 4}}},
- {&grpc_static_metadata_refcounts[69], {{g_bytes + 742, 4}}},
- {&grpc_static_metadata_refcounts[70], {{g_bytes + 746, 6}}},
- {&grpc_static_metadata_refcounts[71], {{g_bytes + 752, 7}}},
- {&grpc_static_metadata_refcounts[72], {{g_bytes + 759, 4}}},
- {&grpc_static_metadata_refcounts[73], {{g_bytes + 763, 8}}},
- {&grpc_static_metadata_refcounts[74], {{g_bytes + 771, 17}}},
- {&grpc_static_metadata_refcounts[75], {{g_bytes + 788, 13}}},
- {&grpc_static_metadata_refcounts[76], {{g_bytes + 801, 8}}},
- {&grpc_static_metadata_refcounts[77], {{g_bytes + 809, 19}}},
- {&grpc_static_metadata_refcounts[78], {{g_bytes + 828, 13}}},
- {&grpc_static_metadata_refcounts[79], {{g_bytes + 841, 11}}},
- {&grpc_static_metadata_refcounts[80], {{g_bytes + 852, 4}}},
- {&grpc_static_metadata_refcounts[81], {{g_bytes + 856, 8}}},
- {&grpc_static_metadata_refcounts[82], {{g_bytes + 864, 12}}},
- {&grpc_static_metadata_refcounts[83], {{g_bytes + 876, 18}}},
- {&grpc_static_metadata_refcounts[84], {{g_bytes + 894, 19}}},
- {&grpc_static_metadata_refcounts[85], {{g_bytes + 913, 5}}},
- {&grpc_static_metadata_refcounts[86], {{g_bytes + 918, 7}}},
- {&grpc_static_metadata_refcounts[87], {{g_bytes + 925, 7}}},
- {&grpc_static_metadata_refcounts[88], {{g_bytes + 932, 11}}},
- {&grpc_static_metadata_refcounts[89], {{g_bytes + 943, 6}}},
- {&grpc_static_metadata_refcounts[90], {{g_bytes + 949, 10}}},
- {&grpc_static_metadata_refcounts[91], {{g_bytes + 959, 25}}},
- {&grpc_static_metadata_refcounts[92], {{g_bytes + 984, 17}}},
- {&grpc_static_metadata_refcounts[93], {{g_bytes + 1001, 4}}},
- {&grpc_static_metadata_refcounts[94], {{g_bytes + 1005, 3}}},
- {&grpc_static_metadata_refcounts[95], {{g_bytes + 1008, 16}}},
- {&grpc_static_metadata_refcounts[96], {{g_bytes + 1024, 16}}},
- {&grpc_static_metadata_refcounts[97], {{g_bytes + 1040, 13}}},
- {&grpc_static_metadata_refcounts[98], {{g_bytes + 1053, 12}}},
- {&grpc_static_metadata_refcounts[99], {{g_bytes + 1065, 21}}},
+{&grpc_static_metadata_refcounts[0], {{g_bytes+0, 5}}},
+{&grpc_static_metadata_refcounts[1], {{g_bytes+5, 7}}},
+{&grpc_static_metadata_refcounts[2], {{g_bytes+12, 7}}},
+{&grpc_static_metadata_refcounts[3], {{g_bytes+19, 10}}},
+{&grpc_static_metadata_refcounts[4], {{g_bytes+29, 7}}},
+{&grpc_static_metadata_refcounts[5], {{g_bytes+36, 2}}},
+{&grpc_static_metadata_refcounts[6], {{g_bytes+38, 12}}},
+{&grpc_static_metadata_refcounts[7], {{g_bytes+50, 11}}},
+{&grpc_static_metadata_refcounts[8], {{g_bytes+61, 16}}},
+{&grpc_static_metadata_refcounts[9], {{g_bytes+77, 13}}},
+{&grpc_static_metadata_refcounts[10], {{g_bytes+90, 20}}},
+{&grpc_static_metadata_refcounts[11], {{g_bytes+110, 21}}},
+{&grpc_static_metadata_refcounts[12], {{g_bytes+131, 13}}},
+{&grpc_static_metadata_refcounts[13], {{g_bytes+144, 14}}},
+{&grpc_static_metadata_refcounts[14], {{g_bytes+158, 12}}},
+{&grpc_static_metadata_refcounts[15], {{g_bytes+170, 16}}},
+{&grpc_static_metadata_refcounts[16], {{g_bytes+186, 15}}},
+{&grpc_static_metadata_refcounts[17], {{g_bytes+201, 30}}},
+{&grpc_static_metadata_refcounts[18], {{g_bytes+231, 37}}},
+{&grpc_static_metadata_refcounts[19], {{g_bytes+268, 10}}},
+{&grpc_static_metadata_refcounts[20], {{g_bytes+278, 4}}},
+{&grpc_static_metadata_refcounts[21], {{g_bytes+282, 8}}},
+{&grpc_static_metadata_refcounts[22], {{g_bytes+290, 12}}},
+{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}},
+{&grpc_static_metadata_refcounts[24], {{g_bytes+302, 19}}},
+{&grpc_static_metadata_refcounts[25], {{g_bytes+321, 12}}},
+{&grpc_static_metadata_refcounts[26], {{g_bytes+333, 30}}},
+{&grpc_static_metadata_refcounts[27], {{g_bytes+363, 31}}},
+{&grpc_static_metadata_refcounts[28], {{g_bytes+394, 36}}},
+{&grpc_static_metadata_refcounts[29], {{g_bytes+430, 15}}},
+{&grpc_static_metadata_refcounts[30], {{g_bytes+445, 12}}},
+{&grpc_static_metadata_refcounts[31], {{g_bytes+457, 11}}},
+{&grpc_static_metadata_refcounts[32], {{g_bytes+468, 1}}},
+{&grpc_static_metadata_refcounts[33], {{g_bytes+469, 1}}},
+{&grpc_static_metadata_refcounts[34], {{g_bytes+470, 1}}},
+{&grpc_static_metadata_refcounts[35], {{g_bytes+471, 8}}},
+{&grpc_static_metadata_refcounts[36], {{g_bytes+479, 4}}},
+{&grpc_static_metadata_refcounts[37], {{g_bytes+483, 7}}},
+{&grpc_static_metadata_refcounts[38], {{g_bytes+490, 8}}},
+{&grpc_static_metadata_refcounts[39], {{g_bytes+498, 16}}},
+{&grpc_static_metadata_refcounts[40], {{g_bytes+514, 4}}},
+{&grpc_static_metadata_refcounts[41], {{g_bytes+518, 3}}},
+{&grpc_static_metadata_refcounts[42], {{g_bytes+521, 3}}},
+{&grpc_static_metadata_refcounts[43], {{g_bytes+524, 4}}},
+{&grpc_static_metadata_refcounts[44], {{g_bytes+528, 5}}},
+{&grpc_static_metadata_refcounts[45], {{g_bytes+533, 4}}},
+{&grpc_static_metadata_refcounts[46], {{g_bytes+537, 3}}},
+{&grpc_static_metadata_refcounts[47], {{g_bytes+540, 3}}},
+{&grpc_static_metadata_refcounts[48], {{g_bytes+543, 1}}},
+{&grpc_static_metadata_refcounts[49], {{g_bytes+544, 11}}},
+{&grpc_static_metadata_refcounts[50], {{g_bytes+555, 3}}},
+{&grpc_static_metadata_refcounts[51], {{g_bytes+558, 3}}},
+{&grpc_static_metadata_refcounts[52], {{g_bytes+561, 3}}},
+{&grpc_static_metadata_refcounts[53], {{g_bytes+564, 3}}},
+{&grpc_static_metadata_refcounts[54], {{g_bytes+567, 3}}},
+{&grpc_static_metadata_refcounts[55], {{g_bytes+570, 14}}},
+{&grpc_static_metadata_refcounts[56], {{g_bytes+584, 13}}},
+{&grpc_static_metadata_refcounts[57], {{g_bytes+597, 15}}},
+{&grpc_static_metadata_refcounts[58], {{g_bytes+612, 13}}},
+{&grpc_static_metadata_refcounts[59], {{g_bytes+625, 6}}},
+{&grpc_static_metadata_refcounts[60], {{g_bytes+631, 27}}},
+{&grpc_static_metadata_refcounts[61], {{g_bytes+658, 3}}},
+{&grpc_static_metadata_refcounts[62], {{g_bytes+661, 5}}},
+{&grpc_static_metadata_refcounts[63], {{g_bytes+666, 13}}},
+{&grpc_static_metadata_refcounts[64], {{g_bytes+679, 13}}},
+{&grpc_static_metadata_refcounts[65], {{g_bytes+692, 19}}},
+{&grpc_static_metadata_refcounts[66], {{g_bytes+711, 16}}},
+{&grpc_static_metadata_refcounts[67], {{g_bytes+727, 14}}},
+{&grpc_static_metadata_refcounts[68], {{g_bytes+741, 16}}},
+{&grpc_static_metadata_refcounts[69], {{g_bytes+757, 13}}},
+{&grpc_static_metadata_refcounts[70], {{g_bytes+770, 6}}},
+{&grpc_static_metadata_refcounts[71], {{g_bytes+776, 4}}},
+{&grpc_static_metadata_refcounts[72], {{g_bytes+780, 4}}},
+{&grpc_static_metadata_refcounts[73], {{g_bytes+784, 6}}},
+{&grpc_static_metadata_refcounts[74], {{g_bytes+790, 7}}},
+{&grpc_static_metadata_refcounts[75], {{g_bytes+797, 4}}},
+{&grpc_static_metadata_refcounts[76], {{g_bytes+801, 8}}},
+{&grpc_static_metadata_refcounts[77], {{g_bytes+809, 17}}},
+{&grpc_static_metadata_refcounts[78], {{g_bytes+826, 13}}},
+{&grpc_static_metadata_refcounts[79], {{g_bytes+839, 8}}},
+{&grpc_static_metadata_refcounts[80], {{g_bytes+847, 19}}},
+{&grpc_static_metadata_refcounts[81], {{g_bytes+866, 13}}},
+{&grpc_static_metadata_refcounts[82], {{g_bytes+879, 11}}},
+{&grpc_static_metadata_refcounts[83], {{g_bytes+890, 4}}},
+{&grpc_static_metadata_refcounts[84], {{g_bytes+894, 8}}},
+{&grpc_static_metadata_refcounts[85], {{g_bytes+902, 12}}},
+{&grpc_static_metadata_refcounts[86], {{g_bytes+914, 18}}},
+{&grpc_static_metadata_refcounts[87], {{g_bytes+932, 19}}},
+{&grpc_static_metadata_refcounts[88], {{g_bytes+951, 5}}},
+{&grpc_static_metadata_refcounts[89], {{g_bytes+956, 7}}},
+{&grpc_static_metadata_refcounts[90], {{g_bytes+963, 7}}},
+{&grpc_static_metadata_refcounts[91], {{g_bytes+970, 11}}},
+{&grpc_static_metadata_refcounts[92], {{g_bytes+981, 6}}},
+{&grpc_static_metadata_refcounts[93], {{g_bytes+987, 10}}},
+{&grpc_static_metadata_refcounts[94], {{g_bytes+997, 25}}},
+{&grpc_static_metadata_refcounts[95], {{g_bytes+1022, 17}}},
+{&grpc_static_metadata_refcounts[96], {{g_bytes+1039, 4}}},
+{&grpc_static_metadata_refcounts[97], {{g_bytes+1043, 3}}},
+{&grpc_static_metadata_refcounts[98], {{g_bytes+1046, 16}}},
+{&grpc_static_metadata_refcounts[99], {{g_bytes+1062, 16}}},
+{&grpc_static_metadata_refcounts[100], {{g_bytes+1078, 13}}},
+{&grpc_static_metadata_refcounts[101], {{g_bytes+1091, 12}}},
+{&grpc_static_metadata_refcounts[102], {{g_bytes+1103, 21}}},
};
uintptr_t grpc_static_mdelem_user_data[GRPC_STATIC_MDELEM_COUNT] = {
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 6, 6, 8, 8, 2, 4, 4};
+ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,4,4,6,6,8,8,2,4,4
+};
+
-static const int8_t elems_r[] = {
- 11, 9, -3, 0, 10, 27, -74, 28, 0, 14, -7, 0, 0, 0, 18, 8, -2,
- 0, 0, 13, 12, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, -50, 0, -33, -55, -56, -57, -58, -57, 0, 40, 39, 38, 37, 36, 35, 34,
- 33, 32, 31, 30, 29, 28, 28, 27, 26, 25, 24, 23, 22, 21, 20, 19, 22,
- 21, 20, 19, 18, 17, 16, 15, 14, 13, 12, 12, 11, 0};
+static const int8_t elems_r[] = {11,9,-3,0,10,25,-77,26,0,11,-7,0,0,0,21,14,1,0,0,33,12,11,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,-56,0,-36,-61,-60,-39,-63,-64,0,36,35,34,33,34,33,32,31,31,30,29,28,27,26,26,25,25,24,23,22,21,20,19,22,21,20,19,18,17,16,15,14,13,12,12,11,0};
static uint32_t elems_phash(uint32_t i) {
- i -= 45;
- uint32_t x = i % 98;
- uint32_t y = i / 98;
+ i -= 48;
+ uint32_t x = i % 101;
+ uint32_t y = i / 101;
uint32_t h = x;
if (y < GPR_ARRAY_SIZE(elems_r)) {
uint32_t delta = (uint32_t)elems_r[y];
@@ -342,241 +264,134 @@ static uint32_t elems_phash(uint32_t i) {
}
return h;
}
-
-static const uint16_t elem_keys[] = {
- 1032, 1033, 1034, 247, 248, 249, 250, 251, 1623, 143, 144, 45,
- 46, 440, 441, 442, 1523, 1632, 1633, 932, 933, 934, 729, 730,
- 1423, 1532, 1533, 535, 731, 1923, 2023, 2123, 5223, 5523, 5623, 5723,
- 5823, 1436, 1653, 5923, 6023, 6123, 6223, 6323, 6423, 6523, 6623, 6723,
- 6823, 6923, 7023, 7123, 7223, 5423, 7323, 7423, 7523, 7623, 7723, 7823,
- 7923, 8023, 8123, 8223, 1096, 1097, 1098, 1099, 8323, 8423, 8523, 8623,
- 8723, 8823, 8923, 9023, 9123, 9223, 9323, 323, 9423, 9523, 1697, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 137, 238, 239, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0};
-static const uint8_t elem_idxs[] = {
- 76, 79, 77, 19, 20, 21, 22, 23, 25, 15, 16, 17, 18, 11,
- 12, 13, 38, 83, 84, 3, 4, 5, 0, 1, 43, 36, 37, 6,
- 2, 72, 50, 57, 24, 28, 29, 30, 31, 7, 26, 32, 33, 34,
- 35, 39, 40, 41, 42, 44, 45, 46, 47, 48, 49, 27, 51, 52,
- 53, 54, 55, 56, 58, 59, 60, 61, 78, 80, 81, 82, 62, 63,
- 64, 65, 66, 67, 68, 69, 70, 71, 73, 14, 74, 75, 85, 255,
- 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
- 255, 255, 255, 255, 255, 8, 9, 10};
+
+static const uint16_t elem_keys[] = {1065,1066,1067,256,257,258,259,260,1671,149,150,48,49,455,456,457,962,963,964,1568,1683,1684,753,754,1465,553,755,2083,2186,5688,5997,1580,1581,6100,6306,6409,6512,6615,6718,6821,1481,1704,6924,7027,7130,7233,1980,7336,7439,7542,7645,7748,7851,5894,7954,8057,6203,8160,8263,8366,8469,8572,8675,8778,1129,1130,1131,1132,8881,8984,9087,9190,9293,9396,9499,9602,9705,9808,9911,332,10014,10117,0,0,0,1748,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,143,247,248,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
+static const uint8_t elem_idxs[] = {76,79,77,19,20,21,22,23,25,15,16,17,18,11,12,13,3,4,5,38,83,84,0,1,43,6,2,50,57,24,28,36,37,29,31,32,33,34,35,39,7,26,40,41,42,44,72,45,46,47,48,49,51,27,52,53,30,54,55,56,58,59,60,61,78,80,81,82,62,63,64,65,66,67,68,69,70,71,73,14,74,75,255,255,255,85,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,8,9,10};
grpc_mdelem grpc_static_mdelem_for_static_strings(int a, int b) {
if (a == -1 || b == -1) return GRPC_MDNULL;
- uint32_t k = (uint32_t)(a * 100 + b);
+ uint32_t k = (uint32_t)(a * 103 + b);
uint32_t h = elems_phash(k);
- return h < GPR_ARRAY_SIZE(elem_keys) && elem_keys[h] == k &&
- elem_idxs[h] != 255
- ? GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[elem_idxs[h]],
- GRPC_MDELEM_STORAGE_STATIC)
- : GRPC_MDNULL;
+ return h < GPR_ARRAY_SIZE(elem_keys) && elem_keys[h] == k && elem_idxs[h] != 255 ? GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[elem_idxs[h]], GRPC_MDELEM_STORAGE_STATIC) : GRPC_MDNULL;
}
grpc_mdelem_data grpc_static_mdelem_table[GRPC_STATIC_MDELEM_COUNT] = {
- {{&grpc_static_metadata_refcounts[7], {{g_bytes + 50, 11}}},
- {&grpc_static_metadata_refcounts[29], {{g_bytes + 430, 1}}}},
- {{&grpc_static_metadata_refcounts[7], {{g_bytes + 50, 11}}},
- {&grpc_static_metadata_refcounts[30], {{g_bytes + 431, 1}}}},
- {{&grpc_static_metadata_refcounts[7], {{g_bytes + 50, 11}}},
- {&grpc_static_metadata_refcounts[31], {{g_bytes + 432, 1}}}},
- {{&grpc_static_metadata_refcounts[9], {{g_bytes + 77, 13}}},
- {&grpc_static_metadata_refcounts[32], {{g_bytes + 433, 8}}}},
- {{&grpc_static_metadata_refcounts[9], {{g_bytes + 77, 13}}},
- {&grpc_static_metadata_refcounts[33], {{g_bytes + 441, 4}}}},
- {{&grpc_static_metadata_refcounts[9], {{g_bytes + 77, 13}}},
- {&grpc_static_metadata_refcounts[34], {{g_bytes + 445, 7}}}},
- {{&grpc_static_metadata_refcounts[5], {{g_bytes + 36, 2}}},
- {&grpc_static_metadata_refcounts[35], {{g_bytes + 452, 8}}}},
- {{&grpc_static_metadata_refcounts[14], {{g_bytes + 158, 12}}},
- {&grpc_static_metadata_refcounts[36], {{g_bytes + 460, 16}}}},
- {{&grpc_static_metadata_refcounts[1], {{g_bytes + 5, 7}}},
- {&grpc_static_metadata_refcounts[37], {{g_bytes + 476, 4}}}},
- {{&grpc_static_metadata_refcounts[2], {{g_bytes + 12, 7}}},
- {&grpc_static_metadata_refcounts[38], {{g_bytes + 480, 3}}}},
- {{&grpc_static_metadata_refcounts[2], {{g_bytes + 12, 7}}},
- {&grpc_static_metadata_refcounts[39], {{g_bytes + 483, 3}}}},
- {{&grpc_static_metadata_refcounts[4], {{g_bytes + 29, 7}}},
- {&grpc_static_metadata_refcounts[40], {{g_bytes + 486, 4}}}},
- {{&grpc_static_metadata_refcounts[4], {{g_bytes + 29, 7}}},
- {&grpc_static_metadata_refcounts[41], {{g_bytes + 490, 5}}}},
- {{&grpc_static_metadata_refcounts[4], {{g_bytes + 29, 7}}},
- {&grpc_static_metadata_refcounts[42], {{g_bytes + 495, 4}}}},
- {{&grpc_static_metadata_refcounts[3], {{g_bytes + 19, 10}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[1], {{g_bytes + 5, 7}}},
- {&grpc_static_metadata_refcounts[43], {{g_bytes + 499, 3}}}},
- {{&grpc_static_metadata_refcounts[1], {{g_bytes + 5, 7}}},
- {&grpc_static_metadata_refcounts[44], {{g_bytes + 502, 3}}}},
- {{&grpc_static_metadata_refcounts[0], {{g_bytes + 0, 5}}},
- {&grpc_static_metadata_refcounts[45], {{g_bytes + 505, 1}}}},
- {{&grpc_static_metadata_refcounts[0], {{g_bytes + 0, 5}}},
- {&grpc_static_metadata_refcounts[46], {{g_bytes + 506, 11}}}},
- {{&grpc_static_metadata_refcounts[2], {{g_bytes + 12, 7}}},
- {&grpc_static_metadata_refcounts[47], {{g_bytes + 517, 3}}}},
- {{&grpc_static_metadata_refcounts[2], {{g_bytes + 12, 7}}},
- {&grpc_static_metadata_refcounts[48], {{g_bytes + 520, 3}}}},
- {{&grpc_static_metadata_refcounts[2], {{g_bytes + 12, 7}}},
- {&grpc_static_metadata_refcounts[49], {{g_bytes + 523, 3}}}},
- {{&grpc_static_metadata_refcounts[2], {{g_bytes + 12, 7}}},
- {&grpc_static_metadata_refcounts[50], {{g_bytes + 526, 3}}}},
- {{&grpc_static_metadata_refcounts[2], {{g_bytes + 12, 7}}},
- {&grpc_static_metadata_refcounts[51], {{g_bytes + 529, 3}}}},
- {{&grpc_static_metadata_refcounts[52], {{g_bytes + 532, 14}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[16], {{g_bytes + 186, 15}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[16], {{g_bytes + 186, 15}}},
- {&grpc_static_metadata_refcounts[53], {{g_bytes + 546, 13}}}},
- {{&grpc_static_metadata_refcounts[54], {{g_bytes + 559, 15}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[55], {{g_bytes + 574, 13}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[56], {{g_bytes + 587, 6}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[57], {{g_bytes + 593, 27}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[58], {{g_bytes + 620, 3}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[59], {{g_bytes + 623, 5}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[60], {{g_bytes + 628, 13}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[61], {{g_bytes + 641, 13}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[62], {{g_bytes + 654, 19}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[15], {{g_bytes + 170, 16}}},
- {&grpc_static_metadata_refcounts[32], {{g_bytes + 433, 8}}}},
- {{&grpc_static_metadata_refcounts[15], {{g_bytes + 170, 16}}},
- {&grpc_static_metadata_refcounts[33], {{g_bytes + 441, 4}}}},
- {{&grpc_static_metadata_refcounts[15], {{g_bytes + 170, 16}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[63], {{g_bytes + 673, 16}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[64], {{g_bytes + 689, 14}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[65], {{g_bytes + 703, 16}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[66], {{g_bytes + 719, 13}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[14], {{g_bytes + 158, 12}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[67], {{g_bytes + 732, 6}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[68], {{g_bytes + 738, 4}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[69], {{g_bytes + 742, 4}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[70], {{g_bytes + 746, 6}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[71], {{g_bytes + 752, 7}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[72], {{g_bytes + 759, 4}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[20], {{g_bytes + 278, 4}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[73], {{g_bytes + 763, 8}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[74], {{g_bytes + 771, 17}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[75], {{g_bytes + 788, 13}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[76], {{g_bytes + 801, 8}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[77], {{g_bytes + 809, 19}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[78], {{g_bytes + 828, 13}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[21], {{g_bytes + 282, 8}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[79], {{g_bytes + 841, 11}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[80], {{g_bytes + 852, 4}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[81], {{g_bytes + 856, 8}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[82], {{g_bytes + 864, 12}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[83], {{g_bytes + 876, 18}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[84], {{g_bytes + 894, 19}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[85], {{g_bytes + 913, 5}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[86], {{g_bytes + 918, 7}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[87], {{g_bytes + 925, 7}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[88], {{g_bytes + 932, 11}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[89], {{g_bytes + 943, 6}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[90], {{g_bytes + 949, 10}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[91], {{g_bytes + 959, 25}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[92], {{g_bytes + 984, 17}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[19], {{g_bytes + 268, 10}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[93], {{g_bytes + 1001, 4}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[94], {{g_bytes + 1005, 3}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[95], {{g_bytes + 1008, 16}}},
- {&grpc_static_metadata_refcounts[23], {{g_bytes + 302, 0}}}},
- {{&grpc_static_metadata_refcounts[10], {{g_bytes + 90, 20}}},
- {&grpc_static_metadata_refcounts[32], {{g_bytes + 433, 8}}}},
- {{&grpc_static_metadata_refcounts[10], {{g_bytes + 90, 20}}},
- {&grpc_static_metadata_refcounts[34], {{g_bytes + 445, 7}}}},
- {{&grpc_static_metadata_refcounts[10], {{g_bytes + 90, 20}}},
- {&grpc_static_metadata_refcounts[96], {{g_bytes + 1024, 16}}}},
- {{&grpc_static_metadata_refcounts[10], {{g_bytes + 90, 20}}},
- {&grpc_static_metadata_refcounts[33], {{g_bytes + 441, 4}}}},
- {{&grpc_static_metadata_refcounts[10], {{g_bytes + 90, 20}}},
- {&grpc_static_metadata_refcounts[97], {{g_bytes + 1040, 13}}}},
- {{&grpc_static_metadata_refcounts[10], {{g_bytes + 90, 20}}},
- {&grpc_static_metadata_refcounts[98], {{g_bytes + 1053, 12}}}},
- {{&grpc_static_metadata_refcounts[10], {{g_bytes + 90, 20}}},
- {&grpc_static_metadata_refcounts[99], {{g_bytes + 1065, 21}}}},
- {{&grpc_static_metadata_refcounts[16], {{g_bytes + 186, 15}}},
- {&grpc_static_metadata_refcounts[32], {{g_bytes + 433, 8}}}},
- {{&grpc_static_metadata_refcounts[16], {{g_bytes + 186, 15}}},
- {&grpc_static_metadata_refcounts[33], {{g_bytes + 441, 4}}}},
- {{&grpc_static_metadata_refcounts[16], {{g_bytes + 186, 15}}},
- {&grpc_static_metadata_refcounts[97], {{g_bytes + 1040, 13}}}},
+{{&grpc_static_metadata_refcounts[7], {{g_bytes+50, 11}}},{&grpc_static_metadata_refcounts[32], {{g_bytes+468, 1}}}},
+{{&grpc_static_metadata_refcounts[7], {{g_bytes+50, 11}}},{&grpc_static_metadata_refcounts[33], {{g_bytes+469, 1}}}},
+{{&grpc_static_metadata_refcounts[7], {{g_bytes+50, 11}}},{&grpc_static_metadata_refcounts[34], {{g_bytes+470, 1}}}},
+{{&grpc_static_metadata_refcounts[9], {{g_bytes+77, 13}}},{&grpc_static_metadata_refcounts[35], {{g_bytes+471, 8}}}},
+{{&grpc_static_metadata_refcounts[9], {{g_bytes+77, 13}}},{&grpc_static_metadata_refcounts[36], {{g_bytes+479, 4}}}},
+{{&grpc_static_metadata_refcounts[9], {{g_bytes+77, 13}}},{&grpc_static_metadata_refcounts[37], {{g_bytes+483, 7}}}},
+{{&grpc_static_metadata_refcounts[5], {{g_bytes+36, 2}}},{&grpc_static_metadata_refcounts[38], {{g_bytes+490, 8}}}},
+{{&grpc_static_metadata_refcounts[14], {{g_bytes+158, 12}}},{&grpc_static_metadata_refcounts[39], {{g_bytes+498, 16}}}},
+{{&grpc_static_metadata_refcounts[1], {{g_bytes+5, 7}}},{&grpc_static_metadata_refcounts[40], {{g_bytes+514, 4}}}},
+{{&grpc_static_metadata_refcounts[2], {{g_bytes+12, 7}}},{&grpc_static_metadata_refcounts[41], {{g_bytes+518, 3}}}},
+{{&grpc_static_metadata_refcounts[2], {{g_bytes+12, 7}}},{&grpc_static_metadata_refcounts[42], {{g_bytes+521, 3}}}},
+{{&grpc_static_metadata_refcounts[4], {{g_bytes+29, 7}}},{&grpc_static_metadata_refcounts[43], {{g_bytes+524, 4}}}},
+{{&grpc_static_metadata_refcounts[4], {{g_bytes+29, 7}}},{&grpc_static_metadata_refcounts[44], {{g_bytes+528, 5}}}},
+{{&grpc_static_metadata_refcounts[4], {{g_bytes+29, 7}}},{&grpc_static_metadata_refcounts[45], {{g_bytes+533, 4}}}},
+{{&grpc_static_metadata_refcounts[3], {{g_bytes+19, 10}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[1], {{g_bytes+5, 7}}},{&grpc_static_metadata_refcounts[46], {{g_bytes+537, 3}}}},
+{{&grpc_static_metadata_refcounts[1], {{g_bytes+5, 7}}},{&grpc_static_metadata_refcounts[47], {{g_bytes+540, 3}}}},
+{{&grpc_static_metadata_refcounts[0], {{g_bytes+0, 5}}},{&grpc_static_metadata_refcounts[48], {{g_bytes+543, 1}}}},
+{{&grpc_static_metadata_refcounts[0], {{g_bytes+0, 5}}},{&grpc_static_metadata_refcounts[49], {{g_bytes+544, 11}}}},
+{{&grpc_static_metadata_refcounts[2], {{g_bytes+12, 7}}},{&grpc_static_metadata_refcounts[50], {{g_bytes+555, 3}}}},
+{{&grpc_static_metadata_refcounts[2], {{g_bytes+12, 7}}},{&grpc_static_metadata_refcounts[51], {{g_bytes+558, 3}}}},
+{{&grpc_static_metadata_refcounts[2], {{g_bytes+12, 7}}},{&grpc_static_metadata_refcounts[52], {{g_bytes+561, 3}}}},
+{{&grpc_static_metadata_refcounts[2], {{g_bytes+12, 7}}},{&grpc_static_metadata_refcounts[53], {{g_bytes+564, 3}}}},
+{{&grpc_static_metadata_refcounts[2], {{g_bytes+12, 7}}},{&grpc_static_metadata_refcounts[54], {{g_bytes+567, 3}}}},
+{{&grpc_static_metadata_refcounts[55], {{g_bytes+570, 14}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[16], {{g_bytes+186, 15}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[16], {{g_bytes+186, 15}}},{&grpc_static_metadata_refcounts[56], {{g_bytes+584, 13}}}},
+{{&grpc_static_metadata_refcounts[57], {{g_bytes+597, 15}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[58], {{g_bytes+612, 13}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[59], {{g_bytes+625, 6}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[60], {{g_bytes+631, 27}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[61], {{g_bytes+658, 3}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[62], {{g_bytes+661, 5}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[63], {{g_bytes+666, 13}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[64], {{g_bytes+679, 13}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[65], {{g_bytes+692, 19}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[15], {{g_bytes+170, 16}}},{&grpc_static_metadata_refcounts[35], {{g_bytes+471, 8}}}},
+{{&grpc_static_metadata_refcounts[15], {{g_bytes+170, 16}}},{&grpc_static_metadata_refcounts[36], {{g_bytes+479, 4}}}},
+{{&grpc_static_metadata_refcounts[15], {{g_bytes+170, 16}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[66], {{g_bytes+711, 16}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[67], {{g_bytes+727, 14}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[68], {{g_bytes+741, 16}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[69], {{g_bytes+757, 13}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[14], {{g_bytes+158, 12}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[70], {{g_bytes+770, 6}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[71], {{g_bytes+776, 4}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[72], {{g_bytes+780, 4}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[73], {{g_bytes+784, 6}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[74], {{g_bytes+790, 7}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[75], {{g_bytes+797, 4}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[20], {{g_bytes+278, 4}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[76], {{g_bytes+801, 8}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[77], {{g_bytes+809, 17}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[78], {{g_bytes+826, 13}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[79], {{g_bytes+839, 8}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[80], {{g_bytes+847, 19}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[81], {{g_bytes+866, 13}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[21], {{g_bytes+282, 8}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[82], {{g_bytes+879, 11}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[83], {{g_bytes+890, 4}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[84], {{g_bytes+894, 8}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[85], {{g_bytes+902, 12}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[86], {{g_bytes+914, 18}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[87], {{g_bytes+932, 19}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[88], {{g_bytes+951, 5}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[89], {{g_bytes+956, 7}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[90], {{g_bytes+963, 7}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[91], {{g_bytes+970, 11}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[92], {{g_bytes+981, 6}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[93], {{g_bytes+987, 10}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[94], {{g_bytes+997, 25}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[95], {{g_bytes+1022, 17}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[19], {{g_bytes+268, 10}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[96], {{g_bytes+1039, 4}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[97], {{g_bytes+1043, 3}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[98], {{g_bytes+1046, 16}}},{&grpc_static_metadata_refcounts[23], {{g_bytes+302, 0}}}},
+{{&grpc_static_metadata_refcounts[10], {{g_bytes+90, 20}}},{&grpc_static_metadata_refcounts[35], {{g_bytes+471, 8}}}},
+{{&grpc_static_metadata_refcounts[10], {{g_bytes+90, 20}}},{&grpc_static_metadata_refcounts[37], {{g_bytes+483, 7}}}},
+{{&grpc_static_metadata_refcounts[10], {{g_bytes+90, 20}}},{&grpc_static_metadata_refcounts[99], {{g_bytes+1062, 16}}}},
+{{&grpc_static_metadata_refcounts[10], {{g_bytes+90, 20}}},{&grpc_static_metadata_refcounts[36], {{g_bytes+479, 4}}}},
+{{&grpc_static_metadata_refcounts[10], {{g_bytes+90, 20}}},{&grpc_static_metadata_refcounts[100], {{g_bytes+1078, 13}}}},
+{{&grpc_static_metadata_refcounts[10], {{g_bytes+90, 20}}},{&grpc_static_metadata_refcounts[101], {{g_bytes+1091, 12}}}},
+{{&grpc_static_metadata_refcounts[10], {{g_bytes+90, 20}}},{&grpc_static_metadata_refcounts[102], {{g_bytes+1103, 21}}}},
+{{&grpc_static_metadata_refcounts[16], {{g_bytes+186, 15}}},{&grpc_static_metadata_refcounts[35], {{g_bytes+471, 8}}}},
+{{&grpc_static_metadata_refcounts[16], {{g_bytes+186, 15}}},{&grpc_static_metadata_refcounts[36], {{g_bytes+479, 4}}}},
+{{&grpc_static_metadata_refcounts[16], {{g_bytes+186, 15}}},{&grpc_static_metadata_refcounts[100], {{g_bytes+1078, 13}}}},
};
bool grpc_static_callout_is_default[GRPC_BATCH_CALLOUTS_COUNT] = {
- true, // :path
- true, // :method
- true, // :status
- true, // :authority
- true, // :scheme
- true, // te
- true, // grpc-message
- true, // grpc-status
- true, // grpc-payload-bin
- true, // grpc-encoding
- true, // grpc-accept-encoding
- true, // grpc-server-stats-bin
- true, // grpc-tags-bin
- true, // grpc-trace-bin
- true, // content-type
- true, // content-encoding
- true, // accept-encoding
- true, // grpc-internal-encoding-request
- true, // grpc-internal-stream-encoding-request
- true, // user-agent
- true, // host
- true, // lb-token
+ true, // :path
+ true, // :method
+ true, // :status
+ true, // :authority
+ true, // :scheme
+ true, // te
+ true, // grpc-message
+ true, // grpc-status
+ true, // grpc-payload-bin
+ true, // grpc-encoding
+ true, // grpc-accept-encoding
+ true, // grpc-server-stats-bin
+ true, // grpc-tags-bin
+ true, // grpc-trace-bin
+ true, // content-type
+ true, // content-encoding
+ true, // accept-encoding
+ true, // grpc-internal-encoding-request
+ true, // grpc-internal-stream-encoding-request
+ true, // user-agent
+ true, // host
+ true, // lb-token
};
-const uint8_t grpc_static_accept_encoding_metadata[8] = {0, 76, 77, 78,
- 79, 80, 81, 82};
+const uint8_t grpc_static_accept_encoding_metadata[8] = {
+0,76,77,78,79,80,81,82
+};
-const uint8_t grpc_static_accept_stream_encoding_metadata[4] = {0, 83, 84, 85};
+const uint8_t grpc_static_accept_stream_encoding_metadata[4] = {
+0,83,84,85
+};
diff --git a/src/core/lib/transport/static_metadata.h b/src/core/lib/transport/static_metadata.h
index f03a9d23b1..d94aab3fa3 100644
--- a/src/core/lib/transport/static_metadata.h
+++ b/src/core/lib/transport/static_metadata.h
@@ -1,12 +1,12 @@
/*
* Copyright 2015 gRPC authors.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -16,10 +16,10 @@
/*
* WARNING: Auto-generated code.
- *
+ *
* To make changes to this file, change
* tools/codegen/core/gen_static_metadata.py, and then re-run it.
- *
+ *
* See metadata.h for an explanation of the interface here, and metadata.c for
* an explanation of what's going on.
*/
@@ -29,7 +29,7 @@
#include "src/core/lib/transport/metadata.h"
-#define GRPC_STATIC_MDSTR_COUNT 100
+#define GRPC_STATIC_MDSTR_COUNT 103
extern const grpc_slice grpc_static_slice_table[GRPC_STATIC_MDSTR_COUNT];
/* ":path" */
#define GRPC_MDSTR_PATH (grpc_static_slice_table[0])
@@ -68,8 +68,7 @@ extern const grpc_slice grpc_static_slice_table[GRPC_STATIC_MDSTR_COUNT];
/* "grpc-internal-encoding-request" */
#define GRPC_MDSTR_GRPC_INTERNAL_ENCODING_REQUEST (grpc_static_slice_table[17])
/* "grpc-internal-stream-encoding-request" */
-#define GRPC_MDSTR_GRPC_INTERNAL_STREAM_ENCODING_REQUEST \
- (grpc_static_slice_table[18])
+#define GRPC_MDSTR_GRPC_INTERNAL_STREAM_ENCODING_REQUEST (grpc_static_slice_table[18])
/* "user-agent" */
#define GRPC_MDSTR_USER_AGENT (grpc_static_slice_table[19])
/* "host" */
@@ -85,164 +84,164 @@ extern const grpc_slice grpc_static_slice_table[GRPC_STATIC_MDSTR_COUNT];
/* "grpc.timeout" */
#define GRPC_MDSTR_GRPC_DOT_TIMEOUT (grpc_static_slice_table[25])
/* "grpc.max_request_message_bytes" */
-#define GRPC_MDSTR_GRPC_DOT_MAX_REQUEST_MESSAGE_BYTES \
- (grpc_static_slice_table[26])
+#define GRPC_MDSTR_GRPC_DOT_MAX_REQUEST_MESSAGE_BYTES (grpc_static_slice_table[26])
/* "grpc.max_response_message_bytes" */
-#define GRPC_MDSTR_GRPC_DOT_MAX_RESPONSE_MESSAGE_BYTES \
- (grpc_static_slice_table[27])
+#define GRPC_MDSTR_GRPC_DOT_MAX_RESPONSE_MESSAGE_BYTES (grpc_static_slice_table[27])
/* "/grpc.lb.v1.LoadBalancer/BalanceLoad" */
-#define GRPC_MDSTR_SLASH_GRPC_DOT_LB_DOT_V1_DOT_LOADBALANCER_SLASH_BALANCELOAD \
- (grpc_static_slice_table[28])
+#define GRPC_MDSTR_SLASH_GRPC_DOT_LB_DOT_V1_DOT_LOADBALANCER_SLASH_BALANCELOAD (grpc_static_slice_table[28])
+/* "message/deflate" */
+#define GRPC_MDSTR_MESSAGE_SLASH_DEFLATE (grpc_static_slice_table[29])
+/* "message/gzip" */
+#define GRPC_MDSTR_MESSAGE_SLASH_GZIP (grpc_static_slice_table[30])
+/* "stream/gzip" */
+#define GRPC_MDSTR_STREAM_SLASH_GZIP (grpc_static_slice_table[31])
/* "0" */
-#define GRPC_MDSTR_0 (grpc_static_slice_table[29])
+#define GRPC_MDSTR_0 (grpc_static_slice_table[32])
/* "1" */
-#define GRPC_MDSTR_1 (grpc_static_slice_table[30])
+#define GRPC_MDSTR_1 (grpc_static_slice_table[33])
/* "2" */
-#define GRPC_MDSTR_2 (grpc_static_slice_table[31])
+#define GRPC_MDSTR_2 (grpc_static_slice_table[34])
/* "identity" */
-#define GRPC_MDSTR_IDENTITY (grpc_static_slice_table[32])
+#define GRPC_MDSTR_IDENTITY (grpc_static_slice_table[35])
/* "gzip" */
-#define GRPC_MDSTR_GZIP (grpc_static_slice_table[33])
+#define GRPC_MDSTR_GZIP (grpc_static_slice_table[36])
/* "deflate" */
-#define GRPC_MDSTR_DEFLATE (grpc_static_slice_table[34])
+#define GRPC_MDSTR_DEFLATE (grpc_static_slice_table[37])
/* "trailers" */
-#define GRPC_MDSTR_TRAILERS (grpc_static_slice_table[35])
+#define GRPC_MDSTR_TRAILERS (grpc_static_slice_table[38])
/* "application/grpc" */
-#define GRPC_MDSTR_APPLICATION_SLASH_GRPC (grpc_static_slice_table[36])
+#define GRPC_MDSTR_APPLICATION_SLASH_GRPC (grpc_static_slice_table[39])
/* "POST" */
-#define GRPC_MDSTR_POST (grpc_static_slice_table[37])
+#define GRPC_MDSTR_POST (grpc_static_slice_table[40])
/* "200" */
-#define GRPC_MDSTR_200 (grpc_static_slice_table[38])
+#define GRPC_MDSTR_200 (grpc_static_slice_table[41])
/* "404" */
-#define GRPC_MDSTR_404 (grpc_static_slice_table[39])
+#define GRPC_MDSTR_404 (grpc_static_slice_table[42])
/* "http" */
-#define GRPC_MDSTR_HTTP (grpc_static_slice_table[40])
+#define GRPC_MDSTR_HTTP (grpc_static_slice_table[43])
/* "https" */
-#define GRPC_MDSTR_HTTPS (grpc_static_slice_table[41])
+#define GRPC_MDSTR_HTTPS (grpc_static_slice_table[44])
/* "grpc" */
-#define GRPC_MDSTR_GRPC (grpc_static_slice_table[42])
+#define GRPC_MDSTR_GRPC (grpc_static_slice_table[45])
/* "GET" */
-#define GRPC_MDSTR_GET (grpc_static_slice_table[43])
+#define GRPC_MDSTR_GET (grpc_static_slice_table[46])
/* "PUT" */
-#define GRPC_MDSTR_PUT (grpc_static_slice_table[44])
+#define GRPC_MDSTR_PUT (grpc_static_slice_table[47])
/* "/" */
-#define GRPC_MDSTR_SLASH (grpc_static_slice_table[45])
+#define GRPC_MDSTR_SLASH (grpc_static_slice_table[48])
/* "/index.html" */
-#define GRPC_MDSTR_SLASH_INDEX_DOT_HTML (grpc_static_slice_table[46])
+#define GRPC_MDSTR_SLASH_INDEX_DOT_HTML (grpc_static_slice_table[49])
/* "204" */
-#define GRPC_MDSTR_204 (grpc_static_slice_table[47])
+#define GRPC_MDSTR_204 (grpc_static_slice_table[50])
/* "206" */
-#define GRPC_MDSTR_206 (grpc_static_slice_table[48])
+#define GRPC_MDSTR_206 (grpc_static_slice_table[51])
/* "304" */
-#define GRPC_MDSTR_304 (grpc_static_slice_table[49])
+#define GRPC_MDSTR_304 (grpc_static_slice_table[52])
/* "400" */
-#define GRPC_MDSTR_400 (grpc_static_slice_table[50])
+#define GRPC_MDSTR_400 (grpc_static_slice_table[53])
/* "500" */
-#define GRPC_MDSTR_500 (grpc_static_slice_table[51])
+#define GRPC_MDSTR_500 (grpc_static_slice_table[54])
/* "accept-charset" */
-#define GRPC_MDSTR_ACCEPT_CHARSET (grpc_static_slice_table[52])
+#define GRPC_MDSTR_ACCEPT_CHARSET (grpc_static_slice_table[55])
/* "gzip, deflate" */
-#define GRPC_MDSTR_GZIP_COMMA_DEFLATE (grpc_static_slice_table[53])
+#define GRPC_MDSTR_GZIP_COMMA_DEFLATE (grpc_static_slice_table[56])
/* "accept-language" */
-#define GRPC_MDSTR_ACCEPT_LANGUAGE (grpc_static_slice_table[54])
+#define GRPC_MDSTR_ACCEPT_LANGUAGE (grpc_static_slice_table[57])
/* "accept-ranges" */
-#define GRPC_MDSTR_ACCEPT_RANGES (grpc_static_slice_table[55])
+#define GRPC_MDSTR_ACCEPT_RANGES (grpc_static_slice_table[58])
/* "accept" */
-#define GRPC_MDSTR_ACCEPT (grpc_static_slice_table[56])
+#define GRPC_MDSTR_ACCEPT (grpc_static_slice_table[59])
/* "access-control-allow-origin" */
-#define GRPC_MDSTR_ACCESS_CONTROL_ALLOW_ORIGIN (grpc_static_slice_table[57])
+#define GRPC_MDSTR_ACCESS_CONTROL_ALLOW_ORIGIN (grpc_static_slice_table[60])
/* "age" */
-#define GRPC_MDSTR_AGE (grpc_static_slice_table[58])
+#define GRPC_MDSTR_AGE (grpc_static_slice_table[61])
/* "allow" */
-#define GRPC_MDSTR_ALLOW (grpc_static_slice_table[59])
+#define GRPC_MDSTR_ALLOW (grpc_static_slice_table[62])
/* "authorization" */
-#define GRPC_MDSTR_AUTHORIZATION (grpc_static_slice_table[60])
+#define GRPC_MDSTR_AUTHORIZATION (grpc_static_slice_table[63])
/* "cache-control" */
-#define GRPC_MDSTR_CACHE_CONTROL (grpc_static_slice_table[61])
+#define GRPC_MDSTR_CACHE_CONTROL (grpc_static_slice_table[64])
/* "content-disposition" */
-#define GRPC_MDSTR_CONTENT_DISPOSITION (grpc_static_slice_table[62])
+#define GRPC_MDSTR_CONTENT_DISPOSITION (grpc_static_slice_table[65])
/* "content-language" */
-#define GRPC_MDSTR_CONTENT_LANGUAGE (grpc_static_slice_table[63])
+#define GRPC_MDSTR_CONTENT_LANGUAGE (grpc_static_slice_table[66])
/* "content-length" */
-#define GRPC_MDSTR_CONTENT_LENGTH (grpc_static_slice_table[64])
+#define GRPC_MDSTR_CONTENT_LENGTH (grpc_static_slice_table[67])
/* "content-location" */
-#define GRPC_MDSTR_CONTENT_LOCATION (grpc_static_slice_table[65])
+#define GRPC_MDSTR_CONTENT_LOCATION (grpc_static_slice_table[68])
/* "content-range" */
-#define GRPC_MDSTR_CONTENT_RANGE (grpc_static_slice_table[66])
+#define GRPC_MDSTR_CONTENT_RANGE (grpc_static_slice_table[69])
/* "cookie" */
-#define GRPC_MDSTR_COOKIE (grpc_static_slice_table[67])
+#define GRPC_MDSTR_COOKIE (grpc_static_slice_table[70])
/* "date" */
-#define GRPC_MDSTR_DATE (grpc_static_slice_table[68])
+#define GRPC_MDSTR_DATE (grpc_static_slice_table[71])
/* "etag" */
-#define GRPC_MDSTR_ETAG (grpc_static_slice_table[69])
+#define GRPC_MDSTR_ETAG (grpc_static_slice_table[72])
/* "expect" */
-#define GRPC_MDSTR_EXPECT (grpc_static_slice_table[70])
+#define GRPC_MDSTR_EXPECT (grpc_static_slice_table[73])
/* "expires" */
-#define GRPC_MDSTR_EXPIRES (grpc_static_slice_table[71])
+#define GRPC_MDSTR_EXPIRES (grpc_static_slice_table[74])
/* "from" */
-#define GRPC_MDSTR_FROM (grpc_static_slice_table[72])
+#define GRPC_MDSTR_FROM (grpc_static_slice_table[75])
/* "if-match" */
-#define GRPC_MDSTR_IF_MATCH (grpc_static_slice_table[73])
+#define GRPC_MDSTR_IF_MATCH (grpc_static_slice_table[76])
/* "if-modified-since" */
-#define GRPC_MDSTR_IF_MODIFIED_SINCE (grpc_static_slice_table[74])
+#define GRPC_MDSTR_IF_MODIFIED_SINCE (grpc_static_slice_table[77])
/* "if-none-match" */
-#define GRPC_MDSTR_IF_NONE_MATCH (grpc_static_slice_table[75])
+#define GRPC_MDSTR_IF_NONE_MATCH (grpc_static_slice_table[78])
/* "if-range" */
-#define GRPC_MDSTR_IF_RANGE (grpc_static_slice_table[76])
+#define GRPC_MDSTR_IF_RANGE (grpc_static_slice_table[79])
/* "if-unmodified-since" */
-#define GRPC_MDSTR_IF_UNMODIFIED_SINCE (grpc_static_slice_table[77])
+#define GRPC_MDSTR_IF_UNMODIFIED_SINCE (grpc_static_slice_table[80])
/* "last-modified" */
-#define GRPC_MDSTR_LAST_MODIFIED (grpc_static_slice_table[78])
+#define GRPC_MDSTR_LAST_MODIFIED (grpc_static_slice_table[81])
/* "lb-cost-bin" */
-#define GRPC_MDSTR_LB_COST_BIN (grpc_static_slice_table[79])
+#define GRPC_MDSTR_LB_COST_BIN (grpc_static_slice_table[82])
/* "link" */
-#define GRPC_MDSTR_LINK (grpc_static_slice_table[80])
+#define GRPC_MDSTR_LINK (grpc_static_slice_table[83])
/* "location" */
-#define GRPC_MDSTR_LOCATION (grpc_static_slice_table[81])
+#define GRPC_MDSTR_LOCATION (grpc_static_slice_table[84])
/* "max-forwards" */
-#define GRPC_MDSTR_MAX_FORWARDS (grpc_static_slice_table[82])
+#define GRPC_MDSTR_MAX_FORWARDS (grpc_static_slice_table[85])
/* "proxy-authenticate" */
-#define GRPC_MDSTR_PROXY_AUTHENTICATE (grpc_static_slice_table[83])
+#define GRPC_MDSTR_PROXY_AUTHENTICATE (grpc_static_slice_table[86])
/* "proxy-authorization" */
-#define GRPC_MDSTR_PROXY_AUTHORIZATION (grpc_static_slice_table[84])
+#define GRPC_MDSTR_PROXY_AUTHORIZATION (grpc_static_slice_table[87])
/* "range" */
-#define GRPC_MDSTR_RANGE (grpc_static_slice_table[85])
+#define GRPC_MDSTR_RANGE (grpc_static_slice_table[88])
/* "referer" */
-#define GRPC_MDSTR_REFERER (grpc_static_slice_table[86])
+#define GRPC_MDSTR_REFERER (grpc_static_slice_table[89])
/* "refresh" */
-#define GRPC_MDSTR_REFRESH (grpc_static_slice_table[87])
+#define GRPC_MDSTR_REFRESH (grpc_static_slice_table[90])
/* "retry-after" */
-#define GRPC_MDSTR_RETRY_AFTER (grpc_static_slice_table[88])
+#define GRPC_MDSTR_RETRY_AFTER (grpc_static_slice_table[91])
/* "server" */
-#define GRPC_MDSTR_SERVER (grpc_static_slice_table[89])
+#define GRPC_MDSTR_SERVER (grpc_static_slice_table[92])
/* "set-cookie" */
-#define GRPC_MDSTR_SET_COOKIE (grpc_static_slice_table[90])
+#define GRPC_MDSTR_SET_COOKIE (grpc_static_slice_table[93])
/* "strict-transport-security" */
-#define GRPC_MDSTR_STRICT_TRANSPORT_SECURITY (grpc_static_slice_table[91])
+#define GRPC_MDSTR_STRICT_TRANSPORT_SECURITY (grpc_static_slice_table[94])
/* "transfer-encoding" */
-#define GRPC_MDSTR_TRANSFER_ENCODING (grpc_static_slice_table[92])
+#define GRPC_MDSTR_TRANSFER_ENCODING (grpc_static_slice_table[95])
/* "vary" */
-#define GRPC_MDSTR_VARY (grpc_static_slice_table[93])
+#define GRPC_MDSTR_VARY (grpc_static_slice_table[96])
/* "via" */
-#define GRPC_MDSTR_VIA (grpc_static_slice_table[94])
+#define GRPC_MDSTR_VIA (grpc_static_slice_table[97])
/* "www-authenticate" */
-#define GRPC_MDSTR_WWW_AUTHENTICATE (grpc_static_slice_table[95])
+#define GRPC_MDSTR_WWW_AUTHENTICATE (grpc_static_slice_table[98])
/* "identity,deflate" */
-#define GRPC_MDSTR_IDENTITY_COMMA_DEFLATE (grpc_static_slice_table[96])
+#define GRPC_MDSTR_IDENTITY_COMMA_DEFLATE (grpc_static_slice_table[99])
/* "identity,gzip" */
-#define GRPC_MDSTR_IDENTITY_COMMA_GZIP (grpc_static_slice_table[97])
+#define GRPC_MDSTR_IDENTITY_COMMA_GZIP (grpc_static_slice_table[100])
/* "deflate,gzip" */
-#define GRPC_MDSTR_DEFLATE_COMMA_GZIP (grpc_static_slice_table[98])
+#define GRPC_MDSTR_DEFLATE_COMMA_GZIP (grpc_static_slice_table[101])
/* "identity,deflate,gzip" */
-#define GRPC_MDSTR_IDENTITY_COMMA_DEFLATE_COMMA_GZIP \
- (grpc_static_slice_table[99])
+#define GRPC_MDSTR_IDENTITY_COMMA_DEFLATE_COMMA_GZIP (grpc_static_slice_table[102])
extern const grpc_slice_refcount_vtable grpc_static_metadata_vtable;
-extern grpc_slice_refcount
- grpc_static_metadata_refcounts[GRPC_STATIC_MDSTR_COUNT];
+extern grpc_slice_refcount grpc_static_metadata_refcounts[GRPC_STATIC_MDSTR_COUNT];
#define GRPC_IS_STATIC_METADATA_STRING(slice) \
- ((slice).refcount != NULL && \
- (slice).refcount->vtable == &grpc_static_metadata_vtable)
+ ((slice).refcount != NULL && (slice).refcount->vtable == &grpc_static_metadata_vtable)
#define GRPC_STATIC_METADATA_INDEX(static_slice) \
((int)((static_slice).refcount - grpc_static_metadata_refcounts))
@@ -251,263 +250,177 @@ extern grpc_slice_refcount
extern grpc_mdelem_data grpc_static_mdelem_table[GRPC_STATIC_MDELEM_COUNT];
extern uintptr_t grpc_static_mdelem_user_data[GRPC_STATIC_MDELEM_COUNT];
/* "grpc-status": "0" */
-#define GRPC_MDELEM_GRPC_STATUS_0 \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[0], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_STATUS_0 (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[0], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-status": "1" */
-#define GRPC_MDELEM_GRPC_STATUS_1 \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[1], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_STATUS_1 (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[1], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-status": "2" */
-#define GRPC_MDELEM_GRPC_STATUS_2 \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[2], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_STATUS_2 (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[2], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-encoding": "identity" */
-#define GRPC_MDELEM_GRPC_ENCODING_IDENTITY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[3], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_ENCODING_IDENTITY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[3], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-encoding": "gzip" */
-#define GRPC_MDELEM_GRPC_ENCODING_GZIP \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[4], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_ENCODING_GZIP (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[4], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-encoding": "deflate" */
-#define GRPC_MDELEM_GRPC_ENCODING_DEFLATE \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[5], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_ENCODING_DEFLATE (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[5], GRPC_MDELEM_STORAGE_STATIC))
/* "te": "trailers" */
-#define GRPC_MDELEM_TE_TRAILERS \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[6], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_TE_TRAILERS (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[6], GRPC_MDELEM_STORAGE_STATIC))
/* "content-type": "application/grpc" */
-#define GRPC_MDELEM_CONTENT_TYPE_APPLICATION_SLASH_GRPC \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[7], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CONTENT_TYPE_APPLICATION_SLASH_GRPC (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[7], GRPC_MDELEM_STORAGE_STATIC))
/* ":method": "POST" */
-#define GRPC_MDELEM_METHOD_POST \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[8], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_METHOD_POST (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[8], GRPC_MDELEM_STORAGE_STATIC))
/* ":status": "200" */
-#define GRPC_MDELEM_STATUS_200 \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[9], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_STATUS_200 (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[9], GRPC_MDELEM_STORAGE_STATIC))
/* ":status": "404" */
-#define GRPC_MDELEM_STATUS_404 \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[10], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_STATUS_404 (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[10], GRPC_MDELEM_STORAGE_STATIC))
/* ":scheme": "http" */
-#define GRPC_MDELEM_SCHEME_HTTP \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[11], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_SCHEME_HTTP (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[11], GRPC_MDELEM_STORAGE_STATIC))
/* ":scheme": "https" */
-#define GRPC_MDELEM_SCHEME_HTTPS \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[12], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_SCHEME_HTTPS (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[12], GRPC_MDELEM_STORAGE_STATIC))
/* ":scheme": "grpc" */
-#define GRPC_MDELEM_SCHEME_GRPC \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[13], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_SCHEME_GRPC (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[13], GRPC_MDELEM_STORAGE_STATIC))
/* ":authority": "" */
-#define GRPC_MDELEM_AUTHORITY_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[14], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_AUTHORITY_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[14], GRPC_MDELEM_STORAGE_STATIC))
/* ":method": "GET" */
-#define GRPC_MDELEM_METHOD_GET \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[15], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_METHOD_GET (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[15], GRPC_MDELEM_STORAGE_STATIC))
/* ":method": "PUT" */
-#define GRPC_MDELEM_METHOD_PUT \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[16], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_METHOD_PUT (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[16], GRPC_MDELEM_STORAGE_STATIC))
/* ":path": "/" */
-#define GRPC_MDELEM_PATH_SLASH \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[17], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_PATH_SLASH (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[17], GRPC_MDELEM_STORAGE_STATIC))
/* ":path": "/index.html" */
-#define GRPC_MDELEM_PATH_SLASH_INDEX_DOT_HTML \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[18], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_PATH_SLASH_INDEX_DOT_HTML (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[18], GRPC_MDELEM_STORAGE_STATIC))
/* ":status": "204" */
-#define GRPC_MDELEM_STATUS_204 \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[19], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_STATUS_204 (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[19], GRPC_MDELEM_STORAGE_STATIC))
/* ":status": "206" */
-#define GRPC_MDELEM_STATUS_206 \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[20], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_STATUS_206 (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[20], GRPC_MDELEM_STORAGE_STATIC))
/* ":status": "304" */
-#define GRPC_MDELEM_STATUS_304 \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[21], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_STATUS_304 (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[21], GRPC_MDELEM_STORAGE_STATIC))
/* ":status": "400" */
-#define GRPC_MDELEM_STATUS_400 \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[22], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_STATUS_400 (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[22], GRPC_MDELEM_STORAGE_STATIC))
/* ":status": "500" */
-#define GRPC_MDELEM_STATUS_500 \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[23], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_STATUS_500 (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[23], GRPC_MDELEM_STORAGE_STATIC))
/* "accept-charset": "" */
-#define GRPC_MDELEM_ACCEPT_CHARSET_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[24], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_CHARSET_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[24], GRPC_MDELEM_STORAGE_STATIC))
/* "accept-encoding": "" */
-#define GRPC_MDELEM_ACCEPT_ENCODING_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[25], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_ENCODING_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[25], GRPC_MDELEM_STORAGE_STATIC))
/* "accept-encoding": "gzip, deflate" */
-#define GRPC_MDELEM_ACCEPT_ENCODING_GZIP_COMMA_DEFLATE \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[26], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_ENCODING_GZIP_COMMA_DEFLATE (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[26], GRPC_MDELEM_STORAGE_STATIC))
/* "accept-language": "" */
-#define GRPC_MDELEM_ACCEPT_LANGUAGE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[27], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_LANGUAGE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[27], GRPC_MDELEM_STORAGE_STATIC))
/* "accept-ranges": "" */
-#define GRPC_MDELEM_ACCEPT_RANGES_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[28], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_RANGES_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[28], GRPC_MDELEM_STORAGE_STATIC))
/* "accept": "" */
-#define GRPC_MDELEM_ACCEPT_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[29], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[29], GRPC_MDELEM_STORAGE_STATIC))
/* "access-control-allow-origin": "" */
-#define GRPC_MDELEM_ACCESS_CONTROL_ALLOW_ORIGIN_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[30], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCESS_CONTROL_ALLOW_ORIGIN_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[30], GRPC_MDELEM_STORAGE_STATIC))
/* "age": "" */
-#define GRPC_MDELEM_AGE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[31], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_AGE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[31], GRPC_MDELEM_STORAGE_STATIC))
/* "allow": "" */
-#define GRPC_MDELEM_ALLOW_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[32], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ALLOW_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[32], GRPC_MDELEM_STORAGE_STATIC))
/* "authorization": "" */
-#define GRPC_MDELEM_AUTHORIZATION_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[33], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_AUTHORIZATION_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[33], GRPC_MDELEM_STORAGE_STATIC))
/* "cache-control": "" */
-#define GRPC_MDELEM_CACHE_CONTROL_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[34], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CACHE_CONTROL_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[34], GRPC_MDELEM_STORAGE_STATIC))
/* "content-disposition": "" */
-#define GRPC_MDELEM_CONTENT_DISPOSITION_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[35], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CONTENT_DISPOSITION_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[35], GRPC_MDELEM_STORAGE_STATIC))
/* "content-encoding": "identity" */
-#define GRPC_MDELEM_CONTENT_ENCODING_IDENTITY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[36], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CONTENT_ENCODING_IDENTITY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[36], GRPC_MDELEM_STORAGE_STATIC))
/* "content-encoding": "gzip" */
-#define GRPC_MDELEM_CONTENT_ENCODING_GZIP \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[37], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CONTENT_ENCODING_GZIP (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[37], GRPC_MDELEM_STORAGE_STATIC))
/* "content-encoding": "" */
-#define GRPC_MDELEM_CONTENT_ENCODING_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[38], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CONTENT_ENCODING_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[38], GRPC_MDELEM_STORAGE_STATIC))
/* "content-language": "" */
-#define GRPC_MDELEM_CONTENT_LANGUAGE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[39], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CONTENT_LANGUAGE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[39], GRPC_MDELEM_STORAGE_STATIC))
/* "content-length": "" */
-#define GRPC_MDELEM_CONTENT_LENGTH_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[40], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CONTENT_LENGTH_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[40], GRPC_MDELEM_STORAGE_STATIC))
/* "content-location": "" */
-#define GRPC_MDELEM_CONTENT_LOCATION_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[41], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CONTENT_LOCATION_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[41], GRPC_MDELEM_STORAGE_STATIC))
/* "content-range": "" */
-#define GRPC_MDELEM_CONTENT_RANGE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[42], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CONTENT_RANGE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[42], GRPC_MDELEM_STORAGE_STATIC))
/* "content-type": "" */
-#define GRPC_MDELEM_CONTENT_TYPE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[43], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_CONTENT_TYPE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[43], GRPC_MDELEM_STORAGE_STATIC))
/* "cookie": "" */
-#define GRPC_MDELEM_COOKIE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[44], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_COOKIE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[44], GRPC_MDELEM_STORAGE_STATIC))
/* "date": "" */
-#define GRPC_MDELEM_DATE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[45], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_DATE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[45], GRPC_MDELEM_STORAGE_STATIC))
/* "etag": "" */
-#define GRPC_MDELEM_ETAG_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[46], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ETAG_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[46], GRPC_MDELEM_STORAGE_STATIC))
/* "expect": "" */
-#define GRPC_MDELEM_EXPECT_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[47], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_EXPECT_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[47], GRPC_MDELEM_STORAGE_STATIC))
/* "expires": "" */
-#define GRPC_MDELEM_EXPIRES_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[48], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_EXPIRES_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[48], GRPC_MDELEM_STORAGE_STATIC))
/* "from": "" */
-#define GRPC_MDELEM_FROM_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[49], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_FROM_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[49], GRPC_MDELEM_STORAGE_STATIC))
/* "host": "" */
-#define GRPC_MDELEM_HOST_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[50], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_HOST_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[50], GRPC_MDELEM_STORAGE_STATIC))
/* "if-match": "" */
-#define GRPC_MDELEM_IF_MATCH_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[51], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_IF_MATCH_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[51], GRPC_MDELEM_STORAGE_STATIC))
/* "if-modified-since": "" */
-#define GRPC_MDELEM_IF_MODIFIED_SINCE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[52], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_IF_MODIFIED_SINCE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[52], GRPC_MDELEM_STORAGE_STATIC))
/* "if-none-match": "" */
-#define GRPC_MDELEM_IF_NONE_MATCH_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[53], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_IF_NONE_MATCH_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[53], GRPC_MDELEM_STORAGE_STATIC))
/* "if-range": "" */
-#define GRPC_MDELEM_IF_RANGE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[54], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_IF_RANGE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[54], GRPC_MDELEM_STORAGE_STATIC))
/* "if-unmodified-since": "" */
-#define GRPC_MDELEM_IF_UNMODIFIED_SINCE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[55], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_IF_UNMODIFIED_SINCE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[55], GRPC_MDELEM_STORAGE_STATIC))
/* "last-modified": "" */
-#define GRPC_MDELEM_LAST_MODIFIED_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[56], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_LAST_MODIFIED_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[56], GRPC_MDELEM_STORAGE_STATIC))
/* "lb-token": "" */
-#define GRPC_MDELEM_LB_TOKEN_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[57], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_LB_TOKEN_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[57], GRPC_MDELEM_STORAGE_STATIC))
/* "lb-cost-bin": "" */
-#define GRPC_MDELEM_LB_COST_BIN_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[58], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_LB_COST_BIN_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[58], GRPC_MDELEM_STORAGE_STATIC))
/* "link": "" */
-#define GRPC_MDELEM_LINK_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[59], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_LINK_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[59], GRPC_MDELEM_STORAGE_STATIC))
/* "location": "" */
-#define GRPC_MDELEM_LOCATION_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[60], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_LOCATION_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[60], GRPC_MDELEM_STORAGE_STATIC))
/* "max-forwards": "" */
-#define GRPC_MDELEM_MAX_FORWARDS_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[61], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_MAX_FORWARDS_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[61], GRPC_MDELEM_STORAGE_STATIC))
/* "proxy-authenticate": "" */
-#define GRPC_MDELEM_PROXY_AUTHENTICATE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[62], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_PROXY_AUTHENTICATE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[62], GRPC_MDELEM_STORAGE_STATIC))
/* "proxy-authorization": "" */
-#define GRPC_MDELEM_PROXY_AUTHORIZATION_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[63], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_PROXY_AUTHORIZATION_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[63], GRPC_MDELEM_STORAGE_STATIC))
/* "range": "" */
-#define GRPC_MDELEM_RANGE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[64], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_RANGE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[64], GRPC_MDELEM_STORAGE_STATIC))
/* "referer": "" */
-#define GRPC_MDELEM_REFERER_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[65], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_REFERER_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[65], GRPC_MDELEM_STORAGE_STATIC))
/* "refresh": "" */
-#define GRPC_MDELEM_REFRESH_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[66], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_REFRESH_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[66], GRPC_MDELEM_STORAGE_STATIC))
/* "retry-after": "" */
-#define GRPC_MDELEM_RETRY_AFTER_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[67], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_RETRY_AFTER_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[67], GRPC_MDELEM_STORAGE_STATIC))
/* "server": "" */
-#define GRPC_MDELEM_SERVER_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[68], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_SERVER_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[68], GRPC_MDELEM_STORAGE_STATIC))
/* "set-cookie": "" */
-#define GRPC_MDELEM_SET_COOKIE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[69], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_SET_COOKIE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[69], GRPC_MDELEM_STORAGE_STATIC))
/* "strict-transport-security": "" */
-#define GRPC_MDELEM_STRICT_TRANSPORT_SECURITY_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[70], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_STRICT_TRANSPORT_SECURITY_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[70], GRPC_MDELEM_STORAGE_STATIC))
/* "transfer-encoding": "" */
-#define GRPC_MDELEM_TRANSFER_ENCODING_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[71], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_TRANSFER_ENCODING_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[71], GRPC_MDELEM_STORAGE_STATIC))
/* "user-agent": "" */
-#define GRPC_MDELEM_USER_AGENT_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[72], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_USER_AGENT_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[72], GRPC_MDELEM_STORAGE_STATIC))
/* "vary": "" */
-#define GRPC_MDELEM_VARY_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[73], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_VARY_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[73], GRPC_MDELEM_STORAGE_STATIC))
/* "via": "" */
-#define GRPC_MDELEM_VIA_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[74], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_VIA_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[74], GRPC_MDELEM_STORAGE_STATIC))
/* "www-authenticate": "" */
-#define GRPC_MDELEM_WWW_AUTHENTICATE_EMPTY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[75], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_WWW_AUTHENTICATE_EMPTY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[75], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-accept-encoding": "identity" */
-#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_IDENTITY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[76], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_IDENTITY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[76], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-accept-encoding": "deflate" */
-#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_DEFLATE \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[77], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_DEFLATE (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[77], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-accept-encoding": "identity,deflate" */
-#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_IDENTITY_COMMA_DEFLATE \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[78], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_IDENTITY_COMMA_DEFLATE (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[78], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-accept-encoding": "gzip" */
-#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_GZIP \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[79], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_GZIP (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[79], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-accept-encoding": "identity,gzip" */
-#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_IDENTITY_COMMA_GZIP \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[80], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_IDENTITY_COMMA_GZIP (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[80], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-accept-encoding": "deflate,gzip" */
-#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_DEFLATE_COMMA_GZIP \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[81], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_DEFLATE_COMMA_GZIP (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[81], GRPC_MDELEM_STORAGE_STATIC))
/* "grpc-accept-encoding": "identity,deflate,gzip" */
-#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_IDENTITY_COMMA_DEFLATE_COMMA_GZIP \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[82], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_GRPC_ACCEPT_ENCODING_IDENTITY_COMMA_DEFLATE_COMMA_GZIP (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[82], GRPC_MDELEM_STORAGE_STATIC))
/* "accept-encoding": "identity" */
-#define GRPC_MDELEM_ACCEPT_ENCODING_IDENTITY \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[83], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_ENCODING_IDENTITY (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[83], GRPC_MDELEM_STORAGE_STATIC))
/* "accept-encoding": "gzip" */
-#define GRPC_MDELEM_ACCEPT_ENCODING_GZIP \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[84], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_ENCODING_GZIP (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[84], GRPC_MDELEM_STORAGE_STATIC))
/* "accept-encoding": "identity,gzip" */
-#define GRPC_MDELEM_ACCEPT_ENCODING_IDENTITY_COMMA_GZIP \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[85], GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_ENCODING_IDENTITY_COMMA_GZIP (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[85], GRPC_MDELEM_STORAGE_STATIC))
grpc_mdelem grpc_static_mdelem_for_static_strings(int a, int b);
typedef enum {
@@ -539,49 +452,39 @@ typedef enum {
typedef union {
struct grpc_linked_mdelem *array[GRPC_BATCH_CALLOUTS_COUNT];
struct {
- struct grpc_linked_mdelem *path;
- struct grpc_linked_mdelem *method;
- struct grpc_linked_mdelem *status;
- struct grpc_linked_mdelem *authority;
- struct grpc_linked_mdelem *scheme;
- struct grpc_linked_mdelem *te;
- struct grpc_linked_mdelem *grpc_message;
- struct grpc_linked_mdelem *grpc_status;
- struct grpc_linked_mdelem *grpc_payload_bin;
- struct grpc_linked_mdelem *grpc_encoding;
- struct grpc_linked_mdelem *grpc_accept_encoding;
- struct grpc_linked_mdelem *grpc_server_stats_bin;
- struct grpc_linked_mdelem *grpc_tags_bin;
- struct grpc_linked_mdelem *grpc_trace_bin;
- struct grpc_linked_mdelem *content_type;
- struct grpc_linked_mdelem *content_encoding;
- struct grpc_linked_mdelem *accept_encoding;
- struct grpc_linked_mdelem *grpc_internal_encoding_request;
- struct grpc_linked_mdelem *grpc_internal_stream_encoding_request;
- struct grpc_linked_mdelem *user_agent;
- struct grpc_linked_mdelem *host;
- struct grpc_linked_mdelem *lb_token;
+ struct grpc_linked_mdelem *path;
+ struct grpc_linked_mdelem *method;
+ struct grpc_linked_mdelem *status;
+ struct grpc_linked_mdelem *authority;
+ struct grpc_linked_mdelem *scheme;
+ struct grpc_linked_mdelem *te;
+ struct grpc_linked_mdelem *grpc_message;
+ struct grpc_linked_mdelem *grpc_status;
+ struct grpc_linked_mdelem *grpc_payload_bin;
+ struct grpc_linked_mdelem *grpc_encoding;
+ struct grpc_linked_mdelem *grpc_accept_encoding;
+ struct grpc_linked_mdelem *grpc_server_stats_bin;
+ struct grpc_linked_mdelem *grpc_tags_bin;
+ struct grpc_linked_mdelem *grpc_trace_bin;
+ struct grpc_linked_mdelem *content_type;
+ struct grpc_linked_mdelem *content_encoding;
+ struct grpc_linked_mdelem *accept_encoding;
+ struct grpc_linked_mdelem *grpc_internal_encoding_request;
+ struct grpc_linked_mdelem *grpc_internal_stream_encoding_request;
+ struct grpc_linked_mdelem *user_agent;
+ struct grpc_linked_mdelem *host;
+ struct grpc_linked_mdelem *lb_token;
} named;
} grpc_metadata_batch_callouts;
-#define GRPC_BATCH_INDEX_OF(slice) \
- (GRPC_IS_STATIC_METADATA_STRING((slice)) \
- ? (grpc_metadata_batch_callouts_index)GPR_CLAMP( \
- GRPC_STATIC_METADATA_INDEX((slice)), 0, \
- GRPC_BATCH_CALLOUTS_COUNT) \
- : GRPC_BATCH_CALLOUTS_COUNT)
+#define GRPC_BATCH_INDEX_OF(slice) \
+ (GRPC_IS_STATIC_METADATA_STRING((slice)) ? (grpc_metadata_batch_callouts_index)GPR_CLAMP(GRPC_STATIC_METADATA_INDEX((slice)), 0, GRPC_BATCH_CALLOUTS_COUNT) : GRPC_BATCH_CALLOUTS_COUNT)
extern bool grpc_static_callout_is_default[GRPC_BATCH_CALLOUTS_COUNT];
extern const uint8_t grpc_static_accept_encoding_metadata[8];
-#define GRPC_MDELEM_ACCEPT_ENCODING_FOR_ALGORITHMS(algs) \
- (GRPC_MAKE_MDELEM( \
- &grpc_static_mdelem_table[grpc_static_accept_encoding_metadata[(algs)]], \
- GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_ENCODING_FOR_ALGORITHMS(algs) (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[grpc_static_accept_encoding_metadata[(algs)]], GRPC_MDELEM_STORAGE_STATIC))
extern const uint8_t grpc_static_accept_stream_encoding_metadata[4];
-#define GRPC_MDELEM_ACCEPT_STREAM_ENCODING_FOR_ALGORITHMS(algs) \
- (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table \
- [grpc_static_accept_stream_encoding_metadata[(algs)]], \
- GRPC_MDELEM_STORAGE_STATIC))
+#define GRPC_MDELEM_ACCEPT_STREAM_ENCODING_FOR_ALGORITHMS(algs) (GRPC_MAKE_MDELEM(&grpc_static_mdelem_table[grpc_static_accept_stream_encoding_metadata[(algs)]], GRPC_MDELEM_STORAGE_STATIC))
#endif /* GRPC_CORE_LIB_TRANSPORT_STATIC_METADATA_H */