Log Service allows you to save query and analysis results as charts to a dashboard. This topic describes how to add charts to a dashboard.
A dashboard can contain a maximum of 50 charts.
You can add multiple charts to a dashboard. You can add a chart to the dashboard at a time.
- Log on to the Log Service console.
- In the Projects section, click the name of the project that you want to view.
- Query logs.
- Choose . On the Logstores tab, click the Logstore that you want to view.
- On the Search & Analysis page, enter a query statement in the search box and click Search & Analyze.
- On the Graph tab, select a chart type.
- On the Properties tab, configure the properties of the chart. The properties that you can configure vary based on the chart types. For more information, see Charts.
- Optional:Configure a placeholder variable. Before you configure a drill-down event and filter data, you must configure a placeholder variable for the chart. For example, you can configure the drill-down event of Chart A to redirect to the dashboard on which Chart B is located. After you configure the drill-down event of Chart A, the placeholder variable is replaced by the variable that you click to trigger the drill-down event and execute the query statement of Chart B. This way, to trigger the drill-down event, you must click the placeholder variable that you configured for Chart B. For more information, see Configure a drill-down event.
- On the Data Source tab, select the keyword in the query statement and click Generate Variable. You can configure multiple placeholder variables.
- Configure the parameters of a placeholder variable.
Parameter Description Variable Name The name of the placeholder variable. Default Value The default value of the placeholder variable in the current chart. Matching Mode Valid values:
- Global Match: replaces all keywords that are the same as the keyword that you select in the query statement with the name of the placeholder variable.
- Exact Match: replaces only the keyword that you select in the query statement with the name of the placeholder variable.
Result The query statement that contains the configured placeholder variable.
- On the Data Source tab, select the keyword in the query statement and click Generate Variable.
- Optional:Configure a drill-down event. After you configure a drill-down event for the chart, you can click a value on the chart to view more details and perform analysis.On the Interactive Behavior tab, configure a drill-down event. For more information, see Configure a drill-down event.
- Click Add to New Dashboard.
- In the Add to New Dashboard dialog box, specify the dashboard and chart name and click OK.
Parameter Description Operation Valid values:
- Add to Existing Dashboard: adds the chart to an existing dashboard.
- Create Dashboard: creates a dashboard and adds the chart to the dashboard.
Dashboards Select an existing dashboard.
This parameter is required only if you set the Operation parameter to Add to Existing Dashboard.
Dashboard Name Enter a name for the new dashboard.
This parameter is required only if you set the Operation parameter to Create Dashboard.
Chart Name Enter a name for the chart. The chart name is displayed as the chart title on the dashboard.