Rediģēt

Kopīgot, izmantojot


queryWorkItems@0 - Query work items v0 task

Use this task in an agentless job of a release pipeline to ensure the number of matching items returned by a work item query is within the configured thresholds.

Can only be used in an agentless job of a release pipeline.

Syntax

# Query work items v0
# Execute a work item query and check the number of items returned.
- task: queryWorkItems@0
  inputs:
    queryId: # string. Required. Query. 
    maxThreshold: '0' # string. Required. Upper threshold. Default: 0.
  # Advanced
    minThreshold: '0' # string. Required. Lower threshold. Default: 0.
# Query Work Items v0
# Executes a work item query and checks for the number of items returned.
- task: queryWorkItems@0
  inputs:
    queryId: # string. Required. Query. 
    maxThreshold: '0' # string. Required. Upper threshold. Default: 0.
  # Advanced
    minThreshold: '0' # string. Required. Lower threshold. Default: 0.

Inputs

queryId - Query
string. Required.

Specifies a saved work item query within the current project to execute. Can be a built-in or custom query.


maxThreshold - Upper threshold
string. Required. Default value: 0.

Specifies the maximum number of matching work items from the query.


minThreshold - Lower threshold
string. Required. Default value: 0.

Specifies the minimum number of matching work items from the query.


Task control options

All tasks have control options in addition to their task inputs. For more information, see Control options and common task properties.

Output variables

None.

Remarks

Use this task in an agentless job of a release pipeline to ensure the number of matching items returned by a work item query is within the configured thresholds.

Note

This task can only be used in an agentless job of a release pipeline.

This task succeeds if _minimum-threshold_ <= _#-matching-workitems_ <= _maximum-threshold_.

For more information about using this task, see the Approvals and gates overview.

Requirements

Requirement Description
Pipeline types YAML, Classic build, Classic release
Runs on Server, ServerGate
Demands None
Capabilities This task does not satisfy any demands for subsequent tasks in the job.
Command restrictions Any
Settable variables Any
Agent version All supported agent versions.
Task category Utility