0
votes

I have been trying to setup cloud logging so that logs are written to cloud storage but excluded from StackDriver logs. Reading the documentation I think this is possible and that exports should get priority over exclusions.

  • On the log router page I have created a sink to write logs to cloud storage, this is working on its own and I can see the logs in the selected bucket.

  • From the "logs ingestion" page on the "Exclusions" tab I defined an exclusion. But once this is enabled logs are no-longer written to the bucket.

1

1 Answers

0
votes

If the log entry matches the exclusion rule put in place, then the log entry will be discarded. If the log entry does not match the exclusion put in place, then the log entry will be exported to its destination. You can read more about how the Stackdriver logging router handles exports and exclusions here.