Uploaded image for project: 'Dev - Nexus Repo'
  1. Dev - Nexus Repo
  2. NEXUS-8074

Staging Profiles REST service should respect a specified id when creating a profile

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Won't Fix
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Staging
    • Labels:
      None

      Description

      Based on NXCM-2847

      An id specified when creating a staging profile through POST to "/service/local/staging/profiles" is ignored - a new one is generated for the created resource. If an id is specified the service should respect it.

      I'm raising this as a request for improvement. My use case is the following (original response):

      In order to manage the configuration of our Nexus services, we're are using a configuration management tool (Puppet in our case). This means, the whole Nexus configuration is kept in source control and enforce by Puppet. This allows us to

      • Collaborate on changes via pull requests
      • Test changes in CI by spinning up a test instance with that particular configuration and run tests against it to make sure the change is sane
      • Roll bad changes back to previously working versions
      • Revert unwanted changes made through the UI

      Thus we don't backup the inner state of a Nexus service as we can easily restore it via Puppet. So if in our case Nexus is completely broken or some hardware failure killed the instance, we just restore the repository files from backup and provision Nexus from scratch. We're currently managing Nexus internal files like nexus.xml or staging.xml directly. This caused already some upgrade pain as the format changed and Puppet simply reverted the change. It also requires a restart of the service to pick up changes. Not cool.

      REST to the rescue: we've started to use the REST interface offered by Nexus to configure it as needed (read more about the Puppet module we've open sourced to manage Nexus via REST). This is much better as we may not need to manage any of the Nexus relavant configuration files any more and can leave it up to Nexus to change them as required whilst still being able to enforce a certain configuration. But due to the limitation reported by this issue, we currently cannot re-create a staging profile with a certain id out of the box. This is not the end of the world but simply requires some human intervention in the whole configuration process which is easy to forget.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned
              Reporter:
              mmeinhold Martin Meinhold [Atlassian]
              Last Updated By:
              Peter Lynch
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Date of First Response:

                  tigCommentSecurity.panel-title