From ea6b14f3af26fd78381229056f80c450e73dd795 Mon Sep 17 00:00:00 2001 From: Dave Syer Date: Thu, 5 May 2016 08:27:08 +0000 Subject: [PATCH] Sync docs from master to gh-pages --- spring-cloud-config.html | 53 +++++++++++++++++++++++++++++++++++----- 1 file changed, 47 insertions(+), 6 deletions(-) diff --git a/spring-cloud-config.html b/spring-cloud-config.html index 97dbf01d..ab7c9c8d 100644 --- a/spring-cloud-config.html +++ b/spring-cloud-config.html @@ -440,6 +440,7 @@ body.book #toc,body.book #preamble,body.book h1.sect0,body.book .sect1>h2{page-b
  • Serving Encrypted Properties
  • +
  • Serving Alternative Formats
  • Serving Plain Text
  • Embedding the Config Server
  • Push Notifications and Spring Cloud Bus
  • @@ -517,11 +518,6 @@ list of properties), and "label" is an optional git label (defaults to "master".)

    -

    The YAML and properties forms are coalesced into a single -map, even if the origin of the values (reflected in the -"propertySources" of the "standard" form) has multiple sources.

    -
    -

    Spring Cloud Config Server pulls configuration for remote clients from a git repository (which must be provided):

    @@ -1581,6 +1577,51 @@ key nor the enabled flag.

    +

    Serving Alternative Formats

    +
    +
    +

    The default JSON format from the environment endpoints is perfect for +consumption by Spring applications because it maps directly onto the +Environment abstraction. If you prefer you can consume the same data +as YAML or Java properties by adding a suffix to the resource path +(".yml", ".yaml" or ".properties"). This can be useful for consumption +by applications that do not care about the structure of the JSON +endpoints, or the extra metadata they provide, for example an +application that is not using Spring might benefit fro mthe simplicity +of this approach.

    +
    +
    +

    The YAML and properties representations have an additional flag +(provided as a boolean query parameter resolvePlaceholders) to +signal that placeholders in the source documents, in the standard +Spring ${…​} form, should be resolved in the output where possible +before rendering. This is a useful feature for consumers that don’t +know about the Spring placeholder conventions.

    +
    +
    + + + + + +
    +
    Note
    +
    +there are limitations in using the YAML or properties formats, +mainly in relation to the loss of metadata. The JSON is structured as +an ordered list of property sources, for example, with names that +correlate with the source. The YAML and properties forms are coalesced +into a single map, even if the origin of the values has multiple +sources, and the names of teh original source files are lost. The YAML +representation is not necessarily a faithful representation of the +YAML source in a backing repository either: it is constructed from a +list of flat property sources, and assumptions have to be made about +the form of the keys. +
    +
    +
    +
    +

    Serving Plain Text

    @@ -1985,7 +2026,7 @@ grabbing it in the bootstrap context and injecting one).