or run

npx @tessl/cli init
Log in

Version

Tile

Overview

Evals

Files

Files

docs

client-management.mdcluster-operations.mdindex.mdmodels-types.mdsystem-operations.md

system-operations.mddocs/

0

# System Operations

1

2

System-level operations for managing available API operations and system services within clusters. These operations provide discovery and management capabilities for the Azure Machine Learning Compute service.

3

4

## Capabilities

5

6

### API Operations Discovery

7

8

Operations for discovering available API operations and their metadata, useful for building dynamic clients or documentation.

9

10

```python { .api }

11

class MachineLearningComputeOperations:

12

"""Operations for general Machine Learning Compute management."""

13

14

def list_available_operations(

15

self,

16

custom_headers: Dict[str, str] = None,

17

raw: bool = False

18

) -> AvailableOperations:

19

"""

20

Gets all available operations for the Microsoft.MachineLearningCompute resource provider.

21

22

Args:

23

custom_headers (dict, optional): Headers to add to the request

24

raw (bool): Returns direct response alongside deserialized response

25

26

Returns:

27

AvailableOperations: Container with list of available API operations

28

29

Raises:

30

CloudError: Service error occurred

31

"""

32

```

33

34

**Usage Example:**

35

36

```python

37

# Get all available operations

38

operations = client.machine_learning_compute.list_available_operations()

39

40

# Iterate through available operations

41

for operation in operations.value:

42

print(f"Operation: {operation.name}")

43

print(f"Display Name: {operation.display.operation}")

44

print(f"Provider: {operation.display.provider}")

45

print(f"Resource: {operation.display.resource}")

46

print(f"Description: {operation.display.description}")

47

print("---")

48

49

# Filter operations by type

50

cluster_operations = [

51

op for op in operations.value

52

if "operationalizationClusters" in op.name

53

]

54

55

print(f"Found {len(cluster_operations)} cluster operations")

56

```

57

58

## Operation Response Models

59

60

### AvailableOperations

61

62

Container for the list of available API operations.

63

64

```python { .api }

65

class AvailableOperations:

66

"""

67

Container for available operations.

68

69

Attributes:

70

value (List[ResourceOperation]): List of available operations

71

"""

72

value: List[ResourceOperation]

73

```

74

75

### ResourceOperation

76

77

Individual API operation definition with metadata.

78

79

```python { .api }

80

class ResourceOperation:

81

"""

82

API operation definition.

83

84

Attributes:

85

name (str): Operation name (e.g., "Microsoft.MachineLearningCompute/operationalizationClusters/read")

86

display (ResourceOperationDisplay): Display information for the operation

87

origin (str): The operation origin

88

"""

89

name: str

90

display: ResourceOperationDisplay

91

origin: str

92

```

93

94

### ResourceOperationDisplay

95

96

Display information for API operations, used in Azure portal and documentation.

97

98

```python { .api }

99

class ResourceOperationDisplay:

100

"""

101

Display information for a resource operation.

102

103

Attributes:

104

provider (str): Service provider (e.g., "Microsoft Machine Learning Compute")

105

resource (str): Resource type (e.g., "Operationalization Cluster")

106

operation (str): Operation description (e.g., "Create or Update Operationalization Cluster")

107

description (str): Detailed operation description

108

"""

109

provider: str

110

resource: str

111

operation: str

112

description: str

113

```

114

115

**Usage Example:**

116

117

```python

118

# Explore operation metadata

119

operations = client.machine_learning_compute.list_available_operations()

120

121

for op in operations.value:

122

if "create" in op.display.operation.lower():

123

print(f"Create Operation: {op.name}")

124

print(f" Resource: {op.display.resource}")

125

print(f" Description: {op.display.description}")

126

```

127

128

## Integration with Azure Resource Manager

129

130

The system operations integrate with Azure's Resource Manager infrastructure:

131

132

```python

133

# This operation provides the same information available through:

134

# az provider operation list --namespace Microsoft.MachineLearningCompute

135

136

operations = client.machine_learning_compute.list_available_operations()

137

138

# Can be used to build custom tooling, documentation, or validation

139

operation_names = [op.name for op in operations.value]

140

print(f"Total operations: {len(operation_names)}")

141

142

# Check if specific operations are available

143

cluster_create_available = any(

144

"operationalizationClusters/write" in op.name

145

for op in operations.value

146

)

147

print(f"Cluster creation available: {cluster_create_available}")

148

```

149

150

## Error Handling

151

152

System operations use standard Azure error handling patterns:

153

154

```python

155

from azure.core.exceptions import ClientAuthenticationError, HttpResponseError

156

157

try:

158

operations = client.machine_learning_compute.list_available_operations()

159

except ClientAuthenticationError:

160

print("Authentication failed - check credentials")

161

except HttpResponseError as e:

162

print(f"HTTP error: {e.status_code} - {e.message}")

163

except Exception as e:

164

print(f"Unexpected error: {e}")

165

```