队列是一个容器,可用于存储不限数量的项目。队列项目可存储多种类型的数据,例如发票信息或客户详细信息。可以在其他系统(例如 SAP 或 Salesforce)中处理此信息。
The data stored in, and output from, Queue items is free form by default. For situations where a specific schema is needed, such as integrations with other applications, processing of machine generated forms, or for analytics, you can upload custom JSON schemas to ensure that all Queue item data is in the proper format.
In Orchestrator, newly created queues are empty by default. To populate them with items you can either use the upload functionality in Orchestrator, or Studio activities. The latter also enable you to change item statuses and process them. As soon as queue items are processed, they become transactions.
队列概述
队列使您可以创建大型自动化项目,其中复杂逻辑非常重要。例如,您可以创建一个流程,用以收集所有发票信息并为每段数据创建一个队列项目来存储它。随后,您可以创建另一个流程,该流程从 Orchestrator 收集信息并将其用于执行其他任务,例如在不同的应用程序中支付发票,根据到期日期或价值推迟付款,每次支付账单时向会计团队发送电子邮件等。
使用“队列”页面可以创建新的队列。此页面还为您提供了对以下内容的访问权限:先前创建的队列、事务状态随时间变化的图表以及各种其他详细信息,例如平均执行时间和成功事务的总数。

Item statuses are controlled by RPA developers when they create the automation projects, while revision statuses are controlled in Orchestrator and enable you to perform version control, but only of queue items that have been abandoned or have failed with an application or business exception.
Failed or abandoned items can also be assigned to a reviewer, which can be changed or cleared at any point, if needed. Each of these changes are tracked in the History tab of the Audit Details window. The reviewer is in charge of assessing the current status of the transactions he is assigned to, and changing the review status. The status of queue items up for revision can be changed in the Review Requests page.
架构定义
在创建或编辑队列时,您可以上传“特定数据”、“输出数据”和/或“分析数据”的 JSON
架构。使用该架构后,将根据提供的格式验证所有事务,如果结果数据不符合要求,则该项目将由于业务异常而失败。
重要
架构不会追溯应用到现有事务,仅追溯到上传架构后执行的事务。
您的架构不得包含数组。
出于验证目的,
DateTime
被接受为string
类型。要使用和验证分析数据架构,需要 19.10 或更高版本的机器人和活动。
如果上传的架构不包含有效的架构定义
URI
,则使用draft-07
定义(如以下示例所示)作为后备。
注意
为了更好地控制 Orchestrator 的性能,借助
Queue.MaxSpecificDataSizeInKiloBytes
应用程序设置,队列项的特定数据大小被限制为 1 MB。任何超出此限制的内容都无法添加到队列中,并且会返回错误代码 403 - Payload Too Large。如果您需要上传较大的项目,请将较大的数据存储在外部存储中,并且仅引用项目中的链接。
架构示例:
{
"definitions": {},
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "http://example.com/root.json",
"type": "object",
"title": "The Root Schema",
"additionalProperties": { "type": "string" },
"required": [
"stringTest",
"intTest",
"boolTest"
],
"properties": {
"stringTest": {
"$id": "#/properties/stringTest",
"type": "string",
"title": "The Stringtest Schema",
"default": "",
"examples": [
"stringTest"
],
"pattern": "^(.*)$"
},
"intTest": {
"$id": "#/properties/intTest",
"type": "integer",
"title": "The Inttest Schema",
"default": 0,
"examples": [
30
]
},
"boolTest": {
"$id": "#/properties/boolTest",
"type": "boolean",
"title": "The Booltest Schema",
"default": false,
"examples": [
false
]
}
}
}
事务概述
“事务”页面显示给定队列中的事务。此页面还显示这些事务的状态、应处理日期、负责处理的机器人,以及引发的异常类型或分配的引用(如果如有)。
您可以根据通过“添加队列项目”活动和“添加事务项目”活动的“引用”属性添加的自定义引用搜索特定事务或一组事务。该引用可用于将您的事务链接到自动化项目中使用的其他应用程序。此外,此功能使您可以根据提供的自定义引用在 Orchestrator 中搜索特定事务。
还可以强制事务引用在队列级别是唯一的。创建队列时会启用此功能,并应用于所有事务(已删除或重试的事务除外)。这使识别特定项目变得轻而易举,并简化了审核过程。
如果在将项目添加到队列时遇到重复引用,则作业将失败,并显示为“发生故障”状态,并在“作业详细信息”窗口中显示“Execution error: UiPath.Core.Activities.OrchestratorHttpException: Error creating Transaction. Duplicate Reference.
”错误消息。
队列项目中存储的信息显示在 Orchestrator 中“事务详细信息”窗口的“特定数据”下。此外,如果该项目失败并已重试,项目的历史记录将显示在同一窗口中。

“事务详细信息”窗口包含三个选项卡:
- Details - enables you to view the exact information added to a transaction, as well as the statuses it went through, and the number of times it was retried.
- Comments - enables you to view and add transaction-related comments in case you need to share information about a specific transaction with your teammates. All the users with View, Edit, and Delete permissions on Queues and Transactions can add, edit, or remove comments, respectively, however, keep in mind you can make changes to your own comments only.
- History - enables you to see what action was performed by who, see who the reviewer is and what the review status is. For more information, see the Managing Transactions and Field Descriptions for Transactions pages.
处理顺序
在任何给定队列中,将按层次结构处理事务,依据的顺序如下:
- 具有截止日期的项目,如下所示:
a. 按优先级顺序;并且
b. 对于优先级相同的项目,根据所设置的截止日期。 - 没有截止日期的项目按优先级排序,并且
a. 对于优先级相同的项目,根据根据先进先出规则。
When setting a Deadline or a Postpone date, we recommend populating the respective fields with relative dates. For example, DateTime.Now.AddHours(2)
, DateTime.Now.AddDays(10)
and DateTime.Now.Add(New System.TimeSpan(5, 0, 0, 0))
. Additionally, you can use the US notation to add an exact time, such as 10/10/2019 07:40:00
. Automatic correction of this date is available, for example, if you write 12 10 2019 9:0
, it is automatically transformed to 12/10/2019 09:00:00
.
在 Studio 的“截止日期”和“延期”字段中添加的时间会显示在 Orchestrator 的“事务”页面中的“截止日期”和“延期”列下。
导出事务
您可以单击“事务”页面中的“导出”按钮,将与给定队列相关的所有事务和信息导出到 .csv 文件。所有页面筛选选项也会应用于生成的文件。

请注意,为了确保最佳性能,导出的条目不按时间倒序排列。
队列 SLA 预测
此工具可帮助您为队列中新添加的项目设置 SLA(项目截止日期)。这可以帮助您评估是否可以及时处理它们,以及需要分配哪些资源以确保不违反其 SLA。每当有可能无法实现 SLA 时,系统都会适当通知您,以便您做出相应调整。
了解如何配置队列 SLA。
了解如何进行预测以及预测的确切含义。
SLA 仅适用于未设置截止时间的项目,这意味着没有预先定义截止时间的新添加的项目将根据设置为 SLA 的值自动填充。具体来说,每个项目的截止时间从队列项目添加到队列中的时间算起,由为队列 SLA 设置的值表示。例如,如果我将 SLA 设置为 2 小时,并且在下午 4、5 和 6 点将 3 个项目添加到队列中,那么我的项目的截止时间分别为下午 6、7、8 点。
具有截止时间(在 Studio 或用于上传的 .csv 文件中设置)的项目不会受到 SLA 设置的影响。
重要
启用 SLA 预测后,添加到队列中的项目的优先级会自动设置为“高”,无论在 Studio 或用于上传的 .csv 文件中是如何设置的。
您无法删除与启用了 SLA 预测的队列关联的流程。
如果至少一个队列项目超过了其截止日期,则“必要机器人 (SLA)”列中将显示“超出容量”,并且不再计算预测。
对截止日期在未来 24 小时内的队列项目进行预测(可以使用
Queue.SlaReadaheadTimeLimitHours
进行更改),并且不考虑项目的延期日期。
就队列-流程关联而言,队列触发器和 SLA 预测是相互依赖的。因此,每当配置其中一者时,另一者都会预填充,以使配置之间保持对等。假设我为队列 Y 定义了一个队列触发器以使用流程 X,队列 Y 的 SLA 预测只能使用流程 X 进行,那么,为 Y 启用队列 SLA 时,X 会预填充,并且为只读状态。
风险 SLA
您还可以为项目定义一个风险 SLA,其作用类似于 SLA 之前的缓冲区。明确地说,项目的风险截止时间是根据风险 SLA 计算得出的,从将队列项目添加到队列之时算起。假设我将风险 SLA 设置为 2 小时,并且在下午 4:30、5:15 和 6:45 将 3 个项目添加到队列中,那么我的项目的风险截止时间分别为下午 6:30、7:15、8:45。
如果已超过风险 SLA 且队列项目未得到处理,该项目就有可能无法满足其截止时间。系统会适当通知用户,以便用户做出相应调整。
队列 SLA 权限
要为队列配置 SLA 预测,您需要具有以下权限:
- View on Processes
- View on Queues
- 队列的“编辑”权限(在编辑队列时配置 SLA)
- 队列的“创建”权限(在创建队列时配置 SLA)
使用 CSV 文件批量上传项目
Learn more about bulk uploading queue items using a CSV file.
6个月前更新