[SWS-779] PayloadValidatingInterceptor 's method is not getting triggered in the echo server sample program when the echo client program is executed. Created: 07/Jun/12  Updated: 28/Jun/12  Resolved: 26/Jun/12

Status: Resolved
Project: Spring Web Services
Component/s: Core
Affects Version/s: 2.1 GA
Fix Version/s: 2.1.1

Type: Bug Priority: Trivial
Reporter: Venkat Ganesh Assignee: Arjen Poutsma
Resolution: Invalid Votes: 0
Labels: springwebservices
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

$ java -version
java version "1.6.0_30"
Java(TM) SE Runtime Environment (build 1.6.0_30-b12)
Java HotSpot(TM) 64-Bit Server VM (build 20.5-b03, mixed mode)

$ uname -a
Linux stardev 3.2.0-24-generic #39-Ubuntu SMP Mon May 21 16:52:17 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux

apache-tomcat-7.0.22 spring-ws-2.1.0.RELEASE

Attachments: Text File callstack1.txt     Text File callstack2.txt    


I am following the instructions available at spring-ws-2.1.0.RELEASE/samples/echo/readme.txt. The file spring-ws-2.1.0.RELEASE/samples/echo/server/target/echo-server.war is successfully deployed at apache-tomcat-7.0.22/webapps/echo-server. When I run the client program "mvn install exec:java" from spring-ws-2.1.0.RELEASE/samples/echo/client/spring-ws/ directory, I can verify call stacks 1 and 2, attached to this issue does get invoked and the program completes successfully.

However, I have set breakpoint for PayloadValidatingInterceptor class and also the methods in this class. The interceptor is not getting invoked. Why, the interceptor's callback methods are not getting called? My intent is to to add some application logic when the interceptor call back method is called after I can verify the callbacks are really getting called.

Thanks and regards,

$ grep PayloadValidatingInterceptor spring-ws-2.1.0.RELEASE/samples/echo/server/src/main/webapp/WEB-INF/spring-ws-servlet.xml
<bean class="org.springframework.ws.soap.server.endpoint.interceptor.PayloadValidatingInterceptor">

Break points are here:

EchoEndpoint [line: 67] - EchoEndpoint(EchoService)
EchoEndpoint [line: 83] - handleEchoRequest(Element)
PayloadValidatingInterceptor [line: 52] - getValidationRequestSource(WebServiceMessage)
PayloadValidatingInterceptor [line: 63] - getValidationResponseSource(WebServiceMessage)
WebServiceMessageReceiverHandlerAdapter [line: 50] - getLastModified(HttpServletRequest, Object)
WebServiceMessageReceiverHandlerAdapter [line: 56] - handle(HttpServletRequest, HttpServletResponse, Object)
WebServiceMessageReceiverHandlerAdapter [line: 72] - supports(Object)
WebServiceMessageReceiverHandlerAdapter [entry] - getLastModified(HttpServletRequest, Object)
WebServiceMessageReceiverHandlerAdapter [entry] - handle(HttpServletRequest, HttpServletResponse, Object)
WebServiceMessageReceiverHandlerAdapter [entry] - supports(Object)

Comment by Arjen Poutsma [ 26/Jun/12 ]

I think your put breakpoints on the client-side PayloadValidatingInterceptor (i.e. org.springframework.ws.client.support.interceptor.PayloadValidatingInterceptor),and they should be on the server-side variant (org.springframework.ws.soap.server.endpoint.interceptor.PayloadValidatingInterceptor).

Comment by Venkat Ganesh [ 28/Jun/12 ]

thanks for the clarification. I am able to verify server side interceptor is getting called. Please close this issue. Thanks a lot.

Generated at Thu Oct 18 16:10:43 UTC 2018 using JIRA 7.9.2#79002-sha1:3bb15b68ecd99a30eb364c4c1a393359bcad6278.