Since CDI beans do not support final methods could I make filter final by using @Vetoed?
On Fri, Aug 7, 2015 at 10:54 AM, Romain Manni-Bucau <[email protected]> wrote: > just curiosity: remove @Singleton and making the class @Vetoed should > ensure it is not a CDI bean or an EJB so it would be a bit faster for this > particular impl. > > > Romain Manni-Bucau > @rmannibucau <https://twitter.com/rmannibucau> | Blog > <http://rmannibucau.wordpress.com> | Github < > https://github.com/rmannibucau> | > LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber > <http://www.tomitribe.com> > > 2015-08-07 7:48 GMT-07:00 sgjava <[email protected]>: > > > This is what I ended up with: > > > > @Singleton > > @Provider > > public class ServerResponseLoggingFilter implements > ContainerResponseFilter > > { > > > > /** > > * Logger. > > */ > > //CHECKSTYLE:OFF ConstantName > > private static final Logger log = LoggerFactory. > > getLogger(ServerResponseLoggingFilter.class); > > //CHECKSTYLE:ON ConstantName > > > > @Override > > public void filter(final ContainerRequestContext requestContext, > > final ContainerResponseContext responseContext) { > > log.debug(String.format("Entity: %s", > > responseContext.getEntity())); > > } > > } > > > > > > > > -- > > View this message in context: > > > http://tomee-openejb.979440.n4.nabble.com/ContainerResponseFilter-for-logging-tp4675772p4675778.html > > Sent from the TomEE Users mailing list archive at Nabble.com. > > > -- Steven P. Goldsmith
