Class AttributeContext.Types.Peer

Stay organized with collections Save and categorize content based on your preferences.
public sealed class Peer : Protobuf.IMessage<AttributeContext.Types.Peer>, Protobuf.IBufferMessage

This message defines attributes for a node that handles a network request. The node can be either a service or an application that sends, forwards, or receives the request. Service peers should fill in principal and labels as appropriate.

Inheritance

Object > AttributeContext.Types.Peer

Namespace

Google.Rpc.Context

Assembly

Google.Api.CommonProtos.dll

Constructors

Peer()

public Peer()

Peer(AttributeContext.Types.Peer)

public Peer(AttributeContext.Types.Peer other)
Parameter
TypeNameDescription
AttributeContext.Types.Peerother

Fields

IpFieldNumber

public const int IpFieldNumber = 1

Field number for the "ip" field.

Field Value
TypeDescription
Int32

LabelsFieldNumber

public const int LabelsFieldNumber = 6

Field number for the "labels" field.

Field Value
TypeDescription
Int32

PortFieldNumber

public const int PortFieldNumber = 2

Field number for the "port" field.

Field Value
TypeDescription
Int32

PrincipalFieldNumber

public const int PrincipalFieldNumber = 7

Field number for the "principal" field.

Field Value
TypeDescription
Int32

RegionCodeFieldNumber

public const int RegionCodeFieldNumber = 8

Field number for the "region_code" field.

Field Value
TypeDescription
Int32

Properties

Descriptor

public static Protobuf.Reflection.MessageDescriptor Descriptor { get; }
Property Value
TypeDescription
Protobuf.Reflection.MessageDescriptor

Ip

public string Ip { get; set; }

The IP address of the peer.

Property Value
TypeDescription
String

Labels

public Protobuf.Collections.MapField<string, string> Labels { get; }

The labels associated with the peer.

Property Value
TypeDescription
Protobuf.Collections.MapField<String, String>

Parser

public static Protobuf.MessageParser<AttributeContext.Types.Peer> Parser { get; }
Property Value
TypeDescription
Protobuf.MessageParser<AttributeContext.Types.Peer>

Port

public long Port { get; set; }

The network port of the peer.

Property Value
TypeDescription
Int64

Principal

public string Principal { get; set; }

The identity of this peer. Similar to Request.auth.principal, but relative to the peer instead of the request. For example, the idenity associated with a load balancer that forwared the request.

Property Value
TypeDescription
String

RegionCode

public string RegionCode { get; set; }

The CLDR country/region code associated with the above IP address. If the IP address is private, the region_code should reflect the physical location where this peer is running.

Property Value
TypeDescription
String

Methods

CalculateSize()

public int CalculateSize()
Returns
TypeDescription
Int32

Clone()

public AttributeContext.Types.Peer Clone()
Returns
TypeDescription
AttributeContext.Types.Peer

Equals(AttributeContext.Types.Peer)

public bool Equals(AttributeContext.Types.Peer other)
Parameter
TypeNameDescription
AttributeContext.Types.Peerother
Returns
TypeDescription
Boolean

Equals(Object)

public override bool Equals(object other)
Parameter
TypeNameDescription
Objectother
Returns
TypeDescription
Boolean

GetHashCode()

public override int GetHashCode()
Returns
TypeDescription
Int32

MergeFrom(Protobuf.CodedInputStream)

public void MergeFrom(Protobuf.CodedInputStream input)
Parameter
TypeNameDescription
Protobuf.CodedInputStreaminput

MergeFrom(AttributeContext.Types.Peer)

public void MergeFrom(AttributeContext.Types.Peer other)
Parameter
TypeNameDescription
AttributeContext.Types.Peerother

ToString()

public override string ToString()
Returns
TypeDescription
String

WriteTo(Protobuf.CodedOutputStream)

public void WriteTo(Protobuf.CodedOutputStream output)
Parameter
TypeNameDescription
Protobuf.CodedOutputStreamoutput

Implements