Constructor and Description |
---|
TransactionFilter() |
Modifier and Type | Method and Description |
---|---|
void |
destroy()
Any cleanup for the filter.
|
void |
doFilter(ServletRequest request,
ServletResponse response,
FilterChain nextFilter)
Wrap the request in a transaction.
|
void |
init(FilterConfig config)
Lookup java:comp/UserTransaction and cache the results.
|
public void init(FilterConfig config) throws ServletException
init
in interface Filter
ServletException
public void doFilter(ServletRequest request, ServletResponse response, FilterChain nextFilter) throws ServletException, java.io.IOException
doFilter
in interface Filter
request
- the servlet requestresponse
- the servlet responsenextFilter
- the next filter in the chainServletException
java.io.IOException