Search in sources :

Example 1 with AvaticaHandler

use of org.apache.calcite.avatica.server.AvaticaHandler in project calcite-avatica by apache.

the class AvaticaServersForTest method startServer.

/**
 * Starts Avatica server and cache.
 */
public void startServer(HandlerFactory factory, Service service, Serialization serialization, MetricsSystemConfiguration metricsConfig, AvaticaServerConfiguration serverConfig) {
    AvaticaHandler handler = factory.getHandler(service, serialization, metricsConfig, serverConfig);
    final HttpServer server = new HttpServer.Builder().withHandler(handler).withPort(0).build();
    server.start();
    serversBySerialization.put(serialization, server);
}
Also used : HttpServer(org.apache.calcite.avatica.server.HttpServer) AvaticaHandler(org.apache.calcite.avatica.server.AvaticaHandler)

Aggregations

AvaticaHandler (org.apache.calcite.avatica.server.AvaticaHandler)1 HttpServer (org.apache.calcite.avatica.server.HttpServer)1