zhongjiajie commented on code in PR #10184:
URL: https://github.com/apache/dolphinscheduler/pull/10184#discussion_r914506956


##########
docs/docs/zh/guide/parameter/context.md:
##########
@@ -76,3 +77,22 @@ Node_mysql 运行结果如下:
 虽然在 Node_A 的脚本中为 output 赋值为 1,但日志中显示的值仍然为 100。但根据[参数优先级](priority.md)的原则:`本地参数 
> 上游任务传递的参数 > 全局参数`,在 Node_B 中输出的值为 1。则证明 output 参数参照预期的值在该工作流中传递,并在 Node_mysql 
中使用该值完成查询操作。
 
 但是 value 的值却只有在 Node_A 中输出为 66,其原因为 value 的方向选择为 IN,只有当方向为 OUT 时才会被定义为变量输出。
+
+
+### HTTP
+
+第一步:拖一个http类型的任务,在自定义参数中KEY的位置填写body 
,在IN/OUT的部分选择OUT,在输出数据类型部分选择VARCHAR,一定要选择VARCHAR,不要选择别的哈。
+
+<img src="../../../../img/httpParam/httpParam-1.png" alt="httpParam-1.png" 
style="zoom:50%;" />
+
+第二步:在添加一个http任务类型的节点,接收上游传递来的参数。这一次只需要在【请求参数】部分进行添加就可以了,
+
+<img src="../../../../img/httpParam/httpParam-2.png" alt="httpParam-2.png" 
style="zoom:50%;" />
+
+参数名可以写任意,可以body也可以是别的,类型选择parameter,value的取值一定是你上一个节点设置输出的key,如:我上一个节点设置的输出key是body,那我下一个节点就要这样取值${body}
+
+配置好后的效果
+<img src="../../../../img/httpParam/httpParam-3.png" alt="httpParam-3.png" 
style="zoom:50%;" />
+
+第三步:你可以写一个测试接口,来测试咱们的参数是否传递成功。
+<img src="../../../../img/httpParam/httpParam-4.png" alt="httpParam-4.png" 
style="zoom:50%;" />

Review Comment:
   ```suggestion
   ![httpParam-4](../../../../img/httpParam/httpParam-4.png)
   ```



##########
docs/docs/zh/guide/parameter/context.md:
##########
@@ -76,3 +77,22 @@ Node_mysql 运行结果如下:
 虽然在 Node_A 的脚本中为 output 赋值为 1,但日志中显示的值仍然为 100。但根据[参数优先级](priority.md)的原则:`本地参数 
> 上游任务传递的参数 > 全局参数`,在 Node_B 中输出的值为 1。则证明 output 参数参照预期的值在该工作流中传递,并在 Node_mysql 
中使用该值完成查询操作。
 
 但是 value 的值却只有在 Node_A 中输出为 66,其原因为 value 的方向选择为 IN,只有当方向为 OUT 时才会被定义为变量输出。
+
+
+### HTTP
+
+第一步:拖一个http类型的任务,在自定义参数中KEY的位置填写body 
,在IN/OUT的部分选择OUT,在输出数据类型部分选择VARCHAR,一定要选择VARCHAR,不要选择别的哈。
+
+<img src="../../../../img/httpParam/httpParam-1.png" alt="httpParam-1.png" 
style="zoom:50%;" />
+
+第二步:在添加一个http任务类型的节点,接收上游传递来的参数。这一次只需要在【请求参数】部分进行添加就可以了,
+
+<img src="../../../../img/httpParam/httpParam-2.png" alt="httpParam-2.png" 
style="zoom:50%;" />

Review Comment:
   ```suggestion
   ![httpParam-2](../../../../img/httpParam/httpParam-2.png)
   ```



##########
docs/docs/zh/guide/parameter/context.md:
##########
@@ -76,3 +77,22 @@ Node_mysql 运行结果如下:
 虽然在 Node_A 的脚本中为 output 赋值为 1,但日志中显示的值仍然为 100。但根据[参数优先级](priority.md)的原则:`本地参数 
> 上游任务传递的参数 > 全局参数`,在 Node_B 中输出的值为 1。则证明 output 参数参照预期的值在该工作流中传递,并在 Node_mysql 
中使用该值完成查询操作。
 
 但是 value 的值却只有在 Node_A 中输出为 66,其原因为 value 的方向选择为 IN,只有当方向为 OUT 时才会被定义为变量输出。
