public class DefaultLoggingRpc extends Object implements LoggingRpc
| Constructor and Description |
|---|
DefaultLoggingRpc(LoggingOptions options) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
Future<com.google.logging.v2.LogMetric> |
create(com.google.logging.v2.CreateLogMetricRequest request)
Sends a request to create a log metric.
|
Future<com.google.logging.v2.LogSink> |
create(com.google.logging.v2.CreateSinkRequest request)
Sends a request to create a sink.
|
Future<com.google.protobuf.Empty> |
delete(com.google.logging.v2.DeleteLogMetricRequest request)
Sends a request to delete a log metric.
|
Future<com.google.protobuf.Empty> |
delete(com.google.logging.v2.DeleteLogRequest request)
Sends a request to deletes a log.
|
Future<com.google.protobuf.Empty> |
delete(com.google.logging.v2.DeleteSinkRequest request)
Sends a request to delete a sink.
|
Future<com.google.logging.v2.LogMetric> |
get(com.google.logging.v2.GetLogMetricRequest request)
Sends a request to get a log metric.
|
Future<com.google.logging.v2.LogSink> |
get(com.google.logging.v2.GetSinkRequest request)
Sends a request to get a sink.
|
Future<com.google.logging.v2.ListLogEntriesResponse> |
list(com.google.logging.v2.ListLogEntriesRequest request)
Sends a request to list log entries.
|
Future<com.google.logging.v2.ListLogMetricsResponse> |
list(com.google.logging.v2.ListLogMetricsRequest request)
Sends a request to list the log metrics in a project.
|
Future<com.google.logging.v2.ListMonitoredResourceDescriptorsResponse> |
list(com.google.logging.v2.ListMonitoredResourceDescriptorsRequest request)
Sends a request to list monitored resource descriptors.
|
Future<com.google.logging.v2.ListSinksResponse> |
list(com.google.logging.v2.ListSinksRequest request)
Sends a request to list the sinks in a project.
|
Future<com.google.logging.v2.LogMetric> |
update(com.google.logging.v2.UpdateLogMetricRequest request)
Sends a request to update a log metric.
|
Future<com.google.logging.v2.LogSink> |
update(com.google.logging.v2.UpdateSinkRequest request)
Sends a request to update a sink.
|
Future<com.google.logging.v2.WriteLogEntriesResponse> |
write(com.google.logging.v2.WriteLogEntriesRequest request)
Sends a request to write log entries to Stackdriver Logging.
|
public DefaultLoggingRpc(LoggingOptions options) throws IOException
IOExceptionpublic Future<com.google.logging.v2.LogSink> create(com.google.logging.v2.CreateSinkRequest request)
LoggingRpcFuture object to consume the
result. Future.get() returns the created sink.create in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.logging.v2.LogSink> update(com.google.logging.v2.UpdateSinkRequest request)
LoggingRpcFuture object to consume the result. Future.get() returns the updated
or created sink.update in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.logging.v2.LogSink> get(com.google.logging.v2.GetSinkRequest request)
LoggingRpcFuture object to consume the
result. Future.get() returns the requested sink or null if not found.get in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.logging.v2.ListSinksResponse> list(com.google.logging.v2.ListSinksRequest request)
LoggingRpcFuture object to
consume the result. Future.get() returns a response object containing the listing
result.list in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.protobuf.Empty> delete(com.google.logging.v2.DeleteSinkRequest request)
LoggingRpcFuture object to consume the
result. Future.get() returns Empty.getDefaultInstance() or null if the
sink was not found.delete in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.protobuf.Empty> delete(com.google.logging.v2.DeleteLogRequest request)
LoggingRpcFuture object to consume the
result. Future.get() returns Empty.getDefaultInstance() or null if the
log was not found. The deleted log will reappear if it receives new log entries.delete in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.logging.v2.WriteLogEntriesResponse> write(com.google.logging.v2.WriteLogEntriesRequest request)
LoggingRpcFuture object to consume the result. Future.get() returns a response object for
the write operation.write in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.logging.v2.ListLogEntriesResponse> list(com.google.logging.v2.ListLogEntriesRequest request)
LoggingRpcFuture object to consume the result.
Future.get() returns a response object containing the listing result.list in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.logging.v2.ListMonitoredResourceDescriptorsResponse> list(com.google.logging.v2.ListMonitoredResourceDescriptorsRequest request)
LoggingRpcFuture
object to consume the result. Future.get() returns a response object containing the
listing result.list in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.logging.v2.LogMetric> create(com.google.logging.v2.CreateLogMetricRequest request)
LoggingRpcFuture object to consume
the result. Future.get() returns the created metric.create in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.logging.v2.LogMetric> update(com.google.logging.v2.UpdateLogMetricRequest request)
LoggingRpcFuture object to consume the result. Future.get() returns the
updated or created log metric.update in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.logging.v2.LogMetric> get(com.google.logging.v2.GetLogMetricRequest request)
LoggingRpcFuture object to consume the
result. Future.get() returns the requested log metric or null if not found.get in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.logging.v2.ListLogMetricsResponse> list(com.google.logging.v2.ListLogMetricsRequest request)
LoggingRpcFuture
object to consume the result. Future.get() returns a response object containing the
listing result.list in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic Future<com.google.protobuf.Empty> delete(com.google.logging.v2.DeleteLogMetricRequest request)
LoggingRpcFuture object to consume
the result. Future.get() returns Empty.getDefaultInstance() or null if
the log was not found.delete in interface LoggingRpcrequest - the request object containing all of the parameters for the API callpublic void close()
throws Exception
close in interface AutoCloseableExceptionCopyright © 2016 Google. All rights reserved.