How to access HTTP headers in Spring-ws endpoint?

后端 未结 3 695
余生分开走
余生分开走 2021-01-04 18:49

How can I access HTTP headers in Spring-ws endpoint?

My code looks like this:

public class MyEndpoint extends AbstractMarshallingPayloadEndpoint {
           


        
3条回答
  •  遥遥无期
    2021-01-04 19:36

    I had the same kind of problem (see this other question). I needed to add a Content-Type header to my WS. I went the road of the Servlet Filter. Most of the time, you should not need to change HTTP headers in a webservice. But ... there is sometime a diference between theory and practice.

提交回复
热议问题