use of org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher in project metron by apache.
the class PcapService method main.
public static void main(String[] args) throws IOException {
PcapServiceCli cli = new PcapServiceCli(args);
cli.parse();
ConfigurationUtil.setPcapOutputPath(cli.getPcapHdfsPath());
LOG.info("Pcap location set to {}", cli.getPcapHdfsPath());
ConfigurationUtil.setTempQueryOutputPath(cli.getQueryHdfsPath());
LOG.info("Query temp location set to {}", cli.getQueryHdfsPath());
Server server = new Server(cli.getPort());
ServletContextHandler context = new ServletContextHandler(ServletContextHandler.SESSIONS);
context.setContextPath("/");
ServletHolder h = new ServletHolder(new HttpServletDispatcher());
h.setInitParameter("javax.ws.rs.Application", "org.apache.metron.pcapservice.rest.JettyServiceRunner");
context.addServlet(h, "/*");
server.setHandler(context);
try {
server.start();
server.join();
} catch (Exception e) {
e.printStackTrace();
}
}
use of org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher in project brave by openzipkin.
the class ITTracingFeature_Container method init.
@Override
public void init(ServletContextHandler handler) {
// Adds application programmatically as opposed to using web.xml
handler.addServlet(new ServletHolder(new HttpServletDispatcher()), "/*");
handler.addEventListener(new TracingBootstrap(httpTracing, new TestResource(httpTracing)));
}
use of org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher in project brave by openzipkin.
the class ITDeclarativeSampling method init.
@Override
public void init(ServletContextHandler handler) {
// Adds application programmatically as opposed to using web.xml
handler.addServlet(new ServletHolder(new HttpServletDispatcher()), "/*");
handler.addEventListener(new TracingBootstrap(httpTracing, new Resource()));
}
use of org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher in project brave by openzipkin.
the class ITSpanCustomizingContainerFilter method init.
@Override
public void init(ServletContextHandler handler) {
// Adds application programmatically as opposed to using web.xml
handler.addServlet(new ServletHolder(new HttpServletDispatcher()), "/*");
handler.addEventListener(new TaggingBootstrap(new TestResource(httpTracing)));
addFilter(handler, TracingFilter.create(httpTracing));
}
Aggregations