Annotation Type Order


  • @Retention(RUNTIME)
    public @interface Order
    Annotation to configure an explicit "order" for method handlers. This annotation exposes the Vert.x Route.order(int) API as an an alternative way to force handler order, if you don't like to write lambda handler fields, or handler reference fields. Note that because Vert.x-web internally sets an incrementing (0-based) order for handlers set up without an explicit order specified, mixing handlers with @Order and without can lead to undesired results. One strategy to mitigate this is to use the @Order annotation only with very large numbers (1000 and above) to make sure explicitly ordered handlers are executed after all implicitly ordered handlers, or to set negative numbers to make sure explicitly ordered handlers are executed before all implicitly ordered handlers.
    Author:
    odeda
    See Also:
    Vert.x-web ordering documentation
    • Required Element Summary

      Required Elements 
      Modifier and Type Required Element Description
      int value
      The order (ascending) that this handler will be called within all handlers that match the current requests.
    • Element Detail

      • value

        int value
        The order (ascending) that this handler will be called within all handlers that match the current requests.
        Returns:
        order