Results 1 to 3 of 3

Thread: Access to ServletContext from Endpoint

  1. #1
    Join Date
    Apr 2009
    Posts
    15

    Default Access to ServletContext from Endpoint

    Hi

    My Spring WS 1.5.6 endpoint extends AbstractMarshallingPayloadEndpoint. I'm trying to access the ServletContext from the endpoint's invokeInternal(Object o) method, is this possible? I need to get at my servlet's initParams which were set in the web.xml's <context-param> element. Any suggestions?

    Thanks in advance,
    Barry

  2. #2
    Join Date
    Sep 2006
    Posts
    6

    Default

    Did you ever find an answer? I have the same problem.

    John

  3. #3
    Join Date
    Apr 2009
    Posts
    15

    Default

    Yes, I did find out but forgot to post the answer back here!

    You just need to implement the interface 'ServletContextAware' and have it injected by Spring at runtime.

    Hope that helps.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •