start_search
async
¶
start_search(
workspace_name: WorkspaceName,
query_statement: SearchQueryStatement,
*,
config_overrides: Optional[AsyncIoTSiteWiseClientConfig] = None,
client_token: Optional[ClientToken] = None,
search_type: Optional[SearchType] = None,
search_filters: Optional[SearchFilters] = None,
group_id: Optional[GroupId] = None,
) -> StartSearchResponse
Starts an asynchronous search over the data in a workspace. The search runs in the background; the response returns immediately with a searchId and an initial status of QUEUED. Use DescribeSearch to poll for completion and GetSearchResults to retrieve the results once the search reaches SUCCEEDED. The request is idempotent on clientToken: repeating a call with the same token returns the original search instead of starting a new one.
Parameters:
-
workspace_name(WorkspaceName) –The name of the workspace whose data is searched.
-
query_statement(SearchQueryStatement) –The natural-language query describing the data to search for.
-
client_token(Optional[ClientToken], default:None) –A unique, case-sensitive identifier you provide to ensure the request is idempotent. Repeating a StartSearch call with the same
clientTokenreturns the original search rather than starting a new one. If omitted, the SDK autogenerates one. -
search_type(Optional[SearchType], default:None) –The search strategy to use. Defaults to
QUICKwhen omitted. -
search_filters(Optional[SearchFilters], default:None) –Optional filters that restrict the search to a subset of the workspace's data.
-
group_id(Optional[GroupId], default:None) –An optional caller-supplied identifier used to group related searches together.
Raises:
-
AccessDeniedException–Access is denied.
-
ConflictingOperationException–Your request has conflicting operations. This can occur if you're trying to perform more than one operation on the same resource at the same time.
-
InternalFailureException–IoT SiteWise can't process your request right now. Try again later.
-
InvalidRequestException–The request isn't valid. This can occur if your request contains malformed JSON or unsupported characters. Check your request and try again.
-
LimitExceededException–You've reached the quota for a resource. For example, this can occur if you're trying to associate more than the allowed number of child assets or attempting to create more than the allowed number of properties for an asset model.
For more information, see Quotas in the IoT SiteWise User Guide.
-
ResourceNotFoundException–The requested resource can't be found.
-
ThrottlingException–Your request exceeded a rate limit. For example, you might have exceeded the number of IoT SiteWise assets that can be created per second, the allowed number of messages per second, and so on.
For more information, see Quotas in the IoT SiteWise User Guide.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_iotsitewise/_services/async_io_t_site_wise.py
10513 10514 10515 10516 10517 10518 10519 10520 10521 10522 10523 10524 10525 10526 10527 10528 10529 10530 10531 10532 10533 10534 10535 10536 10537 10538 10539 10540 10541 10542 10543 10544 10545 10546 10547 10548 10549 10550 10551 10552 10553 10554 10555 10556 10557 10558 10559 10560 10561 10562 10563 10564 10565 10566 10567 10568 10569 10570 10571 10572 10573 10574 10575 10576 10577 10578 10579 10580 10581 10582 10583 10584 10585 10586 10587 10588 10589 10590 10591 10592 10593 10594 10595 | |