@Override
public Promise<JerseyServer> createServer(JsonObject config) {
final Deferred<JerseyServer> d = new When<JerseyServer>().defer();
try {
final JerseyServer jerseyServer = jerseyServerProvider.get();
JerseyConfigurator configurator = configuratorProvider.get();
configurator.init(config, vertx, container);
jerseyServer.init(configurator, new Handler<AsyncResult<HttpServer>>() {
@Override
public void handle(AsyncResult<HttpServer> result) {
if (result.succeeded()) {
d.getResolver().resolve(jerseyServer);
} else {