+
+
+### HTTP
+
+第一步:拖一个http类型的任务,在自定义参数中KEY的位置填写body 
,在IN/OUT的部分选择OUT,在输出数据类型部分选择VARCHAR,一定要选择VARCHAR,不要选择别的哈。
+
+<img src="../../../../img/httpParam/httpParam-1.png" alt="httpParam-1.png" 
style="zoom:50%;" />
+
+第二步:在添加一个http任务类型的节点,接收上游传递来的参数。这一次只需要在【请求参数】部分进行添加就可以了,
+
+<img src="../../../../img/httpParam/httpParam-2.png" alt="httpParam-2.png" 
style="zoom:50%;" />
+
+参数名可以写任意,可以body也可以是别的,类型选择parameter,value的取值一定是你上一个节点设置输出的key,如:我上一个节点设置的输出key是body,那我下一个节点就要这样取值${body}
+
+配置好后的效果
+<img src="../../../../img/httpParam/httpParam-3.png" alt="httpParam-3.png" 
style="zoom:50%;" />

Review Comment:
   ```suggestion
   ![httpParam-3](../../../../img/httpParam/httpParam-3.png)
   ```



##########
docs/docs/en/guide/parameter/context.md:
##########
@@ -76,3 +76,21 @@ The result of Node_mysql is as follows:
 Even though output is assigned a value of 1 in Node_A's script, the log still 
shows a value of 100. But according to the principle from [parameter 
priority](priority.md): `Local Parameter > Parameter Context > Global 
Parameter`, the output value in Node_B is 1. It proves that the output 
parameter is passed in the workflow with reference to the expected value, and 
the query operation is completed using this value in Node_mysql.
 
 But the output value 66 only shows in the Node_A, the reason is that the 
direction of value is selected as IN, and only when the direction is OUT will 
it be defined as a variable output.
+
+### HTTP
+
+Step 1: Drag an HTTP task, fill IN body for KEY, select OUT for IN/OUT, select 
VARCHAR for output data type, always select VARCHAR, nothing else.
+
+<img src="../../../../img/httpParam/httpParam-1.png" alt="httpParam-1.png" 
style="zoom:50%;" />
+
+Step 2: After adding an HTTP task type node, accept the parameters passed 
upstream. This time just add it in the Request Parameters section,
+
+<img src="../../../../img/httpParam/httpParam-2.png" alt="httpParam-2.png" 
style="zoom:50%;" />
+
+It can be anything, it can be body, it can be anything, parameter,value, it 
must be the key that you pass upstream. In this case, the key that you pass 
upstream is body, so we use ${body}
+
+The configuration is complete
+<img src="../../../../img/httpParam/httpParam-3.png" alt="httpParam-3.png" 
style="zoom:50%;" />

Review Comment:
   ```suggestion
   ![httpParam-3](../../../../img/httpParam/httpParam-3.png)
   ```



##########
docs/docs/en/guide/parameter/context.md:
##########
@@ -76,3 +76,21 @@ The result of Node_mysql is as follows:
 Even though output is assigned a value of 1 in Node_A's script, the log still 
shows a value of 100. But according to the principle from [parameter 
priority](priority.md): `Local Parameter > Parameter Context > Global 
Parameter`, the output value in Node_B is 1. It proves that the output 
parameter is passed in the workflow with reference to the expected value, and 
the query operation is completed using this value in Node_mysql.
 
 But the output value 66 only shows in the Node_A, the reason is that the 
direction of value is selected as IN, and only when the direction is OUT will 
it be defined as a variable output.
+
+### HTTP
+
+Step 1: Drag an HTTP task, fill IN body for KEY, select OUT for IN/OUT, select 
VARCHAR for output data type, always select VARCHAR, nothing else.
+
+<img src="../../../../img/httpParam/httpParam-1.png" alt="httpParam-1.png" 
style="zoom:50%;" />

Review Comment:
   ```suggestion
   ![httpParam-1](../../../../img/httpParam/httpParam-1.png)
   ```



##########
docs/docs/en/guide/parameter/context.md:
##########
@@ -76,3 +76,21 @@ The result of Node_mysql is as follows:
 Even though output is assigned a value of 1 in Node_A's script, the log still 
