unlink_clusters

Applicable Products

Product

Supported (√/x)

Ascend 950PR/Ascend 950DT

√

Atlas A3 training products/Atlas A3 inference products

√

Atlas A2 training products/Atlas A2 inference products

√

Atlas 200I/500 A2 inference products

x

Atlas inference products

x

Atlas training products

x

Note: For Atlas A2 training products/Atlas A2 inference products, only the Atlas 800I A2 inference server and A200I A2 Box heterogeneous subrack are supported.

Function Description

Disconnects a link unilaterally. The request can be initiated by the client to notify the server of disconnection. Alternatively, both the client and server can initiate forcible disconnection to clean up only local links.

Prototype

1
unlink_clusters(clusters: Union[List[LLMClusterInfo], Tuple[LLMClusterInfo]], timeout=3000, force=False)

Parameters

Parameter

Data Type

Value Description

clusters

Union[List[LLMClusterInfo], Tuple[LLMClusterInfo]]

Cluster list.

timeout

int

Timeout interval, in milliseconds. The default timeout interval is 3000 ms.

force

bool

Whether to forcibly disconnect the link. The default value is False. True indicates forcible disconnection.

  • For forcible link disconnection, only the local link is forcibly disconnected; therefore, this API must be called on both ends.
  • Non-forcible link disconnection is initiated by the client.
    • If no fault occurs, both ends of the link are disconnected.
    • If a fault occurs, a disconnection operation needs to be initiated by the server.

Example

Click GitCode, select the matching version, and obtain the sample from the examples/python directory.

Returns

In normal cases, a tuple of two values is returned. The first value is the return value of the API, and the type is LLMStatusCode. The second value is the list of link setup results of each cluster, and the type is LLMStatusCode.

If a parameter is incorrect, TypeError or ValueError may be reported.

Constraints

None