SPIKE: apply Vert.x Config to configure application classes

Priority

Environment

None

Template

None

Description

Intro

There is a need to have a tool to put and retrieve application settings from an external storage.

For example a module works with a database and has to have different DB settings (like connection url, JDBC driver etc) depending on the environment:

  • settings for LOCAL:

  • settings for UAT:

Usually this is done by placing settings in a property file or other type of independent storage and making the code read and apply the configuration during initialization stage.

Vert.x platform configuration support

There are many Java libraries that provide configuration facilities. Vert.x platform has its own tool called Vert.x Config (VC) (on github). It's a quite rich framework that:

  • offers multiple configuration syntaxes (json, properties, yaml (extension), hocon (extension)…​

  • offers multiple configuration stores (files, directories, http, git (extension), redis (extension), system properties, environment properties)…​

  • lets you define the processing order and overloading

  • supports runtime reconfiguration

  • can be extended with custom configuration storage and formats

Typical scenario of using VC assumes that you:

  1. set up configuration store(s)

  2. create configuration retriever and add the store(s) to it

  3. use the retriever to get configuration

  4. take settings from the configuration and apply them

This works fine unless you have too many classes to configure or you can't do it in a single place and at the same moment. If your class hierarchy is big and multi-leveled or you need to get the configuration once and reuse it later on in different places then it's become a bit tricky.

Spike goals

The goal of the spike is to develop a solution on top of VC to be able to:

  • read configuration once and share it across class hierarchy in most convenient way

  • make configuration stores to be configurable themselves (do not change code if a new store to be added or changed)

  • support real time configuration changes for shared configuration [optional]

  • intergate mod-configuration with VC as another configuration storage [optional]

Development Team

Spitfire

Release

None

Story Points

Sprint

Checklist

hide

TestRail: Results

Activity

Show:

Dima Tkachenko March 5, 2019 at 9:36 AM

the story in not actual - closed

Khalilah Gambrell March 4, 2019 at 4:45 PM

- can we close this story?

Won't Do

Details

Assignee

Reporter

Fix versions

TestRail: Cases

Open TestRail: Cases

TestRail: Runs

Open TestRail: Runs

Created October 23, 2018 at 3:09 PM
Updated March 5, 2019 at 9:36 AM
Resolved March 5, 2019 at 9:36 AM
TestRail: Cases
TestRail: Runs