Accessing ServletContext from the RestController

20 views
Skip to first unread message

Darrell Esau

unread,
Jun 17, 2012, 11:01:30 PM6/17/12
to se...@googlegroups.com
Hi,

Any reason we can't access the ServletContext from a RestController?

Seems like it should be accessible with a few getters (assuming it's persisted somewhere in ResponseHelper).

-d

Eduardo Yáñez Parareda

unread,
Jun 18, 2012, 4:49:52 AM6/18/12
to se...@googlegroups.com
Hi Darrell, what would you need in the RestController?, I've tried RestController to be independent of Servlets, Request and so on.
If you need something, ask me for it. It'll be easy to add...

Darrell Esau

unread,
Jun 18, 2012, 6:50:11 PM6/18/12
to se...@googlegroups.com
Well -- currently, I need getServletContextName() name and getRealPath(), but I could certainly see the need for getInitParameter().

Any reason to make the context inaccessible?

-d

Eduardo Yáñez Parareda

unread,
Aug 6, 2012, 12:24:47 PM8/6/12
to se...@googlegroups.com
Hi, sorry for the delay... Next version will have methods to access all of those stuff...
Reply all
Reply to author
Forward
0 new messages