single service handler for thrift and http