use of org.apache.cxf.customer.book.Book in project cxf by apache.
the class AbstractBookServerHttp2 method run.
protected void run() {
SpringBusFactory factory = new SpringBusFactory();
Bus bus = factory.createBus(context);
bus.setProperty(HttpServerEngineSupport.ENABLE_HTTP2, true);
setBus(bus);
JAXRSServerFactoryBean sf = new JAXRSServerFactoryBean();
sf.setBus(bus);
sf.setResourceClasses(BookStore.class);
sf.setProvider(new StreamingResponseProvider<Book>());
sf.setResourceProvider(BookStore.class, new SingletonResourceProvider(new BookStore(), true));
sf.setAddress(scheme + "://localhost:" + port + "/http2");
server = sf.create();
}
use of org.apache.cxf.customer.book.Book in project cxf by apache.
the class AbstractBookServerHttp2 method run.
protected void run() {
SpringBusFactory factory = new SpringBusFactory();
Bus bus = factory.createBus(context);
bus.setProperty(HttpServerEngineSupport.ENABLE_HTTP2, true);
setBus(bus);
JAXRSServerFactoryBean sf = new JAXRSServerFactoryBean();
sf.setBus(bus);
sf.setResourceClasses(BookStoreWebSocket.class, BookStorePerRequest.class);
sf.setProvider(new StreamingResponseProvider<Book>());
sf.setResourceProvider(BookStoreWebSocket.class, new SingletonResourceProvider(new BookStoreWebSocket(), true));
sf.setAddress(scheme + "://localhost:" + port + "/http2");
server = sf.create();
}
use of org.apache.cxf.customer.book.Book in project cxf by apache.
the class AbstractBookServerHttp2 method run.
protected void run() {
SpringBusFactory factory = new SpringBusFactory();
Bus bus = factory.createBus(context);
bus.setProperty(HttpServerEngineSupport.ENABLE_HTTP2, true);
setBus(bus);
JAXRSServerFactoryBean sf = new JAXRSServerFactoryBean();
sf.setBus(bus);
sf.setResourceClasses(BookStore.class);
sf.setProvider(new StreamingResponseProvider<Book>());
sf.setResourceProvider(BookStore.class, new SingletonResourceProvider(new BookStore(), true));
sf.setAddress(scheme + "://localhost:" + port + "/http2");
server = sf.create();
}
Aggregations