You can use Cloud Monitoring and Cloud Logging with Service Directory.
Monitoring
Monitoring allows you to create dashboards or set up
alerts, and can be accessed by visiting
Monitoring
in Google Cloud Console. To view basic monitoring metrics (request
count, size and latency), go to the Metrics Explorer and filter by
resource_type:consumed_api
and service:servicedirectory.googleapis.com
.
Logging
Service Directory produces audit logs that can be viewed through Logging.
Audit Logs
Audit logs can help you answer the questions "Who did what, where, and when?". Service Directory writes two types of audit logs: admin activity and data access. Admin activity logs are always enabled and apply to the following Service Directory operations:
- CreateNamespace
- UpdateNamespace
- DeleteNamespace
- SetIamPolicy
All other Service Directory operations are considered data access logs and are not enabled by default. Data access logs are also subject to Logging pricing and quota, whereas neither applies to admin activity logs. To enable data access logging, see Configuring Data Access logs.
To see these logs in
Logging,
select Service Directory Namespace
from the Resource dropdown and
cloudaudit.googleapis.com/activity
or cloudaudit.googleapis.com/data_access
,
as appropriate, from the Logs dropdown.
What's next
- To get a thorough understanding of Monitoring, see the Monitoring documentation