Uploaded image for project: 'Puppet Server'
  1. Puppet Server
  2. SERVER-1310

Move projects to use standard error format

    Details

    • Type: Task
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: SERVER 2.5.0
    • Component/s: None
    • Labels:
      None
    • Template:
    • Sub-team:
    • Story Points:
      5
    • Sprint:
      Server Jade 2016-06-01, Server Jade 2016-06-15
    • Release Notes:
      Bug Fix
    • Release Notes Summary:
      Hide
      Previously Puppet Server and many TrapperKeeper projects returned error messages in a format that was similar to, but unfortunately different from, the errors returned by the PE Console and its attendant services. This moves Puppet Server and TrapperKeeper to use the same error format as the PE Console where appropriate.
      Show
      Previously Puppet Server and many TrapperKeeper projects returned error messages in a format that was similar to, but unfortunately different from, the errors returned by the PE Console and its attendant services. This moves Puppet Server and TrapperKeeper to use the same error format as the PE Console where appropriate.

      Description

      It looks like since puppet server started sending error details the rest of the company has moved to a standard format defined here: https://github.com/puppetlabs/puppet-nogui/blob/master/patterns/api_style_guide.md#errors

      We should either adopt the style from the nogui repo, at some reasonable pace, or fight the proponents of the style in mortal combat (or at least in a mailing list).

      To move us from our current style to their style would entail:
      :type becomes :kind
      :message becomes :msg

      The outer {:error ...} should be removed and our additional fields may need to be moved into a :details list.

      As part of this ticket we will also need to update the documentation at: https://confluence.puppetlabs.com/display/ENG/Exceptions+and+Slingshot

      Also, we can turn most of the error handling for most of our tk libraries over to this with changes to ring-middleware however moving Puppet Server and File-Sync would entail more work as there's a number of custom errors defined within them.

        Attachments

          Issue Links

            Activity

              jsd-sla-details-panel

                People

                • Assignee:
                  erik Erik Dasher
                  Reporter:
                  justin Justin Stoller
                  QA Contact:
                  Erik Dasher
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  5 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: