Solved! Go to Solution.
Welcome to Apigee Community 🙂
As far as i know, FaultRules can be only set for proxy and target end points as per documentation here. Each policy defines default fault names / error codes which can be generated due to various things. These can be attached to proxy & target endpoints so that faults will be handed appropriately. See below,
While you can put any policy in the fault rule, you commonly use the Assign Message policy. Use the Assign Message policy to generates a custom response message for an error condition. Assign Message enables you to configure an HTTP response with payload, HTTP status code, headers, and reason phrase elements. A policy used in a fault rule is typically not used in the normal flow pipeline. Therefore, when using the Edge UI to create a policy for a fault rule, select the plus sign, "+", next to "Policies" in the UI to add the policy.
<FaultRules> tag is like creating a rule to handle faults. A rule can ask a Assign Message Policy to construct a payload that can be send back to client using <Step> tag. Faults can be automatically generated by polices (error codes) or a fault can be manually generated using Raise Fault policy.
Cheers,
Anil Sagar
Welcome to Apigee Community 🙂
As far as i know, FaultRules can be only set for proxy and target end points as per documentation here. Each policy defines default fault names / error codes which can be generated due to various things. These can be attached to proxy & target endpoints so that faults will be handed appropriately. See below,
While you can put any policy in the fault rule, you commonly use the Assign Message policy. Use the Assign Message policy to generates a custom response message for an error condition. Assign Message enables you to configure an HTTP response with payload, HTTP status code, headers, and reason phrase elements. A policy used in a fault rule is typically not used in the normal flow pipeline. Therefore, when using the Edge UI to create a policy for a fault rule, select the plus sign, "+", next to "Policies" in the UI to add the policy.
<FaultRules> tag is like creating a rule to handle faults. A rule can ask a Assign Message Policy to construct a payload that can be send back to client using <Step> tag. Faults can be automatically generated by polices (error codes) or a fault can be manually generated using Raise Fault policy.
Cheers,
Anil Sagar