tencent cloud

피드백

Creating Task

마지막 업데이트 시간:2024-01-20 17:44:35

    Overview

    This document describes how to create a scheduled SQL analysis task.

    Prerequisites

    The CLS service has been activated, and key-value index has been enabled.
    Make sure that the current account has the permission to configure scheduled SQL analysis. For more information, see Examples of Custom Access Policies.

    Directions

    1. Log in to the CLS console.
    2. Click Data Processing > Scheduled SQL Task on the left sidebar and click
    
    to create a task.
    3. On the basic configuration page, configure the following information and click Next:
    Task Name: Enter a custom task name.
    Source Log Topic: Select the log topic where to run the SQL analysis task.
    SQL Statement: Enter the SQL statement in Query Statement, and the system will return the preview results (up to 100 items).
    Target Log Topic: Select the target log topic where to save SQL analysis results.
    4. On the scheduling configuration page, configure the following information and click OK.
    Scheduling Range: Set the time range for running the scheduled task. The default value is to start at the current time and last forever, i.e., running continuously.
    Scheduling Cycle: Set the cycle of the scheduled task, i.e., execution every X minutes. The maximum value is 1,440.
    SQL Time Window: Set the start and end time of the SQL query log data.
    Common SQL Time Window Expression (Suppose It's 12:06 Now)
    SQL Time Window
    Description
    @m-1h, @m
    11:06 - 12:06
    `@m` and `-1h` indicate to take the value down to the minute and subtract 1 hour, respectively.
    @h-1h,@h
    11:00 - 12:00
    `@h` and `-1h` indicate to take the value down to the hour and subtract 1 hour, respectively.
    @m-1h+20m,@h+25m
    11:26 - 12:25
    `@m`, `-1h`, `+20m`, `@h`, and `+25m` indicate to take the value down to the minute, subtract 1 hour, add 20 minutes, take the value down to the hour, and add 25 minutes, respectively.

    Example

    The following example illustrates the configurations of the scheduling range, scheduling cycle, and SQL time window:
    
    
    문의하기

    고객의 업무에 전용 서비스를 제공해드립니다.

    기술 지원

    더 많은 도움이 필요하시면, 티켓을 통해 연락 바랍니다. 티켓 서비스는 연중무휴 24시간 제공됩니다.

    연중무휴 24시간 전화 지원