Torch Log Service
Configuration | Description |
Configuration | Description |
Task name | Task name of the schedule SQL analysis task. |
Description | A brief description of the schedule SQL analysis task. |
Source project | The project where the raw logs for schedule SQL analysis are stored. |
Source topic | The topic where the raw logs for schedule SQL analysis are stored. |
Target topic | After executing the schedule SQL analysis task, the processed log data is stored in the managed Prometheus workspace.
|
Task status | Determines whether to start the schedule SQL analysis task immediately.
|
Configuration | Description |
Configuration | Description |
Start time | The schedule SQL analysis task’s start time, i.e., the time when the first instance is scheduled. After starting, TLS creates instances and runs schedule SQL analysis on time according to specified rules. |
End time | The end time for scheduling the SQL analysis task. After the task ends, TLS will not create instances or perform scheduled SQL analysis. However, the task remains running until it is paused manually. |
Scheduling cycle | The schedule cycle for scheduled SQL analysis tasks. It determines the timing for each instance. The schedule period supports specifying time intervals or fixed trigger times. It is recommended to set the schedule period to be greater than or equal to the length of the query time window. Otherwise, analysis might be delayed and the query results may be inaccurate. For example, if the schedule period is every 10 minutes, the maximum length of the SQL time window is 10 minutes. You can select any of the following configurations:
|
Time zone selection | You need to select a time zone when the scheduling cycle is set to Cron. For a list of common time zones, see Select time zone. |
SQL time window | When a scheduled SQL analysis task runs, the time range for log query and analysis uses a left-closed, right-open format. For a managed Prometheus instance, the maximum SQL time window is 6 hours. For syntax details, see SQL time window syntax. Supports quick filling with the following expressions:
Description Configuration example:
The first instance is created at 2023-8-14 10:00:00 and starts execution at 10:00:10. This instance analyzes log data from the period [09:00:00~10:00:00). The second instance is created at 2023-8-14 11:00:00 and starts execution at 11:00:10. This instance analyzes log data from the period [10:00:00~11:00:00). |
SQL | The scheduled SQL analysis task executes query statements periodically. These statements must follow the query and analysis syntax of TLS. For detailed syntax instructions, see Query overview and Analysis overview. |
Metric name | Select numeric fields from SQL query results to use as metric names for managed Prometheus time series. Metric names indicate the meaning of the monitored sample. For related concepts, see Time series data format for managed Prometheus.
|
Metric label | Select non-time type fields from SQL query results to use as metric labels for managed Prometheus time series. Metric labels represent sample feature dimensions, and these dimensions (such as those in group by) enable managed Prometheus to filter and aggregate sample data.
|
Custom label | Set custom label keys and values for metric labels.
|
Time column | Select a time type field from the SQL execution results as the time column. This column sets the time for metric data. If not selected, the metric data time will use the start time from the SQL time range.
|
Task timeout | When a task exceeds the maximum timeout or retry limit, the scheduled SQL sets its status to failed and finishes. You can receive alerts and retry manually.
|
Execution delay | The delay for each schedule execution. Its supported settings range from 0 to 120 seconds. When the log data volume is large or the collection task is busy, writing data to the log topic may be delayed. In this case, specify an execution delay to ensure data completeness during query and analysis. |