/* Generated by the protocol buffer compiler.  DO NOT EDIT! */
/* Generated from: discovery/protocol.proto */

/* Do not generate deprecated warnings for self */
#ifndef PROTOBUF_C__NO_DEPRECATED
#define PROTOBUF_C__NO_DEPRECATED
#endif

#include "discovery/protocol.pb-c.h"
void   discovery__signed_request__init
                     (Discovery__SignedRequest         *message)
{
  static Discovery__SignedRequest init_value = DISCOVERY__SIGNED_REQUEST__INIT;
  *message = init_value;
}
size_t discovery__signed_request__get_packed_size
                     (const Discovery__SignedRequest *message)
{
  assert(message->base.descriptor == &discovery__signed_request__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__signed_request__pack
                     (const Discovery__SignedRequest *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__signed_request__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__signed_request__pack_to_buffer
                     (const Discovery__SignedRequest *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__signed_request__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__SignedRequest *
       discovery__signed_request__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__SignedRequest *)
     protobuf_c_message_unpack (&discovery__signed_request__descriptor,
                                allocator, len, data);
}
void   discovery__signed_request__free_unpacked
                     (Discovery__SignedRequest *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__signed_request__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__request__init
                     (Discovery__Request         *message)
{
  static Discovery__Request init_value = DISCOVERY__REQUEST__INIT;
  *message = init_value;
}
size_t discovery__request__get_packed_size
                     (const Discovery__Request *message)
{
  assert(message->base.descriptor == &discovery__request__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__request__pack
                     (const Discovery__Request *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__request__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__request__pack_to_buffer
                     (const Discovery__Request *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__request__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__Request *
       discovery__request__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__Request *)
     protobuf_c_message_unpack (&discovery__request__descriptor,
                                allocator, len, data);
}
void   discovery__request__free_unpacked
                     (Discovery__Request *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__request__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__response__init
                     (Discovery__Response         *message)
{
  static Discovery__Response init_value = DISCOVERY__RESPONSE__INIT;
  *message = init_value;
}
size_t discovery__response__get_packed_size
                     (const Discovery__Response *message)
{
  assert(message->base.descriptor == &discovery__response__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__response__pack
                     (const Discovery__Response *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__response__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__response__pack_to_buffer
                     (const Discovery__Response *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__response__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__Response *
       discovery__response__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__Response *)
     protobuf_c_message_unpack (&discovery__response__descriptor,
                                allocator, len, data);
}
void   discovery__response__free_unpacked
                     (Discovery__Response *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__response__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__auth_info__init
                     (Discovery__AuthInfo         *message)
{
  static Discovery__AuthInfo init_value = DISCOVERY__AUTH_INFO__INIT;
  *message = init_value;
}
size_t discovery__auth_info__get_packed_size
                     (const Discovery__AuthInfo *message)
{
  assert(message->base.descriptor == &discovery__auth_info__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__auth_info__pack
                     (const Discovery__AuthInfo *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__auth_info__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__auth_info__pack_to_buffer
                     (const Discovery__AuthInfo *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__auth_info__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__AuthInfo *
       discovery__auth_info__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__AuthInfo *)
     protobuf_c_message_unpack (&discovery__auth_info__descriptor,
                                allocator, len, data);
}
void   discovery__auth_info__free_unpacked
                     (Discovery__AuthInfo *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__auth_info__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__query__init
                     (Discovery__Query         *message)
{
  static Discovery__Query init_value = DISCOVERY__QUERY__INIT;
  *message = init_value;
}
size_t discovery__query__get_packed_size
                     (const Discovery__Query *message)
{
  assert(message->base.descriptor == &discovery__query__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__query__pack
                     (const Discovery__Query *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__query__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__query__pack_to_buffer
                     (const Discovery__Query *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__query__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__Query *
       discovery__query__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__Query *)
     protobuf_c_message_unpack (&discovery__query__descriptor,
                                allocator, len, data);
}
void   discovery__query__free_unpacked
                     (Discovery__Query *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__query__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__query_result__init
                     (Discovery__QueryResult         *message)
{
  static Discovery__QueryResult init_value = DISCOVERY__QUERY_RESULT__INIT;
  *message = init_value;
}
size_t discovery__query_result__get_packed_size
                     (const Discovery__QueryResult *message)
{
  assert(message->base.descriptor == &discovery__query_result__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__query_result__pack
                     (const Discovery__QueryResult *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__query_result__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__query_result__pack_to_buffer
                     (const Discovery__QueryResult *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__query_result__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__QueryResult *
       discovery__query_result__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__QueryResult *)
     protobuf_c_message_unpack (&discovery__query_result__descriptor,
                                allocator, len, data);
}
void   discovery__query_result__free_unpacked
                     (Discovery__QueryResult *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__query_result__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__config_query__init
                     (Discovery__ConfigQuery         *message)
{
  static Discovery__ConfigQuery init_value = DISCOVERY__CONFIG_QUERY__INIT;
  *message = init_value;
}
size_t discovery__config_query__get_packed_size
                     (const Discovery__ConfigQuery *message)
{
  assert(message->base.descriptor == &discovery__config_query__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__config_query__pack
                     (const Discovery__ConfigQuery *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__config_query__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__config_query__pack_to_buffer
                     (const Discovery__ConfigQuery *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__config_query__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__ConfigQuery *
       discovery__config_query__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__ConfigQuery *)
     protobuf_c_message_unpack (&discovery__config_query__descriptor,
                                allocator, len, data);
}
void   discovery__config_query__free_unpacked
                     (Discovery__ConfigQuery *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__config_query__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__config_result__msps_entry__init
                     (Discovery__ConfigResult__MspsEntry         *message)
{
  static Discovery__ConfigResult__MspsEntry init_value = DISCOVERY__CONFIG_RESULT__MSPS_ENTRY__INIT;
  *message = init_value;
}
void   discovery__config_result__orderers_entry__init
                     (Discovery__ConfigResult__OrderersEntry         *message)
{
  static Discovery__ConfigResult__OrderersEntry init_value = DISCOVERY__CONFIG_RESULT__ORDERERS_ENTRY__INIT;
  *message = init_value;
}
void   discovery__config_result__init
                     (Discovery__ConfigResult         *message)
{
  static Discovery__ConfigResult init_value = DISCOVERY__CONFIG_RESULT__INIT;
  *message = init_value;
}
size_t discovery__config_result__get_packed_size
                     (const Discovery__ConfigResult *message)
{
  assert(message->base.descriptor == &discovery__config_result__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__config_result__pack
                     (const Discovery__ConfigResult *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__config_result__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__config_result__pack_to_buffer
                     (const Discovery__ConfigResult *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__config_result__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__ConfigResult *
       discovery__config_result__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__ConfigResult *)
     protobuf_c_message_unpack (&discovery__config_result__descriptor,
                                allocator, len, data);
}
void   discovery__config_result__free_unpacked
                     (Discovery__ConfigResult *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__config_result__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__peer_membership_query__init
                     (Discovery__PeerMembershipQuery         *message)
{
  static Discovery__PeerMembershipQuery init_value = DISCOVERY__PEER_MEMBERSHIP_QUERY__INIT;
  *message = init_value;
}
size_t discovery__peer_membership_query__get_packed_size
                     (const Discovery__PeerMembershipQuery *message)
{
  assert(message->base.descriptor == &discovery__peer_membership_query__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__peer_membership_query__pack
                     (const Discovery__PeerMembershipQuery *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__peer_membership_query__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__peer_membership_query__pack_to_buffer
                     (const Discovery__PeerMembershipQuery *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__peer_membership_query__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__PeerMembershipQuery *
       discovery__peer_membership_query__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__PeerMembershipQuery *)
     protobuf_c_message_unpack (&discovery__peer_membership_query__descriptor,
                                allocator, len, data);
}
void   discovery__peer_membership_query__free_unpacked
                     (Discovery__PeerMembershipQuery *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__peer_membership_query__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__peer_membership_result__peers_by_org_entry__init
                     (Discovery__PeerMembershipResult__PeersByOrgEntry         *message)
{
  static Discovery__PeerMembershipResult__PeersByOrgEntry init_value = DISCOVERY__PEER_MEMBERSHIP_RESULT__PEERS_BY_ORG_ENTRY__INIT;
  *message = init_value;
}
void   discovery__peer_membership_result__init
                     (Discovery__PeerMembershipResult         *message)
{
  static Discovery__PeerMembershipResult init_value = DISCOVERY__PEER_MEMBERSHIP_RESULT__INIT;
  *message = init_value;
}
size_t discovery__peer_membership_result__get_packed_size
                     (const Discovery__PeerMembershipResult *message)
{
  assert(message->base.descriptor == &discovery__peer_membership_result__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__peer_membership_result__pack
                     (const Discovery__PeerMembershipResult *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__peer_membership_result__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__peer_membership_result__pack_to_buffer
                     (const Discovery__PeerMembershipResult *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__peer_membership_result__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__PeerMembershipResult *
       discovery__peer_membership_result__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__PeerMembershipResult *)
     protobuf_c_message_unpack (&discovery__peer_membership_result__descriptor,
                                allocator, len, data);
}
void   discovery__peer_membership_result__free_unpacked
                     (Discovery__PeerMembershipResult *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__peer_membership_result__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__chaincode_query__init
                     (Discovery__ChaincodeQuery         *message)
{
  static Discovery__ChaincodeQuery init_value = DISCOVERY__CHAINCODE_QUERY__INIT;
  *message = init_value;
}
size_t discovery__chaincode_query__get_packed_size
                     (const Discovery__ChaincodeQuery *message)
{
  assert(message->base.descriptor == &discovery__chaincode_query__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__chaincode_query__pack
                     (const Discovery__ChaincodeQuery *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__chaincode_query__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__chaincode_query__pack_to_buffer
                     (const Discovery__ChaincodeQuery *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__chaincode_query__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__ChaincodeQuery *
       discovery__chaincode_query__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__ChaincodeQuery *)
     protobuf_c_message_unpack (&discovery__chaincode_query__descriptor,
                                allocator, len, data);
}
void   discovery__chaincode_query__free_unpacked
                     (Discovery__ChaincodeQuery *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__chaincode_query__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__chaincode_interest__init
                     (Discovery__ChaincodeInterest         *message)
{
  static Discovery__ChaincodeInterest init_value = DISCOVERY__CHAINCODE_INTEREST__INIT;
  *message = init_value;
}
size_t discovery__chaincode_interest__get_packed_size
                     (const Discovery__ChaincodeInterest *message)
{
  assert(message->base.descriptor == &discovery__chaincode_interest__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__chaincode_interest__pack
                     (const Discovery__ChaincodeInterest *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__chaincode_interest__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__chaincode_interest__pack_to_buffer
                     (const Discovery__ChaincodeInterest *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__chaincode_interest__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__ChaincodeInterest *
       discovery__chaincode_interest__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__ChaincodeInterest *)
     protobuf_c_message_unpack (&discovery__chaincode_interest__descriptor,
                                allocator, len, data);
}
void   discovery__chaincode_interest__free_unpacked
                     (Discovery__ChaincodeInterest *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__chaincode_interest__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__chaincode_call__init
                     (Discovery__ChaincodeCall         *message)
{
  static Discovery__ChaincodeCall init_value = DISCOVERY__CHAINCODE_CALL__INIT;
  *message = init_value;
}
size_t discovery__chaincode_call__get_packed_size
                     (const Discovery__ChaincodeCall *message)
{
  assert(message->base.descriptor == &discovery__chaincode_call__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__chaincode_call__pack
                     (const Discovery__ChaincodeCall *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__chaincode_call__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__chaincode_call__pack_to_buffer
                     (const Discovery__ChaincodeCall *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__chaincode_call__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__ChaincodeCall *
       discovery__chaincode_call__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__ChaincodeCall *)
     protobuf_c_message_unpack (&discovery__chaincode_call__descriptor,
                                allocator, len, data);
}
void   discovery__chaincode_call__free_unpacked
                     (Discovery__ChaincodeCall *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__chaincode_call__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__chaincode_query_result__init
                     (Discovery__ChaincodeQueryResult         *message)
{
  static Discovery__ChaincodeQueryResult init_value = DISCOVERY__CHAINCODE_QUERY_RESULT__INIT;
  *message = init_value;
}
size_t discovery__chaincode_query_result__get_packed_size
                     (const Discovery__ChaincodeQueryResult *message)
{
  assert(message->base.descriptor == &discovery__chaincode_query_result__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__chaincode_query_result__pack
                     (const Discovery__ChaincodeQueryResult *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__chaincode_query_result__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__chaincode_query_result__pack_to_buffer
                     (const Discovery__ChaincodeQueryResult *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__chaincode_query_result__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__ChaincodeQueryResult *
       discovery__chaincode_query_result__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__ChaincodeQueryResult *)
     protobuf_c_message_unpack (&discovery__chaincode_query_result__descriptor,
                                allocator, len, data);
}
void   discovery__chaincode_query_result__free_unpacked
                     (Discovery__ChaincodeQueryResult *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__chaincode_query_result__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__local_peer_query__init
                     (Discovery__LocalPeerQuery         *message)
{
  static Discovery__LocalPeerQuery init_value = DISCOVERY__LOCAL_PEER_QUERY__INIT;
  *message = init_value;
}
size_t discovery__local_peer_query__get_packed_size
                     (const Discovery__LocalPeerQuery *message)
{
  assert(message->base.descriptor == &discovery__local_peer_query__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__local_peer_query__pack
                     (const Discovery__LocalPeerQuery *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__local_peer_query__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__local_peer_query__pack_to_buffer
                     (const Discovery__LocalPeerQuery *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__local_peer_query__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__LocalPeerQuery *
       discovery__local_peer_query__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__LocalPeerQuery *)
     protobuf_c_message_unpack (&discovery__local_peer_query__descriptor,
                                allocator, len, data);
}
void   discovery__local_peer_query__free_unpacked
                     (Discovery__LocalPeerQuery *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__local_peer_query__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__endorsement_descriptor__endorsers_by_groups_entry__init
                     (Discovery__EndorsementDescriptor__EndorsersByGroupsEntry         *message)
{
  static Discovery__EndorsementDescriptor__EndorsersByGroupsEntry init_value = DISCOVERY__ENDORSEMENT_DESCRIPTOR__ENDORSERS_BY_GROUPS_ENTRY__INIT;
  *message = init_value;
}
void   discovery__endorsement_descriptor__init
                     (Discovery__EndorsementDescriptor         *message)
{
  static Discovery__EndorsementDescriptor init_value = DISCOVERY__ENDORSEMENT_DESCRIPTOR__INIT;
  *message = init_value;
}
size_t discovery__endorsement_descriptor__get_packed_size
                     (const Discovery__EndorsementDescriptor *message)
{
  assert(message->base.descriptor == &discovery__endorsement_descriptor__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__endorsement_descriptor__pack
                     (const Discovery__EndorsementDescriptor *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__endorsement_descriptor__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__endorsement_descriptor__pack_to_buffer
                     (const Discovery__EndorsementDescriptor *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__endorsement_descriptor__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__EndorsementDescriptor *
       discovery__endorsement_descriptor__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__EndorsementDescriptor *)
     protobuf_c_message_unpack (&discovery__endorsement_descriptor__descriptor,
                                allocator, len, data);
}
void   discovery__endorsement_descriptor__free_unpacked
                     (Discovery__EndorsementDescriptor *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__endorsement_descriptor__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__layout__quantities_by_group_entry__init
                     (Discovery__Layout__QuantitiesByGroupEntry         *message)
{
  static Discovery__Layout__QuantitiesByGroupEntry init_value = DISCOVERY__LAYOUT__QUANTITIES_BY_GROUP_ENTRY__INIT;
  *message = init_value;
}
void   discovery__layout__init
                     (Discovery__Layout         *message)
{
  static Discovery__Layout init_value = DISCOVERY__LAYOUT__INIT;
  *message = init_value;
}
size_t discovery__layout__get_packed_size
                     (const Discovery__Layout *message)
{
  assert(message->base.descriptor == &discovery__layout__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__layout__pack
                     (const Discovery__Layout *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__layout__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__layout__pack_to_buffer
                     (const Discovery__Layout *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__layout__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__Layout *
       discovery__layout__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__Layout *)
     protobuf_c_message_unpack (&discovery__layout__descriptor,
                                allocator, len, data);
}
void   discovery__layout__free_unpacked
                     (Discovery__Layout *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__layout__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__peers__init
                     (Discovery__Peers         *message)
{
  static Discovery__Peers init_value = DISCOVERY__PEERS__INIT;
  *message = init_value;
}
size_t discovery__peers__get_packed_size
                     (const Discovery__Peers *message)
{
  assert(message->base.descriptor == &discovery__peers__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__peers__pack
                     (const Discovery__Peers *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__peers__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__peers__pack_to_buffer
                     (const Discovery__Peers *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__peers__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__Peers *
       discovery__peers__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__Peers *)
     protobuf_c_message_unpack (&discovery__peers__descriptor,
                                allocator, len, data);
}
void   discovery__peers__free_unpacked
                     (Discovery__Peers *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__peers__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__peer__init
                     (Discovery__Peer         *message)
{
  static Discovery__Peer init_value = DISCOVERY__PEER__INIT;
  *message = init_value;
}
size_t discovery__peer__get_packed_size
                     (const Discovery__Peer *message)
{
  assert(message->base.descriptor == &discovery__peer__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__peer__pack
                     (const Discovery__Peer *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__peer__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__peer__pack_to_buffer
                     (const Discovery__Peer *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__peer__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__Peer *
       discovery__peer__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__Peer *)
     protobuf_c_message_unpack (&discovery__peer__descriptor,
                                allocator, len, data);
}
void   discovery__peer__free_unpacked
                     (Discovery__Peer *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__peer__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__error__init
                     (Discovery__Error         *message)
{
  static Discovery__Error init_value = DISCOVERY__ERROR__INIT;
  *message = init_value;
}
size_t discovery__error__get_packed_size
                     (const Discovery__Error *message)
{
  assert(message->base.descriptor == &discovery__error__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__error__pack
                     (const Discovery__Error *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__error__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__error__pack_to_buffer
                     (const Discovery__Error *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__error__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__Error *
       discovery__error__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__Error *)
     protobuf_c_message_unpack (&discovery__error__descriptor,
                                allocator, len, data);
}
void   discovery__error__free_unpacked
                     (Discovery__Error *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__error__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__endpoints__init
                     (Discovery__Endpoints         *message)
{
  static Discovery__Endpoints init_value = DISCOVERY__ENDPOINTS__INIT;
  *message = init_value;
}
size_t discovery__endpoints__get_packed_size
                     (const Discovery__Endpoints *message)
{
  assert(message->base.descriptor == &discovery__endpoints__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__endpoints__pack
                     (const Discovery__Endpoints *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__endpoints__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__endpoints__pack_to_buffer
                     (const Discovery__Endpoints *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__endpoints__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__Endpoints *
       discovery__endpoints__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__Endpoints *)
     protobuf_c_message_unpack (&discovery__endpoints__descriptor,
                                allocator, len, data);
}
void   discovery__endpoints__free_unpacked
                     (Discovery__Endpoints *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__endpoints__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
void   discovery__endpoint__init
                     (Discovery__Endpoint         *message)
{
  static Discovery__Endpoint init_value = DISCOVERY__ENDPOINT__INIT;
  *message = init_value;
}
size_t discovery__endpoint__get_packed_size
                     (const Discovery__Endpoint *message)
{
  assert(message->base.descriptor == &discovery__endpoint__descriptor);
  return protobuf_c_message_get_packed_size ((const ProtobufCMessage*)(message));
}
size_t discovery__endpoint__pack
                     (const Discovery__Endpoint *message,
                      uint8_t       *out)
{
  assert(message->base.descriptor == &discovery__endpoint__descriptor);
  return protobuf_c_message_pack ((const ProtobufCMessage*)message, out);
}
size_t discovery__endpoint__pack_to_buffer
                     (const Discovery__Endpoint *message,
                      ProtobufCBuffer *buffer)
{
  assert(message->base.descriptor == &discovery__endpoint__descriptor);
  return protobuf_c_message_pack_to_buffer ((const ProtobufCMessage*)message, buffer);
}
Discovery__Endpoint *
       discovery__endpoint__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data)
{
  return (Discovery__Endpoint *)
     protobuf_c_message_unpack (&discovery__endpoint__descriptor,
                                allocator, len, data);
}
void   discovery__endpoint__free_unpacked
                     (Discovery__Endpoint *message,
                      ProtobufCAllocator *allocator)
{
  assert(message->base.descriptor == &discovery__endpoint__descriptor);
  protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator);
}
static const ProtobufCFieldDescriptor discovery__signed_request__field_descriptors[2] =
{
  {
    "payload",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_BYTES,
    offsetof(Discovery__SignedRequest, has_payload),
    offsetof(Discovery__SignedRequest, payload),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "signature",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_BYTES,
    offsetof(Discovery__SignedRequest, has_signature),
    offsetof(Discovery__SignedRequest, signature),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__signed_request__field_indices_by_name[] = {
  0,   /* field[0] = payload */
  1,   /* field[1] = signature */
};
static const ProtobufCIntRange discovery__signed_request__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__signed_request__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.SignedRequest",
  "SignedRequest",
  "Discovery__SignedRequest",
  "discovery",
  sizeof(Discovery__SignedRequest),
  2,
  discovery__signed_request__field_descriptors,
  discovery__signed_request__field_indices_by_name,
  1,  discovery__signed_request__number_ranges,
  (ProtobufCMessageInit) discovery__signed_request__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__request__field_descriptors[2] =
{
  {
    "authentication",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    0,   /* quantifier_offset */
    offsetof(Discovery__Request, authentication),
    &discovery__auth_info__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "queries",
    2,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__Request, n_queries),
    offsetof(Discovery__Request, queries),
    &discovery__query__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__request__field_indices_by_name[] = {
  0,   /* field[0] = authentication */
  1,   /* field[1] = queries */
};
static const ProtobufCIntRange discovery__request__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__request__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.Request",
  "Request",
  "Discovery__Request",
  "discovery",
  sizeof(Discovery__Request),
  2,
  discovery__request__field_descriptors,
  discovery__request__field_indices_by_name,
  1,  discovery__request__number_ranges,
  (ProtobufCMessageInit) discovery__request__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__response__field_descriptors[1] =
{
  {
    "results",
    1,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__Response, n_results),
    offsetof(Discovery__Response, results),
    &discovery__query_result__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__response__field_indices_by_name[] = {
  0,   /* field[0] = results */
};
static const ProtobufCIntRange discovery__response__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 1 }
};
const ProtobufCMessageDescriptor discovery__response__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.Response",
  "Response",
  "Discovery__Response",
  "discovery",
  sizeof(Discovery__Response),
  1,
  discovery__response__field_descriptors,
  discovery__response__field_indices_by_name,
  1,  discovery__response__number_ranges,
  (ProtobufCMessageInit) discovery__response__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__auth_info__field_descriptors[2] =
{
  {
    "client_identity",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_BYTES,
    offsetof(Discovery__AuthInfo, has_client_identity),
    offsetof(Discovery__AuthInfo, client_identity),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "client_tls_cert_hash",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_BYTES,
    offsetof(Discovery__AuthInfo, has_client_tls_cert_hash),
    offsetof(Discovery__AuthInfo, client_tls_cert_hash),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__auth_info__field_indices_by_name[] = {
  0,   /* field[0] = client_identity */
  1,   /* field[1] = client_tls_cert_hash */
};
static const ProtobufCIntRange discovery__auth_info__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__auth_info__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.AuthInfo",
  "AuthInfo",
  "Discovery__AuthInfo",
  "discovery",
  sizeof(Discovery__AuthInfo),
  2,
  discovery__auth_info__field_descriptors,
  discovery__auth_info__field_indices_by_name,
  1,  discovery__auth_info__number_ranges,
  (ProtobufCMessageInit) discovery__auth_info__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__query__field_descriptors[5] =
{
  {
    "channel",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_STRING,
    0,   /* quantifier_offset */
    offsetof(Discovery__Query, channel),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "config_query",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__Query, query_case),
    offsetof(Discovery__Query, config_query),
    &discovery__config_query__descriptor,
    NULL,
    0 | PROTOBUF_C_FIELD_FLAG_ONEOF,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "peer_query",
    3,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__Query, query_case),
    offsetof(Discovery__Query, peer_query),
    &discovery__peer_membership_query__descriptor,
    NULL,
    0 | PROTOBUF_C_FIELD_FLAG_ONEOF,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "cc_query",
    4,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__Query, query_case),
    offsetof(Discovery__Query, cc_query),
    &discovery__chaincode_query__descriptor,
    NULL,
    0 | PROTOBUF_C_FIELD_FLAG_ONEOF,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "local_peers",
    5,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__Query, query_case),
    offsetof(Discovery__Query, local_peers),
    &discovery__local_peer_query__descriptor,
    NULL,
    0 | PROTOBUF_C_FIELD_FLAG_ONEOF,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__query__field_indices_by_name[] = {
  3,   /* field[3] = cc_query */
  0,   /* field[0] = channel */
  1,   /* field[1] = config_query */
  4,   /* field[4] = local_peers */
  2,   /* field[2] = peer_query */
};
static const ProtobufCIntRange discovery__query__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 5 }
};
const ProtobufCMessageDescriptor discovery__query__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.Query",
  "Query",
  "Discovery__Query",
  "discovery",
  sizeof(Discovery__Query),
  5,
  discovery__query__field_descriptors,
  discovery__query__field_indices_by_name,
  1,  discovery__query__number_ranges,
  (ProtobufCMessageInit) discovery__query__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__query_result__field_descriptors[4] =
{
  {
    "error",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__QueryResult, result_case),
    offsetof(Discovery__QueryResult, error),
    &discovery__error__descriptor,
    NULL,
    0 | PROTOBUF_C_FIELD_FLAG_ONEOF,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "config_result",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__QueryResult, result_case),
    offsetof(Discovery__QueryResult, config_result),
    &discovery__config_result__descriptor,
    NULL,
    0 | PROTOBUF_C_FIELD_FLAG_ONEOF,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "cc_query_res",
    3,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__QueryResult, result_case),
    offsetof(Discovery__QueryResult, cc_query_res),
    &discovery__chaincode_query_result__descriptor,
    NULL,
    0 | PROTOBUF_C_FIELD_FLAG_ONEOF,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "members",
    4,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__QueryResult, result_case),
    offsetof(Discovery__QueryResult, members),
    &discovery__peer_membership_result__descriptor,
    NULL,
    0 | PROTOBUF_C_FIELD_FLAG_ONEOF,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__query_result__field_indices_by_name[] = {
  2,   /* field[2] = cc_query_res */
  1,   /* field[1] = config_result */
  0,   /* field[0] = error */
  3,   /* field[3] = members */
};
static const ProtobufCIntRange discovery__query_result__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 4 }
};
const ProtobufCMessageDescriptor discovery__query_result__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.QueryResult",
  "QueryResult",
  "Discovery__QueryResult",
  "discovery",
  sizeof(Discovery__QueryResult),
  4,
  discovery__query_result__field_descriptors,
  discovery__query_result__field_indices_by_name,
  1,  discovery__query_result__number_ranges,
  (ProtobufCMessageInit) discovery__query_result__init,
  NULL,NULL,NULL    /* reserved[123] */
};
#define discovery__config_query__field_descriptors NULL
#define discovery__config_query__field_indices_by_name NULL
#define discovery__config_query__number_ranges NULL
const ProtobufCMessageDescriptor discovery__config_query__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.ConfigQuery",
  "ConfigQuery",
  "Discovery__ConfigQuery",
  "discovery",
  sizeof(Discovery__ConfigQuery),
  0,
  discovery__config_query__field_descriptors,
  discovery__config_query__field_indices_by_name,
  0,  discovery__config_query__number_ranges,
  (ProtobufCMessageInit) discovery__config_query__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__config_result__msps_entry__field_descriptors[2] =
{
  {
    "key",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_STRING,
    0,   /* quantifier_offset */
    offsetof(Discovery__ConfigResult__MspsEntry, key),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "value",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    0,   /* quantifier_offset */
    offsetof(Discovery__ConfigResult__MspsEntry, value),
    &msp__fabric_mspconfig__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__config_result__msps_entry__field_indices_by_name[] = {
  0,   /* field[0] = key */
  1,   /* field[1] = value */
};
static const ProtobufCIntRange discovery__config_result__msps_entry__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__config_result__msps_entry__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.ConfigResult.MspsEntry",
  "MspsEntry",
  "Discovery__ConfigResult__MspsEntry",
  "discovery",
  sizeof(Discovery__ConfigResult__MspsEntry),
  2,
  discovery__config_result__msps_entry__field_descriptors,
  discovery__config_result__msps_entry__field_indices_by_name,
  1,  discovery__config_result__msps_entry__number_ranges,
  (ProtobufCMessageInit) discovery__config_result__msps_entry__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__config_result__orderers_entry__field_descriptors[2] =
{
  {
    "key",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_STRING,
    0,   /* quantifier_offset */
    offsetof(Discovery__ConfigResult__OrderersEntry, key),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "value",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    0,   /* quantifier_offset */
    offsetof(Discovery__ConfigResult__OrderersEntry, value),
    &discovery__endpoints__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__config_result__orderers_entry__field_indices_by_name[] = {
  0,   /* field[0] = key */
  1,   /* field[1] = value */
};
static const ProtobufCIntRange discovery__config_result__orderers_entry__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__config_result__orderers_entry__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.ConfigResult.OrderersEntry",
  "OrderersEntry",
  "Discovery__ConfigResult__OrderersEntry",
  "discovery",
  sizeof(Discovery__ConfigResult__OrderersEntry),
  2,
  discovery__config_result__orderers_entry__field_descriptors,
  discovery__config_result__orderers_entry__field_indices_by_name,
  1,  discovery__config_result__orderers_entry__number_ranges,
  (ProtobufCMessageInit) discovery__config_result__orderers_entry__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__config_result__field_descriptors[2] =
{
  {
    "msps",
    1,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__ConfigResult, n_msps),
    offsetof(Discovery__ConfigResult, msps),
    &discovery__config_result__msps_entry__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "orderers",
    2,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__ConfigResult, n_orderers),
    offsetof(Discovery__ConfigResult, orderers),
    &discovery__config_result__orderers_entry__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__config_result__field_indices_by_name[] = {
  0,   /* field[0] = msps */
  1,   /* field[1] = orderers */
};
static const ProtobufCIntRange discovery__config_result__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__config_result__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.ConfigResult",
  "ConfigResult",
  "Discovery__ConfigResult",
  "discovery",
  sizeof(Discovery__ConfigResult),
  2,
  discovery__config_result__field_descriptors,
  discovery__config_result__field_indices_by_name,
  1,  discovery__config_result__number_ranges,
  (ProtobufCMessageInit) discovery__config_result__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__peer_membership_query__field_descriptors[1] =
{
  {
    "filter",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    0,   /* quantifier_offset */
    offsetof(Discovery__PeerMembershipQuery, filter),
    &discovery__chaincode_interest__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__peer_membership_query__field_indices_by_name[] = {
  0,   /* field[0] = filter */
};
static const ProtobufCIntRange discovery__peer_membership_query__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 1 }
};
const ProtobufCMessageDescriptor discovery__peer_membership_query__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.PeerMembershipQuery",
  "PeerMembershipQuery",
  "Discovery__PeerMembershipQuery",
  "discovery",
  sizeof(Discovery__PeerMembershipQuery),
  1,
  discovery__peer_membership_query__field_descriptors,
  discovery__peer_membership_query__field_indices_by_name,
  1,  discovery__peer_membership_query__number_ranges,
  (ProtobufCMessageInit) discovery__peer_membership_query__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__peer_membership_result__peers_by_org_entry__field_descriptors[2] =
{
  {
    "key",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_STRING,
    0,   /* quantifier_offset */
    offsetof(Discovery__PeerMembershipResult__PeersByOrgEntry, key),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "value",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    0,   /* quantifier_offset */
    offsetof(Discovery__PeerMembershipResult__PeersByOrgEntry, value),
    &discovery__peers__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__peer_membership_result__peers_by_org_entry__field_indices_by_name[] = {
  0,   /* field[0] = key */
  1,   /* field[1] = value */
};
static const ProtobufCIntRange discovery__peer_membership_result__peers_by_org_entry__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__peer_membership_result__peers_by_org_entry__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.PeerMembershipResult.PeersByOrgEntry",
  "PeersByOrgEntry",
  "Discovery__PeerMembershipResult__PeersByOrgEntry",
  "discovery",
  sizeof(Discovery__PeerMembershipResult__PeersByOrgEntry),
  2,
  discovery__peer_membership_result__peers_by_org_entry__field_descriptors,
  discovery__peer_membership_result__peers_by_org_entry__field_indices_by_name,
  1,  discovery__peer_membership_result__peers_by_org_entry__number_ranges,
  (ProtobufCMessageInit) discovery__peer_membership_result__peers_by_org_entry__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__peer_membership_result__field_descriptors[1] =
{
  {
    "peers_by_org",
    1,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__PeerMembershipResult, n_peers_by_org),
    offsetof(Discovery__PeerMembershipResult, peers_by_org),
    &discovery__peer_membership_result__peers_by_org_entry__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__peer_membership_result__field_indices_by_name[] = {
  0,   /* field[0] = peers_by_org */
};
static const ProtobufCIntRange discovery__peer_membership_result__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 1 }
};
const ProtobufCMessageDescriptor discovery__peer_membership_result__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.PeerMembershipResult",
  "PeerMembershipResult",
  "Discovery__PeerMembershipResult",
  "discovery",
  sizeof(Discovery__PeerMembershipResult),
  1,
  discovery__peer_membership_result__field_descriptors,
  discovery__peer_membership_result__field_indices_by_name,
  1,  discovery__peer_membership_result__number_ranges,
  (ProtobufCMessageInit) discovery__peer_membership_result__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__chaincode_query__field_descriptors[1] =
{
  {
    "interests",
    1,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__ChaincodeQuery, n_interests),
    offsetof(Discovery__ChaincodeQuery, interests),
    &discovery__chaincode_interest__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__chaincode_query__field_indices_by_name[] = {
  0,   /* field[0] = interests */
};
static const ProtobufCIntRange discovery__chaincode_query__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 1 }
};
const ProtobufCMessageDescriptor discovery__chaincode_query__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.ChaincodeQuery",
  "ChaincodeQuery",
  "Discovery__ChaincodeQuery",
  "discovery",
  sizeof(Discovery__ChaincodeQuery),
  1,
  discovery__chaincode_query__field_descriptors,
  discovery__chaincode_query__field_indices_by_name,
  1,  discovery__chaincode_query__number_ranges,
  (ProtobufCMessageInit) discovery__chaincode_query__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__chaincode_interest__field_descriptors[1] =
{
  {
    "chaincodes",
    1,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__ChaincodeInterest, n_chaincodes),
    offsetof(Discovery__ChaincodeInterest, chaincodes),
    &discovery__chaincode_call__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__chaincode_interest__field_indices_by_name[] = {
  0,   /* field[0] = chaincodes */
};
static const ProtobufCIntRange discovery__chaincode_interest__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 1 }
};
const ProtobufCMessageDescriptor discovery__chaincode_interest__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.ChaincodeInterest",
  "ChaincodeInterest",
  "Discovery__ChaincodeInterest",
  "discovery",
  sizeof(Discovery__ChaincodeInterest),
  1,
  discovery__chaincode_interest__field_descriptors,
  discovery__chaincode_interest__field_indices_by_name,
  1,  discovery__chaincode_interest__number_ranges,
  (ProtobufCMessageInit) discovery__chaincode_interest__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__chaincode_call__field_descriptors[2] =
{
  {
    "name",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_STRING,
    0,   /* quantifier_offset */
    offsetof(Discovery__ChaincodeCall, name),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "collection_names",
    2,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_STRING,
    offsetof(Discovery__ChaincodeCall, n_collection_names),
    offsetof(Discovery__ChaincodeCall, collection_names),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__chaincode_call__field_indices_by_name[] = {
  1,   /* field[1] = collection_names */
  0,   /* field[0] = name */
};
static const ProtobufCIntRange discovery__chaincode_call__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__chaincode_call__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.ChaincodeCall",
  "ChaincodeCall",
  "Discovery__ChaincodeCall",
  "discovery",
  sizeof(Discovery__ChaincodeCall),
  2,
  discovery__chaincode_call__field_descriptors,
  discovery__chaincode_call__field_indices_by_name,
  1,  discovery__chaincode_call__number_ranges,
  (ProtobufCMessageInit) discovery__chaincode_call__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__chaincode_query_result__field_descriptors[1] =
{
  {
    "content",
    1,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__ChaincodeQueryResult, n_content),
    offsetof(Discovery__ChaincodeQueryResult, content),
    &discovery__endorsement_descriptor__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__chaincode_query_result__field_indices_by_name[] = {
  0,   /* field[0] = content */
};
static const ProtobufCIntRange discovery__chaincode_query_result__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 1 }
};
const ProtobufCMessageDescriptor discovery__chaincode_query_result__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.ChaincodeQueryResult",
  "ChaincodeQueryResult",
  "Discovery__ChaincodeQueryResult",
  "discovery",
  sizeof(Discovery__ChaincodeQueryResult),
  1,
  discovery__chaincode_query_result__field_descriptors,
  discovery__chaincode_query_result__field_indices_by_name,
  1,  discovery__chaincode_query_result__number_ranges,
  (ProtobufCMessageInit) discovery__chaincode_query_result__init,
  NULL,NULL,NULL    /* reserved[123] */
};
#define discovery__local_peer_query__field_descriptors NULL
#define discovery__local_peer_query__field_indices_by_name NULL
#define discovery__local_peer_query__number_ranges NULL
const ProtobufCMessageDescriptor discovery__local_peer_query__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.LocalPeerQuery",
  "LocalPeerQuery",
  "Discovery__LocalPeerQuery",
  "discovery",
  sizeof(Discovery__LocalPeerQuery),
  0,
  discovery__local_peer_query__field_descriptors,
  discovery__local_peer_query__field_indices_by_name,
  0,  discovery__local_peer_query__number_ranges,
  (ProtobufCMessageInit) discovery__local_peer_query__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__endorsement_descriptor__endorsers_by_groups_entry__field_descriptors[2] =
{
  {
    "key",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_STRING,
    0,   /* quantifier_offset */
    offsetof(Discovery__EndorsementDescriptor__EndorsersByGroupsEntry, key),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "value",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    0,   /* quantifier_offset */
    offsetof(Discovery__EndorsementDescriptor__EndorsersByGroupsEntry, value),
    &discovery__peers__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__endorsement_descriptor__endorsers_by_groups_entry__field_indices_by_name[] = {
  0,   /* field[0] = key */
  1,   /* field[1] = value */
};
static const ProtobufCIntRange discovery__endorsement_descriptor__endorsers_by_groups_entry__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__endorsement_descriptor__endorsers_by_groups_entry__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.EndorsementDescriptor.EndorsersByGroupsEntry",
  "EndorsersByGroupsEntry",
  "Discovery__EndorsementDescriptor__EndorsersByGroupsEntry",
  "discovery",
  sizeof(Discovery__EndorsementDescriptor__EndorsersByGroupsEntry),
  2,
  discovery__endorsement_descriptor__endorsers_by_groups_entry__field_descriptors,
  discovery__endorsement_descriptor__endorsers_by_groups_entry__field_indices_by_name,
  1,  discovery__endorsement_descriptor__endorsers_by_groups_entry__number_ranges,
  (ProtobufCMessageInit) discovery__endorsement_descriptor__endorsers_by_groups_entry__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__endorsement_descriptor__field_descriptors[3] =
{
  {
    "chaincode",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_STRING,
    0,   /* quantifier_offset */
    offsetof(Discovery__EndorsementDescriptor, chaincode),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "endorsers_by_groups",
    2,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__EndorsementDescriptor, n_endorsers_by_groups),
    offsetof(Discovery__EndorsementDescriptor, endorsers_by_groups),
    &discovery__endorsement_descriptor__endorsers_by_groups_entry__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "layouts",
    3,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__EndorsementDescriptor, n_layouts),
    offsetof(Discovery__EndorsementDescriptor, layouts),
    &discovery__layout__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__endorsement_descriptor__field_indices_by_name[] = {
  0,   /* field[0] = chaincode */
  1,   /* field[1] = endorsers_by_groups */
  2,   /* field[2] = layouts */
};
static const ProtobufCIntRange discovery__endorsement_descriptor__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 3 }
};
const ProtobufCMessageDescriptor discovery__endorsement_descriptor__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.EndorsementDescriptor",
  "EndorsementDescriptor",
  "Discovery__EndorsementDescriptor",
  "discovery",
  sizeof(Discovery__EndorsementDescriptor),
  3,
  discovery__endorsement_descriptor__field_descriptors,
  discovery__endorsement_descriptor__field_indices_by_name,
  1,  discovery__endorsement_descriptor__number_ranges,
  (ProtobufCMessageInit) discovery__endorsement_descriptor__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__layout__quantities_by_group_entry__field_descriptors[2] =
{
  {
    "key",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_STRING,
    0,   /* quantifier_offset */
    offsetof(Discovery__Layout__QuantitiesByGroupEntry, key),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "value",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_UINT32,
    offsetof(Discovery__Layout__QuantitiesByGroupEntry, has_value),
    offsetof(Discovery__Layout__QuantitiesByGroupEntry, value),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__layout__quantities_by_group_entry__field_indices_by_name[] = {
  0,   /* field[0] = key */
  1,   /* field[1] = value */
};
static const ProtobufCIntRange discovery__layout__quantities_by_group_entry__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__layout__quantities_by_group_entry__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.Layout.QuantitiesByGroupEntry",
  "QuantitiesByGroupEntry",
  "Discovery__Layout__QuantitiesByGroupEntry",
  "discovery",
  sizeof(Discovery__Layout__QuantitiesByGroupEntry),
  2,
  discovery__layout__quantities_by_group_entry__field_descriptors,
  discovery__layout__quantities_by_group_entry__field_indices_by_name,
  1,  discovery__layout__quantities_by_group_entry__number_ranges,
  (ProtobufCMessageInit) discovery__layout__quantities_by_group_entry__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__layout__field_descriptors[1] =
{
  {
    "quantities_by_group",
    1,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__Layout, n_quantities_by_group),
    offsetof(Discovery__Layout, quantities_by_group),
    &discovery__layout__quantities_by_group_entry__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__layout__field_indices_by_name[] = {
  0,   /* field[0] = quantities_by_group */
};
static const ProtobufCIntRange discovery__layout__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 1 }
};
const ProtobufCMessageDescriptor discovery__layout__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.Layout",
  "Layout",
  "Discovery__Layout",
  "discovery",
  sizeof(Discovery__Layout),
  1,
  discovery__layout__field_descriptors,
  discovery__layout__field_indices_by_name,
  1,  discovery__layout__number_ranges,
  (ProtobufCMessageInit) discovery__layout__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__peers__field_descriptors[1] =
{
  {
    "peers",
    1,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__Peers, n_peers),
    offsetof(Discovery__Peers, peers),
    &discovery__peer__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__peers__field_indices_by_name[] = {
  0,   /* field[0] = peers */
};
static const ProtobufCIntRange discovery__peers__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 1 }
};
const ProtobufCMessageDescriptor discovery__peers__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.Peers",
  "Peers",
  "Discovery__Peers",
  "discovery",
  sizeof(Discovery__Peers),
  1,
  discovery__peers__field_descriptors,
  discovery__peers__field_indices_by_name,
  1,  discovery__peers__number_ranges,
  (ProtobufCMessageInit) discovery__peers__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__peer__field_descriptors[3] =
{
  {
    "state_info",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    0,   /* quantifier_offset */
    offsetof(Discovery__Peer, state_info),
    &gossip__envelope__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "membership_info",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_MESSAGE,
    0,   /* quantifier_offset */
    offsetof(Discovery__Peer, membership_info),
    &gossip__envelope__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "identity",
    3,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_BYTES,
    offsetof(Discovery__Peer, has_identity),
    offsetof(Discovery__Peer, identity),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__peer__field_indices_by_name[] = {
  2,   /* field[2] = identity */
  1,   /* field[1] = membership_info */
  0,   /* field[0] = state_info */
};
static const ProtobufCIntRange discovery__peer__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 3 }
};
const ProtobufCMessageDescriptor discovery__peer__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.Peer",
  "Peer",
  "Discovery__Peer",
  "discovery",
  sizeof(Discovery__Peer),
  3,
  discovery__peer__field_descriptors,
  discovery__peer__field_indices_by_name,
  1,  discovery__peer__number_ranges,
  (ProtobufCMessageInit) discovery__peer__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__error__field_descriptors[1] =
{
  {
    "content",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_STRING,
    0,   /* quantifier_offset */
    offsetof(Discovery__Error, content),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__error__field_indices_by_name[] = {
  0,   /* field[0] = content */
};
static const ProtobufCIntRange discovery__error__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 1 }
};
const ProtobufCMessageDescriptor discovery__error__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.Error",
  "Error",
  "Discovery__Error",
  "discovery",
  sizeof(Discovery__Error),
  1,
  discovery__error__field_descriptors,
  discovery__error__field_indices_by_name,
  1,  discovery__error__number_ranges,
  (ProtobufCMessageInit) discovery__error__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__endpoints__field_descriptors[1] =
{
  {
    "endpoint",
    1,
    PROTOBUF_C_LABEL_REPEATED,
    PROTOBUF_C_TYPE_MESSAGE,
    offsetof(Discovery__Endpoints, n_endpoint),
    offsetof(Discovery__Endpoints, endpoint),
    &discovery__endpoint__descriptor,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__endpoints__field_indices_by_name[] = {
  0,   /* field[0] = endpoint */
};
static const ProtobufCIntRange discovery__endpoints__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 1 }
};
const ProtobufCMessageDescriptor discovery__endpoints__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.Endpoints",
  "Endpoints",
  "Discovery__Endpoints",
  "discovery",
  sizeof(Discovery__Endpoints),
  1,
  discovery__endpoints__field_descriptors,
  discovery__endpoints__field_indices_by_name,
  1,  discovery__endpoints__number_ranges,
  (ProtobufCMessageInit) discovery__endpoints__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCFieldDescriptor discovery__endpoint__field_descriptors[2] =
{
  {
    "host",
    1,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_STRING,
    0,   /* quantifier_offset */
    offsetof(Discovery__Endpoint, host),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
  {
    "port",
    2,
    PROTOBUF_C_LABEL_OPTIONAL,
    PROTOBUF_C_TYPE_UINT32,
    offsetof(Discovery__Endpoint, has_port),
    offsetof(Discovery__Endpoint, port),
    NULL,
    NULL,
    0,             /* flags */
    0,NULL,NULL    /* reserved1,reserved2, etc */
  },
};
static const unsigned discovery__endpoint__field_indices_by_name[] = {
  0,   /* field[0] = host */
  1,   /* field[1] = port */
};
static const ProtobufCIntRange discovery__endpoint__number_ranges[1 + 1] =
{
  { 1, 0 },
  { 0, 2 }
};
const ProtobufCMessageDescriptor discovery__endpoint__descriptor =
{
  PROTOBUF_C__MESSAGE_DESCRIPTOR_MAGIC,
  "discovery.Endpoint",
  "Endpoint",
  "Discovery__Endpoint",
  "discovery",
  sizeof(Discovery__Endpoint),
  2,
  discovery__endpoint__field_descriptors,
  discovery__endpoint__field_indices_by_name,
  1,  discovery__endpoint__number_ranges,
  (ProtobufCMessageInit) discovery__endpoint__init,
  NULL,NULL,NULL    /* reserved[123] */
};
static const ProtobufCMethodDescriptor discovery__discovery__method_descriptors[1] =
{
  { "Discover", &discovery__signed_request__descriptor, &discovery__response__descriptor },
};
const unsigned discovery__discovery__method_indices_by_name[] = {
  0         /* Discover */
};
const ProtobufCServiceDescriptor discovery__discovery__descriptor =
{
  PROTOBUF_C__SERVICE_DESCRIPTOR_MAGIC,
  "discovery.Discovery",
  "Discovery",
  "Discovery__Discovery",
  "discovery",
  1,
  discovery__discovery__method_descriptors,
  discovery__discovery__method_indices_by_name
};
void discovery__discovery__discover(ProtobufCService *service,
                                    const Discovery__SignedRequest *input,
                                    Discovery__Response_Closure closure,
                                    void *closure_data)
{
  assert(service->descriptor == &discovery__discovery__descriptor);
  service->invoke(service, 0, (const ProtobufCMessage *) input, (ProtobufCClosure) closure, closure_data);
}
void discovery__discovery__init (Discovery__Discovery_Service *service,
                                 Discovery__Discovery_ServiceDestroy destroy)
{
  protobuf_c_service_generated_init (&service->base,
                                     &discovery__discovery__descriptor,
                                     (ProtobufCServiceDestroy) destroy);
}
