»cfg4j« is a modern configuration library for distributed apps written in Java.

Release 2.0.0

»cfg4j« 2.0.0 released!

We're proud to announce the 2.0.0 release of »cfg4j«. Learn more about new features in this article.

Changes

New features

  • support configuration refresh
    • on-demand (e.g. using source-supported push mechanism)
    • periodical (every N miliseconds)
    • define your own refresh strategy
  • multi-environment/multi-tenant support
    • Use environments to specify which configuration environment from the configuration source to use (see Environment class)
    • git source: default behavior - map environments to git branches and directories in those branches (see EnvironmentBasedBranchResolver and EnvironmentBasedPathResolver)
    • git: implement BranchResolver and PathResolver to override default behavior
  • logging through SLF4J

2.0.0 artifacts

Installation

Gradle

dependencies {
  compile group: "org.cfg4j", name:"cfg4j-core", version: "2.0.0"

  // Optional plug-ins

  // Consul integration
  compile group: "org.cfg4j", name:"cfg4j-consul", version: "2.0.0"

  // Git integration
  compile group: "org.cfg4j", name:"cfg4j-git", version: "2.0.0"
}

Maven

<dependencies>
  <dependency>
    <groupId>org.cfg4j</groupId>
    <artifactId>cfg4j-core</artifactId>
    <version>2.0.0</version>
  </dependency>
  
  <!-- Optional plug-ins -->
  
  <!-- Consul integration -->
  <dependency> 
    <groupId>org.cfg4j</groupId>
    <artifactId>cfg4j-consul</artifactId>
    <version>2.0.0</version>
  </dependency>
  
  <!-- Git integration -->
  <dependency>
    <groupId>org.cfg4j</groupId>
    <artifactId>cfg4j-git</artifactId>
    <version>2.0.0</version>
  </dependency>
</dependencies>