-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: avoid unnecessary nesting when generating yaml
Also add more example snippets that can be used for testing
- Loading branch information
Showing
4 changed files
with
97 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?> | ||
<RaiseFault async="false" continueOnError="true" enabled="true" name="RF-Example" > | ||
<DisplayName>RF-Example</DisplayName> | ||
<FaultResponse> | ||
<AssignVariable > | ||
<Name>flow.var</Name> | ||
<Value>123</Value> | ||
</AssignVariable> | ||
<Add > | ||
<Headers> | ||
<Header name="user-agent" >example</Header> | ||
</Headers> | ||
</Add> | ||
<Copy source="request" > | ||
<Headers> | ||
<Header name="header-name" ></Header> | ||
</Headers> | ||
<StatusCode>304</StatusCode> | ||
</Copy> | ||
<Remove > | ||
<Headers> | ||
<Header name="sample-header" ></Header> | ||
</Headers> | ||
</Remove> | ||
<Set > | ||
<Headers> | ||
<Header name="user-agent" >{request.header.user-agent}</Header> | ||
</Headers> | ||
<Payload contentType="application/json" >{"name":"foo", "type":"bar"}</Payload> | ||
</Set> | ||
<Set > | ||
<ReasonPhrase>Server Error</ReasonPhrase> | ||
<StatusCode>500</StatusCode> | ||
</Set> | ||
</FaultResponse> | ||
<IgnoreUnresolvedVariables>true</IgnoreUnresolvedVariables> | ||
<ShortFaultReason>false</ShortFaultReason> | ||
</RaiseFault> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
RaiseFault: | ||
.async: false | ||
.continueOnError: true | ||
.enabled: true | ||
.name: RF-Example | ||
DisplayName: RF-Example | ||
FaultResponse: | ||
- AssignVariable: | ||
Name: flow.var | ||
Value: 123 | ||
- Add: | ||
Headers: | ||
Header: | ||
.name: user-agent | ||
.@: example | ||
- Copy: | ||
.source: request | ||
Headers: | ||
Header: | ||
.name: header-name | ||
StatusCode: 304 | ||
- Remove: | ||
Headers: | ||
Header: | ||
.name: sample-header | ||
- Set: | ||
Headers: | ||
Header: | ||
.name: user-agent | ||
.@: '{request.header.user-agent}' | ||
Payload: | ||
.contentType: application/json | ||
.@: '{"name":"foo", "type":"bar"}' | ||
- Set: | ||
ReasonPhrase: Server Error | ||
StatusCode: 500 | ||
IgnoreUnresolvedVariables: true | ||
ShortFaultReason: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters