This ensures only users who have permission to view the logs have access to those logs in Google Stackdriver
This allows for more filtering and exclusion options to define what logs make it into Google Stackdriver.
These fields will allow for consistently intuitive searching of logs and log fragments within Google Stackdriver. To learn how to mark logs with custom fields, please read Creating custom tags in Google Stackdriver Logs
Generic Node Resource
All logs sent from the BindPlane log agent will be available under the Generic Node Resource
- Select Logs Ingestion
- Find the row labeled Generic Node.
- Select Create exclusion filter based on this resource.
- Define your filter for the exclusion being made and provide a Name, Description, and Percentage to Exclude
- Click the Create exclusion button.
The following provides examples of filters and some best practices around creating exclusion filters.
The following filters incoming data by log level, commonly excluding non-error logs, unless debugging.
resource.type="generic_node" and jsonPayload.severity=("INFO" OR "DEBUG" OR "TRACE")
With BindPlane, we recommend making exclusions for each log type. This allows you to enable debug logging for an application that is being debugged without enabling debugging for unnecessary log types.
The following example creates an exclusion for the MySQL log type:
resource.type="generic_node" and jsonPayload.severity=("INFO" OR "DEBUG" OR "TRACE") and jsonPayload.bindplane_source_type="mysql"
- Parse out all possible fields.
- Know what specific attributes you can consistently search on.
- Logically organizing log-based metrics based on deployments, or services.
- Parse all numbers without units.
All numeric values should be parsed to leave only the number as the value. This will significantly decrease the amount of effort needed to build metrics within Stackdriver.
BindPlane provides, in every event, the following fields for consistency across logging types.
The hostname where the agent is installed (also known as the agent name)
The GCP project ID. This is set by the service role that is used to upload logs.
The GCP location the logs are sent to. The configuration is available in the
This value can be set to anything, but BindPlane sets this value equal to the type of log information (JBoss, Tomcat, etc).
This includes all fields that are parsed by regex, or other means, the severity level of the log, and the message of that log that will be shown in Stackdriver as the base message.
In the filter for BindPlane logging, set the
resource.labels.node_id equal to the hostname you want to filter logs for.
To filter for logs related to specific application there are two methods.
- Use the Tag Drop Down to filter for specific application logs.
- Using the advanced filter for Stackdriver Logging, use the
jsonPayload.bindplane_source_typeresource to filter for specific application logs.
Updated 8 months ago