Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-10656

Provide a JSON terminus for facts

    XMLWordPrintable

Details

    • Night's Watch
    • 3
    • ghost-28.10, ghost-4.11
    • New Feature
    • Hide
      This adds a new JSON terminus for facts allowing them to be stored and loaded as json. Puppet agents will continue to default to YAML, but JSON can be used by configuring the "agent" application in routes.yaml:

      ---
      agent:
        facts:
          terminus: facter
          cache: json

      In addition, Puppetserver 7 caches facts *by default* as JSON instead of YAML. The old yaml terminus can be reenabled via `routes.yaml`.
      Show
      This adds a new JSON terminus for facts allowing them to be stored and loaded as json. Puppet agents will continue to default to YAML, but JSON can be used by configuring the "agent" application in routes.yaml: --- agent:   facts:     terminus: facter     cache: json In addition, Puppetserver 7 caches facts *by default* as JSON instead of YAML. The old yaml terminus can be reenabled via `routes.yaml`.
    • Needs Assessment

    Description

      We have a YAML terminus for facts, however YAML can problematic for hexadecimal numbers (see PUP-9505).

      Additionally, JSON is generally a better serialization format for machines to understand, is a smaller spec than YAML, has a relatively mature ecosystem in Java around parsing/serializing, and is backwards compatible with YAML for recent YAML parsers (YAML has become a superset of JSON).

      For these reasons we should implement a JSON terminus for facts (there already exists one for catalogs) and users should be encouraged to use it instead of the YAML terminus.

      Attachments

        Issue Links

          Activity

            People

              florin.dragos Florin Dragos
              justin Justin Stoller
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Zendesk Support