您在“创建管道”中学习了如何创建管道。您将在管道画布上执行许多操作,但是从管道编辑器的主工具栏中还可以获得许多额外的功能。
还有另外两个重要的工具栏用于处理单元测试以及项目和环境。查看相关页面,了解有关管理项目和环境的更多信息,并了解如何为管道编写单元测试。
让我们看看最上面的工具栏:
Action | Icon | Description |
---|---|---|
run | Start the execution of the pipeline; 开始执行管道; |
|
pause | [外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-BecZyUI8-1670217736507)(C:\Users\lenovo\AppData\Roaming\Typora\typora-user-images\image-20221127081024252.png)] | pause the execution of the pipeline; 暂停管道的执行; |
stop | stop the execution of the pipeline; 停止管道的执行; |
|
preview | preview the pipeline; 预览管道 |
|
debug | debug the pipeline; 调试管道 |
|
print the pipeline; 打印管道 |
||
undo | undo an operation; 撤销操作 |
|
redo | redo an operation; 重复操作 |
|
align | align the specified (selected) transforms to the specified grid size; 将指定的(选定)变换与指定的网格大小对齐 |
|
align left | align the selected transforms with left-most selected transform in the selection; 将选择的转换与选择的最左边的转换对齐 |
|
align right | align the selected transforms with right-most selected transform in the selection; 将选择的转换与选择的最右边的转换对齐 |
|
align top | align the selected transforms with top-most selected transform in the selection; 将选择的转换与选择的最上面的转换对齐 |
|
align bottom | align the selected transforms with bottom-most selected transform in the selection; 将选择的转换与选择的最底部的转换对齐 |
|
distribute horizontally | Distribute the selected transforms evenly between the left-most and right-most transform in your selection; 将选择的转换均匀分布在选择的最左和最右转换之间 |
|
distribute vertically | Distribute the selected transforms evenly between the top-most and bottom-most transform in your selection; 将选择的转换均匀分布在选择的最顶部和最底部的转换之间 |
|
管道是Hop项目的基本构建块。
管道完成了繁重的工作:它们从各种来源读取数据,执行许多操作(合并、清理、完善、转换等),并将数据写入某些目标平台。管道以预定义的顺序并并行地执行所有这些操作。
在下面的图片中,一个非常简单的管道从数据库读取数据,向数据添加一条消息,然后发送一封电子邮件。所有这些操作都按照预定义的顺序执行(从数据库读取、添加消息、发送邮件)并并行执行。管道执行这些转换,假设我们的数据库表或查询包含数千行。管道将开始从查询中读取结果,并将它们传递给’Add message’转换。一旦添加了消息,我们将从mail转换发送一封邮件。所有这些都是并行的,所以邮件转换.
管道由跳连接的转换组成。在邮件示例“Table input”中,“Add message”和“mail”都是转换。
通过工作项对话框创建一个新的管道。您将看到下面的对话框。
当您完成管道创建后,保存它。这可以通过“文件”菜单、图标或使用CTLR或Command s来完成。对于新的管道,文件浏览器将显示,以导航到您想要存储文件的位置。
单击管道画布中的任意位置,即您将看到下图的区域。
单击后,将显示如下所示的对话框。通过顶部的搜索框搜索转换、名称、标签(TODO)等。找到要查找的转换后,单击它将其添加到管道中。点击的另一种选择是方向键导航+回车。现在重复此步骤,或者在您想向管道添加更多转换时重复此步骤。向管道添加转换后,可以拖动它来重新定位它。
查看要添加到管道中的转换列表以获得更多详细信息。
添加“Generate Rows”和“Add Sequence”转换,你的管道应该如下图所示。
可以通过对对象的一次单击来配置转换对象。下面显示的菜单将基于您的转换对象显示。
Action | Description |
---|---|
Edit 编辑转换 |
Edit the transform’s metadata 编辑转换的元数据 |
Copy to clipboard 复制 |
Copies selected items to clipboard. 复制选中的转换 |
Create hop 创建跳 |
Creates a new hop between two transforms. 在两个转换之间创建一个新的跳转 |
Detach transform 分离转换 |
Detach the transform from the pipeline 从管道中分离转换 |
Show input fields | 显示输入字段 |
Show output fields | 显示输出字段 |
Edit transform description 编辑转换描述 |
Add a description to the transform. 向转换添加描述。 |
Delete 删除 |
Delete selected transform from the canvas. 从画布中删除选中的转换 |
Data routing | |
Specify copies 指定复制 |
复制指定行数 |
Copy rows 复制行 |
In case of more than one hop the daya is copied to the next transforms. 如果有多个跳,则将daya复制到下一个转换 |
Set partitioning 设置分区 |
Specify how rows of data need to be grouped into partitions allowing parallel execution where similar rows need to end up on the same transform copy 指定需要如何将数据行分组到允许并行执行的分区中,其中相似的行需要在相同的转换副本上结束 |
Error handling 错误处理 |
Set the error handling for the transform, not available for all transforms. 为转换设置错误处理,但不是所有转换都可用 |
Add web service 添加web服务 |
|
Preview | |