简体   繁体   English

Groovy变压器就像被忽略了

[英]Groovy transformer was like ignored

Good day, collegues. 大家好。 In my project i met some problem. 在我的项目中,我遇到了一些问题。 In one of flows i have made two http_requests and then have parsed those responses with groovy transformer. 在其中的一个流程中,我进行了两个http_request,然后使用常规转换器解析了这些响应。 在此处输入图片说明

First groovy script: 第一个常规脚本:

在此处输入图片说明

Second groovy script: 第二个常规脚本: 在此处输入图片说明

The first groovy script works fine. 第一个常规脚本运行正常。 But the second script don't do anything. 但是第二个脚本什么也没做。 Like it was ignored. 就像它被忽略了。

Both http_responses's structures are similar. 这两个http_responses的结构都相似。

Why the second groovy script can have been ignored? 为什么第二个常规脚本可以被忽略?

Omg!( I am very sorry, this was my very stupid mistake. The reason is - 'break' must be in IF scope... In the first http_response sought value is the first item in collection, that's why it works. 天哪!(很抱歉,这是我非常愚蠢的错误。原因是-“ break”必须在IF范围内...在第一个http_response寻求的值中,集合中的第一个项目是这个原因。

ps shame... ps耻辱...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM