RFKSystems Vert.x Utils

Vert.x Utilities

License

License

GroupId

GroupId

com.rfksystems
ArtifactId

ArtifactId

vertx_utils
Last Version

Last Version

1.0.1
Release Date

Release Date

Type

Type

jar
Description

Description

RFKSystems Vert.x Utils
Vert.x Utilities
Project URL

Project URL

https://github.com/rfksystems/vertx_utils
Project Organization

Project Organization

RFK Systems
Source Code Management

Source Code Management

http://github.com/rfksystems/vertx_utils/tree/master

Download vertx_utils

How to add to project

<!-- https://jarcasting.com/artifacts/com.rfksystems/vertx_utils/ -->
<dependency>
    <groupId>com.rfksystems</groupId>
    <artifactId>vertx_utils</artifactId>
    <version>1.0.1</version>
</dependency>
// https://jarcasting.com/artifacts/com.rfksystems/vertx_utils/
implementation 'com.rfksystems:vertx_utils:1.0.1'
// https://jarcasting.com/artifacts/com.rfksystems/vertx_utils/
implementation ("com.rfksystems:vertx_utils:1.0.1")
'com.rfksystems:vertx_utils:jar:1.0.1'
<dependency org="com.rfksystems" name="vertx_utils" rev="1.0.1">
  <artifact name="vertx_utils" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.rfksystems', module='vertx_utils', version='1.0.1')
)
libraryDependencies += "com.rfksystems" % "vertx_utils" % "1.0.1"
[com.rfksystems/vertx_utils "1.0.1"]

Dependencies

compile (3)

Group / Artifact Type Version
io.vertx : vertx-core jar 3.4.2
io.vertx : vertx-config jar 3.4.2
org.jetbrains.kotlin : kotlin-stdlib-jre8 jar 1.1.4-3

test (1)

Group / Artifact Type Version
org.jetbrains.kotlin : kotlin-test jar 1.1.4-3

Project Modules

There are no modules declared in this project.

Vert.x utils

Common Vert.x utilities, written in Kotlin.

Maven Central

Installation

Maven

Add Maven dependency:

<dependency>
    <groupId>com.github.rfksystems</groupId>
    <artifactId>vertx_utils</artifactId>
    <version>${vertx_utils.version}</version>
</dependency>

Utility classes

ManagedVerticleFactory

io.vertx.core.spi.VerticleFactory implementation that sources all options, including class name, deployment options and configuration from io.vertx.core.json.JsonObject structure.

Designed to work with Vert.x Config component, it will also work with anything else provided that the data structure for JsonObject remains the same.

Usage

Define configuration (example in Yaml, but all providers should work given same structure):

com.example.someapp.services.web:
    main: com.example.someapp.services.WebServiceVerticle # Verticle class
    options: # Verticle Deployment options
        ha: true
        instances: 5
        worker: true
        config: # Verticle config, available via config() in verticle class
            foo: bar
            port: 8091

Load configuration and construct the ManagedVerticleFactory providing instance of io.vertx.core.json.JsonObject with above configuration.

Register it to Vert.x

final ManagedVerticleFactory = new ManagedVerticleFactory(servicesConfiguration);
vertx.registerVerticleFactory(managedVerticleFactory);

Deploy verticle:

vertx.deploy("local:com.example.someapp.services.web")

You can change the default local prefix to whatever you please using secondary constructor of ManagedVerticleFactory.

Other managers

See https://jitpack.io

License

Apache License, Version 2.0

com.rfksystems

RFK Systems

Versions

Version
1.0.1
1.0.0