update_fleet_metric
¶
update_fleet_metric(
metric_name: FleetMetricName,
index_name: IndexName,
*,
config_overrides: Optional[IoTClientConfig] = None,
query_string: Optional[QueryString] = None,
aggregation_type: Optional[AggregationType] = None,
period: Optional[FleetMetricPeriod] = None,
aggregation_field: Optional[AggregationField] = None,
description: Optional[FleetMetricDescription] = None,
query_version: Optional[QueryVersion] = None,
unit: Optional[FleetMetricUnit] = None,
expected_version: Optional[OptionalVersion] = None,
) -> None
Updates the data for a fleet metric.
Requires permission to access the UpdateFleetMetric action.
Parameters:
-
metric_name(FleetMetricName) –The name of the fleet metric to update.
-
query_string(Optional[QueryString], default:None) –The search query string.
-
aggregation_type(Optional[AggregationType], default:None) –The type of the aggregation query.
-
period(Optional[FleetMetricPeriod], default:None) –The time in seconds between fleet metric emissions. Range [60(1 min), 86400(1 day)] and must be multiple of 60.
-
aggregation_field(Optional[AggregationField], default:None) –The field to aggregate.
-
description(Optional[FleetMetricDescription], default:None) –The description of the fleet metric.
-
query_version(Optional[QueryVersion], default:None) –The version of the query.
-
index_name(IndexName) –The name of the index to search.
-
unit(Optional[FleetMetricUnit], default:None) –Used to support unit transformation such as milliseconds to seconds. The unit must be supported by CW metric.
-
expected_version(Optional[OptionalVersion], default:None) –The expected version of the fleet metric record in the registry.
Raises:
-
IndexNotReadyException–The index is not ready.
-
InternalFailureException–An unexpected error has occurred.
-
InvalidAggregationException–The aggregation is invalid.
-
InvalidQueryException–The query is invalid.
-
InvalidRequestException–The request is not valid.
-
ResourceNotFoundException–The specified resource does not exist.
-
ServiceUnavailableException–The service is temporarily unavailable.
-
ThrottlingException–The rate exceeds the limit.
-
UnauthorizedException–You are not authorized to perform this operation.
-
VersionConflictException–An exception thrown when the version of an entity specified with the
expectedVersionparameter does not match the latest version in the system. -
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_iot/_services/io_t.py
17638 17639 17640 17641 17642 17643 17644 17645 17646 17647 17648 17649 17650 17651 17652 17653 17654 17655 17656 17657 17658 17659 17660 17661 17662 17663 17664 17665 17666 17667 17668 17669 17670 17671 17672 17673 17674 17675 17676 17677 17678 17679 17680 17681 17682 17683 17684 17685 17686 17687 17688 17689 17690 17691 17692 17693 17694 17695 17696 17697 17698 17699 17700 17701 17702 17703 17704 17705 17706 17707 17708 17709 17710 17711 17712 17713 17714 17715 17716 17717 17718 17719 17720 17721 17722 17723 17724 17725 17726 17727 17728 17729 17730 17731 | |