public final class Logging extends GeneratedMessageV3 implements LoggingOrBuilder
Logging configuration of the service.
The following example shows how to configure logs to be sent to the
producer and consumer projects. In the example, the activity_history
log is sent to both the producer and consumer projects, whereas the
purchase_history
log is only sent to the producer project.
monitored_resources:
- type: library.googleapis.com/branch
labels:
- key: /city
description: The city where the library branch is located in.
- key: /name
description: The name of the branch.
logs:
- name: activity_history
labels:
- name: purchase_history
logging:
producer_destinations:
- monitored_resource: library.googleapis.com/branch
logs:
- activity_history
- purchase_history
consumer_destinations:
- monitored_resource: library.googleapis.com/branch
logs:
Protobuf type google.api.Logging
Static Fields
CONSUMER_DESTINATIONS_FIELD_NUMBER
public static final int CONSUMER_DESTINATIONS_FIELD_NUMBER
Field Value
PRODUCER_DESTINATIONS_FIELD_NUMBER
public static final int PRODUCER_DESTINATIONS_FIELD_NUMBER
Field Value
Static Methods
getDefaultInstance()
public static Logging getDefaultInstance()
Returns
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
newBuilder()
public static Logging.Builder newBuilder()
Returns
newBuilder(Logging prototype)
public static Logging.Builder newBuilder(Logging prototype)
Parameter
Returns
public static Logging parseDelimitedFrom(InputStream input)
Parameter
Returns
Exceptions
public static Logging parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(byte[] data)
public static Logging parseFrom(byte[] data)
Parameter
Name | Description |
data | byte[]
|
Returns
Exceptions
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static Logging parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteString data)
public static Logging parseFrom(ByteString data)
Parameter
Returns
Exceptions
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Logging parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static Logging parseFrom(CodedInputStream input)
Parameter
Returns
Exceptions
public static Logging parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static Logging parseFrom(InputStream input)
Parameter
Returns
Exceptions
public static Logging parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteBuffer data)
public static Logging parseFrom(ByteBuffer data)
Parameter
Returns
Exceptions
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static Logging parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parser()
public static Parser<Logging> parser()
Returns
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter
Returns
Overrides
getConsumerDestinations(int index)
public Logging.LoggingDestination getConsumerDestinations(int index)
Logging configurations for sending logs to the consumer project.
There can be multiple consumer destinations, each one must have a
different monitored resource type. A log can be used in at most
one consumer destination.
repeated .google.api.Logging.LoggingDestination consumer_destinations = 2;
Parameter
Returns
getConsumerDestinationsCount()
public int getConsumerDestinationsCount()
Logging configurations for sending logs to the consumer project.
There can be multiple consumer destinations, each one must have a
different monitored resource type. A log can be used in at most
one consumer destination.
repeated .google.api.Logging.LoggingDestination consumer_destinations = 2;
Returns
getConsumerDestinationsList()
public List<Logging.LoggingDestination> getConsumerDestinationsList()
Logging configurations for sending logs to the consumer project.
There can be multiple consumer destinations, each one must have a
different monitored resource type. A log can be used in at most
one consumer destination.
repeated .google.api.Logging.LoggingDestination consumer_destinations = 2;
Returns
getConsumerDestinationsOrBuilder(int index)
public Logging.LoggingDestinationOrBuilder getConsumerDestinationsOrBuilder(int index)
Logging configurations for sending logs to the consumer project.
There can be multiple consumer destinations, each one must have a
different monitored resource type. A log can be used in at most
one consumer destination.
repeated .google.api.Logging.LoggingDestination consumer_destinations = 2;
Parameter
Returns
getConsumerDestinationsOrBuilderList()
public List<? extends Logging.LoggingDestinationOrBuilder> getConsumerDestinationsOrBuilderList()
Logging configurations for sending logs to the consumer project.
There can be multiple consumer destinations, each one must have a
different monitored resource type. A log can be used in at most
one consumer destination.
repeated .google.api.Logging.LoggingDestination consumer_destinations = 2;
Returns
Type | Description |
List<? extends com.google.api.Logging.LoggingDestinationOrBuilder> | |
getDefaultInstanceForType()
public Logging getDefaultInstanceForType()
Returns
getParserForType()
public Parser<Logging> getParserForType()
Returns
Overrides
getProducerDestinations(int index)
public Logging.LoggingDestination getProducerDestinations(int index)
Logging configurations for sending logs to the producer project.
There can be multiple producer destinations, each one must have a
different monitored resource type. A log can be used in at most
one producer destination.
repeated .google.api.Logging.LoggingDestination producer_destinations = 1;
Parameter
Returns
getProducerDestinationsCount()
public int getProducerDestinationsCount()
Logging configurations for sending logs to the producer project.
There can be multiple producer destinations, each one must have a
different monitored resource type. A log can be used in at most
one producer destination.
repeated .google.api.Logging.LoggingDestination producer_destinations = 1;
Returns
getProducerDestinationsList()
public List<Logging.LoggingDestination> getProducerDestinationsList()
Logging configurations for sending logs to the producer project.
There can be multiple producer destinations, each one must have a
different monitored resource type. A log can be used in at most
one producer destination.
repeated .google.api.Logging.LoggingDestination producer_destinations = 1;
Returns
getProducerDestinationsOrBuilder(int index)
public Logging.LoggingDestinationOrBuilder getProducerDestinationsOrBuilder(int index)
Logging configurations for sending logs to the producer project.
There can be multiple producer destinations, each one must have a
different monitored resource type. A log can be used in at most
one producer destination.
repeated .google.api.Logging.LoggingDestination producer_destinations = 1;
Parameter
Returns
getProducerDestinationsOrBuilderList()
public List<? extends Logging.LoggingDestinationOrBuilder> getProducerDestinationsOrBuilderList()
Logging configurations for sending logs to the producer project.
There can be multiple producer destinations, each one must have a
different monitored resource type. A log can be used in at most
one producer destination.
repeated .google.api.Logging.LoggingDestination producer_destinations = 1;
Returns
Type | Description |
List<? extends com.google.api.Logging.LoggingDestinationOrBuilder> | |
getSerializedSize()
public int getSerializedSize()
Returns
Overrides
getUnknownFields()
public final UnknownFieldSet getUnknownFields()
Returns
Overrides
hashCode()
Returns
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
newBuilderForType()
public Logging.Builder newBuilderForType()
Returns
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected Logging.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Returns
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Returns
Overrides
toBuilder()
public Logging.Builder toBuilder()
Returns
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Parameter
Overrides
Exceptions