Description
Hi,
I would like to extend CXF-3996 for ClientPolicyInFaultInterceptor and ServerPolicyOutFaultInterceptor. Both interceptors will check POLICY_OVERRIDE message context property firstly and, if policy is provided, it will be used (the same way as in PolicyInInterceptor, PolicyOutInterceptor).
The reason of this extension is use cases where fault interceptor chain should be also controlled dynamically using POLICY_OVERRIDE mechanism (for example in case of WS-Addressing: if it was dynamically activated in PolicyInInterceptor, PolicyOutInterceptor it must be also consequentially done in ClientPolicyInFaultInterceptor and ServerPolicyOutFaultInterceptor, otherwise faults will be processed incorrectly). It also harmonise all policy interceptors code.
Patch includes:
1 extended EffectivePolicyImpl to support getting fault interceptors from PolicyInterceptorProviderRegistry
2)updated ClientPolicyInFaultInterceptor and ServerPolicyOutFaultInterceptor
3)harmonized PolicyInInterceptor, PolicyOutInterceptor
4)corresponded junit tests
Regards,
Andrei.