Uploaded image for project: 'Satellite'
  1. Satellite
  2. SAT-24333

[DOC] The activation_keys and hostgroup_id options cannot be optional at the same time in the registration_commands API end point

XMLWordPrintable

    • Improve doc of options in registration_commands
    • False
    • Hide

      None

      Show
      None
    • False
    • 0
    • 0% To Do, 0% In Progress, 100% Done
    • Rocket
    • 3.12.0

      Description of problem:

      While accessing the apidoc for "POST /api/registration_commands" endpoint, Every single option is marked as Optional.

      Specifically for hostgroup_id and activation_key(s) the concern is present. We mark both of them optional in the apidoc and even allow passing a nil value for the hostgroup_id.

      but that cannot happen. A registration process requires an activation key and it will either come from the activation_key(s) option or the AK selected in HG provided by hostgroup_id option.

      If we don't pass HG or AK while generating the command via hammer or API, the command generation will fail.

      If we don't pass AK and just pass a blank value for hostgroup_id, Then the command will be generated but execution of registration would fail since sub-man will not be able to find any activation keys.

      We need to very clearly document the relation between those two options and decide whether we should let them be marked as optional or not.

      Version-Release number of selected component (if applicable):

      Any Sat 6 supported versions

      How reproducible:

      Always

      Steps to Reproduce:
      1.
      2.
      3.

      Actual results:

      Expected results:

      Document the relationship of activation_keys and hostgroup_id options with the registration_commands endpoint and ensure that both are not mentioned optional at the same time.

      Additional info:

              zuansorg Lena Ansorgová
              rhn-support-saydas Sayan Das
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: