io.vertx.ext.sync

## Class SyncVerticle

- java.lang.Object
- - io.vertx.core.AbstractVerticle
  - - io.vertx.ext.sync.SyncVerticle

- All Implemented Interfaces:
    Verticle

      public abstract class SyncVerticle
      extends AbstractVerticle

  A `Verticle` which runs its `start` and `stop` methods using fibers. You should subclass this class instead of `AbstractVerticle` to create any verticles that use vertx-sync.
  Author:
    Tim Fox

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected co.paralleluniverse.fibers.FiberScheduler` | `instanceScheduler`

    - ### Fields inherited from class io.vertx.core.AbstractVerticle

      `context, vertx`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SyncVerticle()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `start()` Override this method in your verticle
    `void` | `start(Promise<Void> startFuture)` Start the verticle instance.
    `void` | `stop()` Optionally override this method in your verticle if you have cleanup to do
    `void` | `stop(Promise<Void> stopFuture)` Stop the verticle instance.

    - ### Methods inherited from class io.vertx.core.AbstractVerticle

      `config, deploymentID, getVertx, init, processArgs, start, stop`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### instanceScheduler

          protected co.paralleluniverse.fibers.FiberScheduler instanceScheduler

  - ### Constructor Detail

    - #### SyncVerticle

          public SyncVerticle()

  - ### Method Detail

    - #### start

          public void start(Promise<Void> startFuture)
                     throws Exception

      Description copied from interface: `Verticle`
      Start the verticle instance.

      Vert.x calls this method when deploying the instance. You do not call it yourself.

      A promise is passed into the method, and when deployment is complete the verticle should either call `Promise.complete(T)` or `Promise.fail(java.lang.Throwable)` the future.

      Parameters:
        `startFuture` - the future
      Throws:
        `Exception`

    - #### stop

          public void stop(Promise<Void> stopFuture)
                    throws Exception

      Description copied from interface: `Verticle`
      Stop the verticle instance.

      Vert.x calls this method when un-deploying the instance. You do not call it yourself.

      A promise is passed into the method, and when un-deployment is complete the verticle should either call `Promise.complete(T)` or `Promise.fail(java.lang.Throwable)` the future.

      Parameters:
        `stopFuture` - the future
      Throws:
        `Exception`

    - #### start

          @Suspendable
          public void start()
                                  throws Exception

      Override this method in your verticle
      Overrides:
        `start` in class `AbstractVerticle`
      Throws:
        `Exception`

    - #### stop

          @Suspendable
          public void stop()
                                 throws Exception

      Optionally override this method in your verticle if you have cleanup to do
      Overrides:
        `stop` in class `AbstractVerticle`
      Throws:
        `Exception`

Copyright © 2019 Eclipse. All rights reserved.