server_metrics_configs
Creates, updates, deletes, gets or lists a server_metrics_configs resource.
Overview
| Name | server_metrics_configs |
| Type | Resource |
| Id | azure.developer_loadtesting.server_metrics_configs |
Fields
The following fields are returned by SELECT queries:
- get_server_metrics_config
| Name | Datatype | Description |
|---|---|---|
createdBy | string | The user that created. |
createdDateTime | string (date-time) | The creation datetime(RFC 3339 literal format). |
lastModifiedBy | string | The user that last modified. |
lastModifiedDateTime | string (date-time) | The last Modified datetime(RFC 3339 literal format). |
metrics | object | Azure resource metrics collection {metric id : metrics object} (Refer : https://learn.microsoft.com/en-us/rest/api/monitor/metric-definitions/list#metricdefinition _ for metric id). Required. |
testId | string | Test identifier. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_server_metrics_config | select | test_id, endpoint | List server metrics configuration for the given test. List server metrics configuration for the given test. | |
create_or_update_server_metrics_config | insert | test_id, endpoint, metrics | Configure server metrics for a test. Configure server metrics for a test. | |
create_or_update_server_metrics_config | replace | test_id, endpoint, metrics | Configure server metrics for a test. Configure server metrics for a test. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
endpoint | string | The service endpoint host (no scheme), e.g. myaccount.table.cosmos.azure.com:443 - value of the client endpoint parameter. (default: ) |
test_id | string | Unique name for the load test, must contain only lower-case alphabetic, numeric, underscore or hyphen characters. Required. |
SELECT examples
- get_server_metrics_config
List server metrics configuration for the given test. List server metrics configuration for the given test.
SELECT
createdBy,
createdDateTime,
lastModifiedBy,
lastModifiedDateTime,
metrics,
testId
FROM azure.developer_loadtesting.server_metrics_configs
WHERE test_id = '{{ test_id }}' -- required
AND endpoint = '{{ endpoint }}' -- required
;
INSERT examples
- create_or_update_server_metrics_config
- Manifest
Configure server metrics for a test. Configure server metrics for a test.
INSERT INTO azure.developer_loadtesting.server_metrics_configs (
metrics,
test_id,
endpoint
)
SELECT
'{{ metrics }}' /* required */,
'{{ test_id }}',
'{{ endpoint }}'
RETURNING
createdBy,
createdDateTime,
lastModifiedBy,
lastModifiedDateTime,
metrics,
testId
;
# Description fields are for documentation purposes
- name: server_metrics_configs
props:
- name: test_id
value: "{{ test_id }}"
description: Required parameter for the server_metrics_configs resource.
- name: endpoint
value: "{{ endpoint }}"
description: Required parameter for the server_metrics_configs resource.
- name: metrics
value: "{{ metrics }}"
description: |
Azure resource metrics collection {metric id : metrics object} (Refer : `https://learn.microsoft.com/en-us/rest/api/monitor/metric-definitions/list#metricdefinition `_ for metric id). Required.
REPLACE examples
- create_or_update_server_metrics_config
Configure server metrics for a test. Configure server metrics for a test.
REPLACE azure.developer_loadtesting.server_metrics_configs
SET
metrics = '{{ metrics }}'
WHERE
test_id = '{{ test_id }}' --required
AND endpoint = '{{ endpoint }}' --required
AND metrics = '{{ metrics }}' --required
RETURNING
createdBy,
createdDateTime,
lastModifiedBy,
lastModifiedDateTime,
metrics,
testId;