Google Cloud Logging v2 API - Class LoggingServiceV2ClientImpl (4.1.0)

public sealed class LoggingServiceV2ClientImpl : LoggingServiceV2Client

Reference documentation and code samples for the Google Cloud Logging v2 API class LoggingServiceV2ClientImpl.

LoggingServiceV2 client wrapper implementation, for convenient use.

Inheritance

object > LoggingServiceV2Client > LoggingServiceV2ClientImpl

Namespace

Google.Cloud.Logging.V2

Assembly

Google.Cloud.Logging.V2.dll

Remarks

Service for ingesting and querying logs.

Constructors

LoggingServiceV2ClientImpl(LoggingServiceV2Client, LoggingServiceV2Settings, ILogger)

public LoggingServiceV2ClientImpl(LoggingServiceV2.LoggingServiceV2Client grpcClient, LoggingServiceV2Settings settings, ILogger logger)

Constructs a client wrapper for the LoggingServiceV2 service, with the specified gRPC client and settings.

Parameters
NameDescription
grpcClientLoggingServiceV2LoggingServiceV2Client

The underlying gRPC client.

settingsLoggingServiceV2Settings

The base LoggingServiceV2Settings used within this client.

loggerILogger

Optional ILogger to use within this client.

Properties

GrpcClient

public override LoggingServiceV2.LoggingServiceV2Client GrpcClient { get; }

The underlying gRPC LoggingServiceV2 client

Property Value
TypeDescription
LoggingServiceV2LoggingServiceV2Client
Overrides

Methods

DeleteLog(DeleteLogRequest, CallSettings)

public override void DeleteLog(DeleteLogRequest request, CallSettings callSettings = null)

Deletes all the log entries in a log for the _Default Log Bucket. The log reappears if it receives new entries. Log entries written shortly before the delete operation might not be deleted. Entries received after the delete operation with a timestamp before the operation will be deleted.

Parameters
NameDescription
requestDeleteLogRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Overrides

DeleteLogAsync(DeleteLogRequest, CallSettings)

public override Task DeleteLogAsync(DeleteLogRequest request, CallSettings callSettings = null)

Deletes all the log entries in a log for the _Default Log Bucket. The log reappears if it receives new entries. Log entries written shortly before the delete operation might not be deleted. Entries received after the delete operation with a timestamp before the operation will be deleted.

Parameters
NameDescription
requestDeleteLogRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task

A Task containing the RPC response.

Overrides

ListLogEntries(ListLogEntriesRequest, CallSettings)

public override PagedEnumerable<ListLogEntriesResponse, LogEntry> ListLogEntries(ListLogEntriesRequest request, CallSettings callSettings = null)

Lists log entries. Use this method to retrieve log entries that originated from a project/folder/organization/billing account. For ways to export log entries, see Exporting Logs.

Parameters
NameDescription
requestListLogEntriesRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListLogEntriesResponseLogEntry

A pageable sequence of LogEntry resources.

Overrides

ListLogEntriesAsync(ListLogEntriesRequest, CallSettings)

public override PagedAsyncEnumerable<ListLogEntriesResponse, LogEntry> ListLogEntriesAsync(ListLogEntriesRequest request, CallSettings callSettings = null)

Lists log entries. Use this method to retrieve log entries that originated from a project/folder/organization/billing account. For ways to export log entries, see Exporting Logs.

Parameters
NameDescription
requestListLogEntriesRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListLogEntriesResponseLogEntry

A pageable asynchronous sequence of LogEntry resources.

Overrides

ListLogs(ListLogsRequest, CallSettings)

public override PagedEnumerable<ListLogsResponse, string> ListLogs(ListLogsRequest request, CallSettings callSettings = null)

Lists the logs in projects, organizations, folders, or billing accounts. Only logs that have entries are listed.

Parameters
NameDescription
requestListLogsRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListLogsResponsestring

A pageable sequence of string resources.

Overrides

ListLogsAsync(ListLogsRequest, CallSettings)

public override PagedAsyncEnumerable<ListLogsResponse, string> ListLogsAsync(ListLogsRequest request, CallSettings callSettings = null)

Lists the logs in projects, organizations, folders, or billing accounts. Only logs that have entries are listed.

Parameters
NameDescription
requestListLogsRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListLogsResponsestring

A pageable asynchronous sequence of string resources.

Overrides

ListMonitoredResourceDescriptors(ListMonitoredResourceDescriptorsRequest, CallSettings)

public override PagedEnumerable<ListMonitoredResourceDescriptorsResponse, MonitoredResourceDescriptor> ListMonitoredResourceDescriptors(ListMonitoredResourceDescriptorsRequest request, CallSettings callSettings = null)

Lists the descriptors for monitored resource types used by Logging.

Parameters
NameDescription
requestListMonitoredResourceDescriptorsRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListMonitoredResourceDescriptorsResponseMonitoredResourceDescriptor

A pageable sequence of MonitoredResourceDescriptor resources.

Overrides

ListMonitoredResourceDescriptorsAsync(ListMonitoredResourceDescriptorsRequest, CallSettings)

public override PagedAsyncEnumerable<ListMonitoredResourceDescriptorsResponse, MonitoredResourceDescriptor> ListMonitoredResourceDescriptorsAsync(ListMonitoredResourceDescriptorsRequest request, CallSettings callSettings = null)

Lists the descriptors for monitored resource types used by Logging.

Parameters
NameDescription
requestListMonitoredResourceDescriptorsRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListMonitoredResourceDescriptorsResponseMonitoredResourceDescriptor

A pageable asynchronous sequence of MonitoredResourceDescriptor resources.

Overrides

TailLogEntries(CallSettings, BidirectionalStreamingSettings)

public override LoggingServiceV2Client.TailLogEntriesStream TailLogEntries(CallSettings callSettings = null, BidirectionalStreamingSettings streamingSettings = null)

Streaming read of log entries as they are ingested. Until the stream is terminated, it will continue reading logs.

Parameters
NameDescription
callSettingsCallSettings

If not null, applies overrides to this RPC call.

streamingSettingsBidirectionalStreamingSettings

If not null, applies streaming overrides to this RPC call.

Returns
TypeDescription
LoggingServiceV2ClientTailLogEntriesStream

The client-server stream.

Overrides

WriteLogEntries(WriteLogEntriesRequest, CallSettings)

public override WriteLogEntriesResponse WriteLogEntries(WriteLogEntriesRequest request, CallSettings callSettings = null)

Writes log entries to Logging. This API method is the only way to send log entries to Logging. This method is used, directly or indirectly, by the Logging agent (fluentd) and all logging libraries configured to use Logging. A single request may contain log entries for a maximum of 1000 different resources (projects, organizations, billing accounts or folders)

Parameters
NameDescription
requestWriteLogEntriesRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
WriteLogEntriesResponse

The RPC response.

Overrides

WriteLogEntriesAsync(WriteLogEntriesRequest, CallSettings)

public override Task<WriteLogEntriesResponse> WriteLogEntriesAsync(WriteLogEntriesRequest request, CallSettings callSettings = null)

Writes log entries to Logging. This API method is the only way to send log entries to Logging. This method is used, directly or indirectly, by the Logging agent (fluentd) and all logging libraries configured to use Logging. A single request may contain log entries for a maximum of 1000 different resources (projects, organizations, billing accounts or folders)

Parameters
NameDescription
requestWriteLogEntriesRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskWriteLogEntriesResponse

A Task containing the RPC response.

Overrides