code: private void doQueueClear(final Message<JsonObject> message) {
      final String name = message.body().getString("name");
      if (name == null) {
        message.reply(new JsonObject().putString("status", "error").putString("message", "No name specified."));
        return;
      }
  
      context.execute(new Action<Void>() {
        @Override
        public Void perform() {
          data.getQueue(formatKey(name)).clear();
          return null;
        }
      }, new Handler<AsyncResult<Void>>() {
        @Override
        public void handle(AsyncResult<Void> result) {
          if (result.failed()) {
            message.reply(new JsonObject().putString("status", "error").putString("message", result.cause().getMessage()));
          } else {
            message.reply(new JsonObject().putString("status", "ok"));
          }
        }
      });
    }
docs: Clears all items in a queue.