Tabnine Logo
VertxImpl.vertx
Code IndexAdd Tabnine to your IDE (free)

How to use
vertx
method
in
io.vertx.core.impl.VertxImpl

Best Java code snippets using io.vertx.core.impl.VertxImpl.vertx (Showing top 8 results out of 315)

origin: eclipse-vertx/vert.x

@Override
public Vertx vertx(VertxOptions options) {
 if (options.isClustered()) {
  throw new IllegalArgumentException("Please use Vertx.clusteredVertx() to create a clustered Vert.x instance");
 }
 return VertxImpl.vertx(options);
}
origin: eclipse-vertx/vert.x

 @Test
 public void testHttpBindError() {
  RuntimeException cause = new RuntimeException();
  vertx = VertxImpl.vertx(new VertxOptions(), new Transport() {
   @Override
   public ChannelFactory<? extends ServerChannel> serverChannelFactory(boolean domainSocket) {
    return (ChannelFactory<ServerChannel>) () -> {
     throw cause;
    };
   }
  });

  vertx.createHttpServer()
   .requestHandler(req -> fail())
   .listen(8080, "localhost", onFailure(err -> {
   testComplete();
  }));
  await();
 }
}
origin: eclipse-vertx/vert.x

@Test
public void testNetBindError() {
 RuntimeException cause = new RuntimeException();
 vertx = VertxImpl.vertx(new VertxOptions(), new Transport() {
  @Override
  public ChannelFactory<? extends ServerChannel> serverChannelFactory(boolean domainSocket) {
   return (ChannelFactory<ServerChannel>) () -> {
    throw cause;
   };
  }
 });
 vertx.createNetServer()
  .connectHandler(so -> fail())
  .listen(1234, "localhost", onFailure(err -> {
  testComplete();
 }));
 await();
}
origin: eclipse-vertx/vert.x

private void testConnectErrorNotifiesOnEventLoop(NetClientOptions options) {
 RuntimeException cause = new RuntimeException();
 vertx = VertxImpl.vertx(new VertxOptions(), new Transport() {
  @Override
  public ChannelFactory<? extends Channel> channelFactory(boolean domainSocket) {
   return (ChannelFactory<Channel>) () -> {
    throw cause;
   };
  }
 });
 vertx.createNetServer().connectHandler(so -> {
  fail();
 }).listen(1234, "localhost", onSuccess(v -> {
  vertx.createNetClient(options).connect(1234, "localhost", onFailure(err -> {
   assertSame(err, cause);
   testComplete();
  }));
 }));
 await();
}
origin: io.vertx/vertx-core

@Override
public Vertx vertx(VertxOptions options) {
 if (options.isClustered()) {
  throw new IllegalArgumentException("Please use Vertx.clusteredVertx() to create a clustered Vert.x instance");
 }
 return VertxImpl.vertx(options);
}
origin: io.vertx/vertx-core

 @Test
 public void testHttpBindError() {
  RuntimeException cause = new RuntimeException();
  vertx = VertxImpl.vertx(new VertxOptions(), new Transport() {
   @Override
   public ChannelFactory<? extends ServerChannel> serverChannelFactory(boolean domainSocket) {
    return (ChannelFactory<ServerChannel>) () -> {
     throw cause;
    };
   }
  });

  vertx.createHttpServer()
   .requestHandler(req -> fail())
   .listen(8080, "localhost", onFailure(err -> {
   testComplete();
  }));
  await();
 }
}
origin: io.vertx/vertx-core

@Test
public void testNetBindError() {
 RuntimeException cause = new RuntimeException();
 vertx = VertxImpl.vertx(new VertxOptions(), new Transport() {
  @Override
  public ChannelFactory<? extends ServerChannel> serverChannelFactory(boolean domainSocket) {
   return (ChannelFactory<ServerChannel>) () -> {
    throw cause;
   };
  }
 });
 vertx.createNetServer()
  .connectHandler(so -> fail())
  .listen(1234, "localhost", onFailure(err -> {
  testComplete();
 }));
 await();
}
origin: io.vertx/vertx-core

private void testConnectErrorNotifiesOnEventLoop(NetClientOptions options) {
 RuntimeException cause = new RuntimeException();
 vertx = VertxImpl.vertx(new VertxOptions(), new Transport() {
  @Override
  public ChannelFactory<? extends Channel> channelFactory(boolean domainSocket) {
   return (ChannelFactory<Channel>) () -> {
    throw cause;
   };
  }
 });
 vertx.createNetServer().connectHandler(so -> {
  fail();
 }).listen(1234, "localhost", onSuccess(v -> {
  vertx.createNetClient(options).connect(1234, "localhost", onFailure(err -> {
   assertSame(err, cause);
   testComplete();
  }));
 }));
 await();
}
io.vertx.core.implVertxImplvertx

Popular methods of VertxImpl

  • createEventLoopContext
  • resolveAddress
  • <init>
  • cancelTimer
  • close
  • closeClusterManager
  • clusteredVertx
  • context
  • createDatagramSocket
  • createDnsClient
  • createHaManager
  • createHttpClient
  • createHaManager,
  • createHttpClient,
  • createHttpServer,
  • createNetClient,
  • createNetServer,
  • createSharedWorkerExecutor,
  • deleteCacheDirAndShutdown,
  • deployVerticle,
  • executeBlocking

Popular in Java

  • Reading from database using SQL prepared statement
  • requestLocationUpdates (LocationManager)
  • startActivity (Activity)
  • getResourceAsStream (ClassLoader)
  • URLConnection (java.net)
    A connection to a URL for reading or writing. For HTTP connections, see HttpURLConnection for docume
  • Format (java.text)
    The base class for all formats. This is an abstract base class which specifies the protocol for clas
  • List (java.util)
    An ordered collection (also known as a sequence). The user of this interface has precise control ove
  • Locale (java.util)
    Locale represents a language/country/variant combination. Locales are used to alter the presentatio
  • SortedMap (java.util)
    A map that has its keys ordered. The sorting is according to either the natural ordering of its keys
  • Get (org.apache.hadoop.hbase.client)
    Used to perform Get operations on a single row. To get everything for a row, instantiate a Get objec
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now