fetchIssues method
List issues of conversion workspace operations e.g. conversion.
Request parameters:
conversionWorkspace - Required. Conversion workspace with issues to
fetch. Must be in the form of:
projects/{project}/locations/{location}/conversionWorkspaces/{conversion_workspace}.
Value must have pattern
^projects/\[^/\]+/locations/\[^/\]+/conversionWorkspaces/\[^/\]+$.
allIssues - Optional. If 'true', gets all issues matching the filter.
Otherwise, for each entity only the issues matching the DdlKind chosen for
application on the destination are returned.
filter - Optional. AIP-160 standard filter. Supporting both entity and
issue fields. Supported fields: - name / fullname: The entity full
name. - type: The entity type (e.g. TABLE, VIEW, INDEX,
TRIGGER). - ddlkind: The kind of DDL (e.g. DDL_KIND_SOURCE,
DDL_KIND_AI, DDL_KIND_DETERMINISTIC). - issue.severity: The severity
of the issue (e.g. INFO, WARNING, ERROR). - issue.state: The state
of the issue (e.g. OPEN, RESOLVED). - issue.origin: The origin of
the issue (e.g. DETERMINISTIC, AI). - issue.category_id: The
category ID of the issue. - issue.group_id: The group ID of the issue.
pageSize - Optional. The maximum number of issues to return. The service
may return fewer issues than the value specifies.
pageToken - Optional. The FetchIssuesResponse.next_page_token value
received in the previous call to FetchIssues, used in the subsequent
request to retrieve the next page of results. On first call this should be
left blank. When paginating, all other parameters provided to FetchIssues
must match the call that provided the page token, except for the page_size
parameter.
tree - Optional. The tree to fetch issues from. If not specified, source
tree is assumed.
Possible string values are:
- "DB_TREE_TYPE_UNSPECIFIED" : Unspecified tree type.
- "SOURCE" : Returns seed and conversion issues
- "DRAFT" : Returns apply issues.
$fields - Selector specifying which fields to include in a partial
response.
Completes with a FetchIssuesResponse.
Completes with a commons.ApiRequestError if the API endpoint returned an error.
If the used http.Client completes with an error when making a REST call,
this method will complete with the same error.
Implementation
async.Future<FetchIssuesResponse> fetchIssues(
core.String conversionWorkspace, {
core.bool? allIssues,
core.String? filter,
core.int? pageSize,
core.String? pageToken,
core.String? tree,
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
'allIssues': ?allIssues == null ? null : ['${allIssues}'],
'filter': ?filter == null ? null : [filter],
'pageSize': ?pageSize == null ? null : ['${pageSize}'],
'pageToken': ?pageToken == null ? null : [pageToken],
'tree': ?tree == null ? null : [tree],
'fields': ?$fields == null ? null : [$fields],
};
final url_ =
'v1/' + core.Uri.encodeFull('$conversionWorkspace') + ':fetchIssues';
final response_ = await _requester.request(
url_,
'GET',
queryParams: queryParams_,
);
return FetchIssuesResponse.fromJson(
response_ as core.Map<core.String, core.dynamic>,
);
}