We are happy to announce the release of SeedStack 16.11 «Kiwi». This is a major release bringing new exciting changes such as a cleaner, much more powerful configuration system.

This post is about the revision 2 of SeedStack 16.11 which is the recommended version as the time of writing. There is no release note for 16.11 and 16.11.1 versions.

W20

The JavaScript W20 framework is no longer a part of SeedStack itself and has been moved to its own Github organization in which it will continue to evolve separately. This change makes of SeedStack, a full Java development solution. This separation greatly simplifies the evolution, the documentation and the «market positioning» of SeedStack and W20.

As before, you can still use the W20 bridge add-on to automate the integration between SeedStack and W20.

W20 document is now available on https://w20-framework.github.io/.

New features

Configuration system

As of version 16.11, SeedStack is changing from a basic key-value configuration system to something much more sophisticated yet still simple to use. This new configuration system is internally named Coffig and is a flexible library that can be integrated with anything.

It is multi-source (YAML, JSON, properties, environment variables, cloud configuration …), each providing a part of a global configuration tree. This tree can then be mapped to any POJO either by a simple annotation or programmatically.

The most notable features are:

  • Main configuration file named application.yaml at the root of the classpath,
  • Hierarchical configuration structure,
  • Flexible mapping, from a single property to complex objects graphs
  • Strongly typed mapping with built-in handling of many useful types: array, list, set, map, enum, optional, uri/url, properties, class
  • Predictable overriding (for tests, from command-line, …)
  • Bean validation of configuration POJOs,
  • Macros
  • Complex functions
  • Profiles
  • Automatic hiding of sensitive information (like password)

More information here.

Tooling support

SeedStack 16.11 adds support for tools that can be run on the project to execute a particular task. In tool mode, the application is initialized with the minimal amount of plugins necessary to execute the task but never fully started.

Tools can be run:

  • With the Maven plugin, either with the tool goal which can run any tool by name or with a specific goal for simplicity.
  • By executing the SeedMain class with the system property seedstack.tool set to the name of the tool to execute.

The following tools are built-in in this version:

  • config which describes all the configuration options of the application.
  • effective-config which dumps the global configuration tree as resolved by the application (useful for debugging configuration issues).
  • crypt which can crypt its arguments using the master key store configured in the application (useful for crypting passwords in configuration).
  • errors which displays the catalog of error codes existing in the application.

HTTP/HTTPS proxy support

JVM-wide HTTP and HTTPS proxy is now auto-configured from standard http_proxy, https_proxy and no_proxy environment variables. This behavior can be disabled in configuration where the proxy can be turned off or an explicit proxy can be specified.

Netflix add-on

A new add-on integrating some Netflix open-source technologies is now provided. It provides integration for the
Netflix Hystrix circuit-breaker and the OpenFeign REST client.

More information here.

Bean validation

The bean validation integration is now part of SeedStack core and is always enabled as it is used by the configuration system. Remove the add-on from your existing projects. Validation features are otherwise unchanged.

Add-on archetype

A new archetype for creating add-ons from scratch is now provided in the distribution.

Fixes

You can find about all fixes by checking the detailed change logs of each component on GitHub, in their release section. The versions of all components and the link to their changelog is available at the end of this article.

Breaking changes

Java 8

This version requires Java 8 as it uses Java 8 internally and some APIs include Java 8 features.

Configuration changes

All SeedStack configuration options have been refactored to benefit of the new configuration features: hierarchical structure, strong typing, validation, … Prefixes have been removed in favor of shorter, simpler names, in camel case.

Configuration files from previous versions must be rewritten in YAML using new property names. While this can be a bit of work, existing options still have the same semantic as before, making it easy to translate from old to new format.

You can use the documentation to learn about the new options and the config tool (see above) can be of great help to discover every option. New configuration is a lot more explicit and strongly typed so potential errors are easily diagnosed and fixed.

Jersey 1

Jersey 1 support has been removed. Only Jersey 2 which is a drop-in replacement for Jersey 1 is available.

Module simplification

Some modules (seed-transaction, seed-el and seed-crypto) have been merged into the seed-core module. You must remove those dependencies from your existing projects.

The shell and metrics modules have been separated as add-ons and are not part of the java framework anymore. They are unchanged feature-wise.

The data security feature has been also separated as an add-on. It is unchanged feature-wise.

Annotation detection

Annotation detection behavior on methods and classes has been standardized across the whole stack. A consistent detection behavior is now used everywhere:

  • On methods and constructors:
    • The annotation is searched on the method/constructor with a fallback on its declaring class.
    • If not found, every method/constructor overridden/implemented by it is searched with a fallback on its own declaring class.
  • On classes, the annotation is searched on the class.

It is worth noting that:

  • Superclasses are not searched but inheritable annotations will be found if present on a class up in the hierarchy.
  • Meta-annotations (annotations annotated by the searched annotation) are always searched.

This new unified behavior does not deviate a lot from previous version behaviors, but we still recommend that you check your annotations, particularly for transaction management which have subtle semantics.

Utilities

The collection of various utilities previously located under the org.seedstack.seed.core.utils package have been rewritten from scratch in a no-dependency utility library named shed. This library includes various pure-java utilities used throughout SeedStack.

Other breaking changes

Other minor breaking changes are listed in the changelog of each component. The versions of all components and the link to their changelog is available at the end of this article.

Component versions

Poms

Core

Add-ons