All Products
Search
Document Center

:UpdateBaseline

更新時間:May 16, 2024

Updates a baseline.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter

Type

Required

Example

Description

Action

String

Yes

UpdateBaseline

The operation that you want to perform. Set the value to UpdateBaseline.

BaselineId

Long

Yes

1000010800007

The baseline ID. You can call the ListBaselines operation to query the ID.

ProjectId

Long

Yes

2043

The workspace ID. You can call the ListBaselines operation to query the ID.

BaselineName

String

No

BaselineName

The name of the baseline.

Owner

String

No

3726346****

The ID of the Alibaba Cloud account used by the baseline owner.

Priority

Integer

No

7

The priority of the baseline. Valid values: 1, 3, 5, 7, and 8.

NodeIds

String

No

1,2,3

The ancestor nodes of nodes in the baseline. Separate the ancestor nodes with commas (,). If a large number of ancestor nodes exist, we recommend that you create a zero load node and configure the zero load node as the descendant node of nodes in the baseline to facilitate node management.

OvertimeSettings

Array of OvertimeSetting

No

The settings of the committed completion time of the baseline.

Cycle

Integer

No

1

The cycle that corresponds to the committed completion time. For a day-level baseline, set this parameter to 1. For an hour-level baseline, set this parameter to a value that does not exceed 24.

Time

String

No

00:00

The committed completion time. Specify the time in the hh:mm format. Valid values of hh: 0 to 47. Valid values of mm: 0 to 59.

AlertMarginThreshold

Integer

No

30

The alert margin threshold. Unit: minutes.

BaselineType

String

No

DAILY

The type of the baseline. Valid values: DAILY and HOURLY. The value DAILY indicates that the baseline is a day-level baseline. The value HOURLY indicates that the baseline is an hour-level baseline.

Enabled

Boolean

No

true

Specifies whether to enable the baseline. Valid values: true and false.

AlertEnabled

Boolean

No

true

Specifies whether to enable the alerting feature. Valid values: true and false.

AlertSettings

Array of AlertSetting

No

The alert settings of the baseline.

AlertType

String

No

BASELINE

The type of the alert. Valid values:

  • BASELINE: baseline alert

  • TOPIC: event alert

AlertMethods

Array of String

No

SMS

The alert notification methods.

SilenceStartTime

String

No

00:00:00

The start time of silence.

SilenceEndTime

String

No

00:00:00

The end time of silence.

AlertInterval

Integer

No

1800

The interval at which an event alert notification is sent. Unit: seconds. Minimum value: 900.

AlertMaximum

Integer

No

1

The maximum number of times an event alert notification is sent. Maximum value: 24.

DingRobots

Array of DingRobot

No

The DingTalk chatbots.

WebUrl

String

No

https://oapi.dingtalk.com/robot/send?access_token=xxx

The webhook URL of the DingTalk chatbot.

AtAll

Boolean

No

false

Specifies whether to remind all members by using the at sign (@). Valid values: true and false.

Webhooks

Array of String

No

https://open.feishu.cn/open-apis/bot/v2/hook/xxx

The webhook URL of the WeCom or Lark chatbot. You can specify multiple webhook URLs. Separate multiple webhook URLs with commas (,). You must specify WEBHOOKS for AlertMethods. If this parameter is set to undefined, the specified webhook URLs are cleared.

Only DataWorks Enterprise Edition supports this parameter.

The webhook URL-based alerting feature is supported in the following regions: China (Shanghai), China (Chengdu), China (Zhangjiakou), China (Beijing), China (Hangzhou), China (Shenzhen), China (Hong Kong), Germany (Frankfurt), and Singapore.

TopicTypes

Array of String

No

SLOW

The type of the event. Valid values: SLOW and ERROR. The value SLOW indicates that the running duration of a specific node in the current scheduling cycle is significantly longer than the average running duration of the node in previous scheduling cycles. The value ERROR indicates that a specific node fails to run. You can specify multiple event types. Separate multiple event types with commas (,).

BaselineAlertEnabled

Boolean

No

true

Specifies whether to enable the baseline alerting feature. This feature is specific to baselines. Valid values: true and false.

AlertRecipientType

String

No

OWNER

The type of the alert recipient. Valid values: OWNER, OTHER, and SHIFT_SCHEDULE. The value OWNER indicates the node owner. The value OTHER indicates specified personnel. The value SHIFT_SCHEDULE indicates personnel in a shift schedule.

AlertRecipient

String

No

123123

The details of the alert recipient. If you set AlertRecipientType to OWNER, leave this parameter empty. If you set AlertRecipientType to SHIFT_SCHEDULE, set this parameter to the name of the shift schedule. If you set AlertRecipientType to OTHER, set this parameter to the employee IDs of specified personnel.

RemoveNodeIds

String

No

123,456

The ID of the node that you want to disassociate from the baseline. You can specify multiple node IDs. Separate multiple node IDs with commas (,).

Response parameters

Parameter

Type

Example

Description

Success

Boolean

true

Indicates whether the request was successful.

ErrorCode

String

401

The error code.

ErrorMessage

String

The specified parameters are invalid.

The error message.

HttpStatusCode

Integer

200

The HTTP status code.

Data

Boolean

true

Indicates whether the baseline was updated.

RequestId

String

6E07E90B-D9BC-5D6B-896A-82BA41A34AE1

The request ID.

Examples

Sample requests

http(s)://[Endpoint]/?Action=UpdateBaseline
&BaselineId=1000010800007
&ProjectId=2043
&BaselineName=BaselineName
&Owner=3726346****
&Priority=7
&NodeIds=1,2,3
&OvertimeSettings=[{"Cycle":1,"Time":"00:00"}]
&AlertMarginThreshold=30
&BaselineType=DAILY
&Enabled=true
&AlertEnabled=true
&AlertSettings=[{"AlertType":"BASELINE","AlertMethods":["SMS"],"SilenceStartTime":"00:00:00","SilenceEndTime":"00:00:00","AlertInterval":1800,"AlertMaximum":1,"DingRobots":[{"WebUrl":"https://oapi.dingtalk.com/robot/send?access_token=xxx\t","AtAll":false}],"Webhooks":["https://open.feishu.cn/open-apis/bot/v2/hook/xxx\t"],"TopicTypes":["SLOW"],"BaselineAlertEnabled":true,"AlertRecipientType":"OWNER","AlertRecipient":"123123"}]
&RemoveNodeIds=123,456
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<UpdateBaselineResponse>
    <Success>true</Success>
    <ErrorCode>401</ErrorCode>
    <ErrorMessage>The specified parameters are invalid.</ErrorMessage>
    <HttpStatusCode>200</HttpStatusCode>
    <Data>true</Data>
    <RequestId>6E07E90B-D9BC-5D6B-896A-82BA41A34AE1</RequestId>
</UpdateBaselineResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "Success" : true,
  "ErrorCode" : "401",
  "ErrorMessage" : "The specified parameters are invalid.",
  "HttpStatusCode" : 200,
  "Data" : true,
  "RequestId" : "6E07E90B-D9BC-5D6B-896A-82BA41A34AE1"
}

Error codes

For a list of error codes, see Service error codes.