Bug #3883
Transaction reports and contained instances have no json support
| Status: | Accepted | Start date: | 05/26/2010 | |
|---|---|---|---|---|
| Priority: | High | Due date: | ||
| Assignee: | - | % Done: | 0% |
|
| Category: | reports | |||
| Target version: | 3.X | |||
| Affected Puppet version: | 0.25.4 | Branch: | ||
| Keywords: | devtriage | |||
| Votes: | 0 |
Description
We are still sending transaction reports over as yaml rather than json, and in fact, none of Transaction::Report, Transaction::Event, or Resource::Status support json.
I’m not sure how big of a deal this is, since we normally just store them as yaml anyway, but my inclination is that this is actually a pretty big deal, so I’m setting this to high unless someone says otherwise.
History
Updated by Jesse Wolfe almost 2 years ago
- Category set to reports
- Assignee set to Luke Kanies
- Target version changed from 2.6.0 to 52
Updated by Luke Kanies over 1 year ago
- Assignee deleted (
Luke Kanies)
Updated by James Turnbull about 1 year ago
- Target version deleted (
52)
Updated by Luke Kanies about 1 year ago
This should be extended to include all indirected data types. Here’s the current status:
Puppet::Node::Facts: to_json: true; from_json: true Puppet::Node::Inventory: to_json: true; from_json: false Puppet::Node: to_json: true; from_json: false Puppet::Transaction::Report: to_json: true; from_json: false Puppet::Resource: to_json: true; from_json: true Puppet::Resource::Type: to_json: true; from_json: true Puppet::Resource::Catalog: to_json: true; from_json: true Puppet::SSL::Key: to_json: true; from_json: false Puppet::SSL::Certificate: to_json: true; from_json: false Puppet::SSL::CertificateRequest: to_json: true; from_json: false Puppet::SSL::CertificateRevocationList: to_json: true; from_json: false Puppet::Status: to_json: true; from_json: true Puppet::FileBucket::File: to_json: true; from_json: true
Built using this code:
require 'puppet'
klass = Puppet::Indirector::Indirection
klass.instances.collect { |name| klass.instance(name).model || fail "no inst for #{name}" }.each { |klass| puts "#{klass}: to_json: #{klass.instance_methods.include?('to_pson')}; from_json: #{klass.respond_to?(:from_pson)}" }
Updated by Nigel Kersten about 1 year ago
- Target version set to 2.7.x
Updated by Nigel Kersten 4 months ago
- Target version changed from 2.7.x to 3.X
- Keywords set to devtriage
Needs developer input.
Updated by Daniel Pittman 4 months ago
Nigel Kersten wrote:
Needs developer input.
We should move to JSON, not YAML, everywhere in the product, and then drop YAML support entirely. Given that, this is relevant but not urgent, since we are unlikely to make that transition in the immediate future.