shows a value of 100. But according to the principle from [parameter 
priority](priority.md): `Local Parameter > Parameter Context > Global 
Parameter`, the output value in Node_B is 1. It proves that the output 
parameter is passed in the workflow with reference to the expected value, and 
the query operation is completed using this value in Node_mysql.
 
 But the output value 66 only shows in the Node_A, the reason is that the 
direction of value is selected as IN, and only when the direction is OUT will 
it be defined as a variable output.
+
+### HTTP
+
+Step 1: Drag an HTTP task, fill IN body for KEY, select OUT for IN/OUT, select 
VARCHAR for output data type, always select VARCHAR, nothing else.
+
+<img src="../../../../img/httpParam/httpParam-1.png" alt="httpParam-1.png" 
style="zoom:50%;" />
+
+Step 2: After adding an HTTP task type node, accept the parameters passed 
upstream. This time just add it in the Request Parameters section,
+
+<img src="../../../../img/httpParam/httpParam-2.png" alt="httpParam-2.png" 
style="zoom:50%;" />
+
+It can be anything, it can be body, it can be anything, parameter,value, it 
must be the key that you pass upstream. In this case, the key that you pass 
upstream is body, so we use ${body}
+
+The configuration is complete
+<img src="../../../../img/httpParam/httpParam-3.png" alt="httpParam-3.png" 
style="zoom:50%;" />
+
+Step 3: You can write a test interface to test whether our parameters are 
passed successfully.
+<img src="../../../../img/httpParam/httpParam-4.png" alt="httpParam-4.png" 
style="zoom:50%;" />

Review Comment:
   ```suggestion
   ![httpParam-4](../../../../img/httpParam/httpParam-4.png)
   ```



##########
docs/docs/zh/guide/parameter/context.md:
##########
@@ -76,3 +77,22 @@ Node_mysql 运行结果如下:
 虽然在 Node_A 的脚本中为 output 赋值为 1,但日志中显示的值仍然为 100。但根据[参数优先级](priority.md)的原则:`本地参数 
> 上游任务传递的参数 > 全局参数`,在 Node_B 中输出的值为 1。则证明 output 参数参照预期的值在该工作流中传递,并在 Node_mysql 
中使用该值完成查询操作。
 
 但是 value 的值却只有在 Node_A 中输出为 66,其原因为 value 的方向选择为 IN,只有当方向为 OUT 时才会被定义为变量输出。
+
+
+### HTTP
+
+第一步:拖一个http类型的任务,在自定义参数中KEY的位置填写body 
,在IN/OUT的部分选择OUT,在输出数据类型部分选择VARCHAR,一定要选择VARCHAR,不要选择别的哈。
+
+<img src="../../../../img/httpParam/httpParam-1.png" alt="httpParam-1.png" 
style="zoom:50%;" />

Review Comment:
   ```suggestion
   ![httpParam-1](../../../../img/httpParam/httpParam-1.png)
   ```



##########
docs/docs/en/guide/parameter/context.md:
##########
@@ -76,3 +76,21 @@ The result of Node_mysql is as follows:
 Even though output is assigned a value of 1 in Node_A's script, the log still 
shows a value of 100. But according to the principle from [parameter 
priority](priority.md): `Local Parameter > Parameter Context > Global 
Parameter`, the output value in Node_B is 1. It proves that the output 
parameter is passed in the workflow with reference to the expected value, and 
the query operation is completed using this value in Node_mysql.
 
 But the output value 66 only shows in the Node_A, the reason is that the 
direction of value is selected as IN, and only when the direction is OUT will 
it be defined as a variable output.
+
+### HTTP
+
+Step 1: Drag an HTTP task, fill IN body for KEY, select OUT for IN/OUT, select 
VARCHAR for output data type, always select VARCHAR, nothing else.
+
+<img src="../../../../img/httpParam/httpParam-1.png" alt="httpParam-1.png" 
style="zoom:50%;" />
+
+Step 2: After adding an HTTP task type node, accept the parameters passed 
upstream. This time just add it in the Request Parameters section,
+
+<img src="../../../../img/httpParam/httpParam-2.png" alt="httpParam-2.png" 
style="zoom:50%;" />

Review Comment:
   ```suggestion
   ![httpParam-2](../../../../img/httpParam/httpParam-2.png)
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to