Uploaded image for project: 'Artifactory Binary Repository'
  1. Artifactory Binary Repository
  2. RTFACT-21267

Upgrade blocked when license is managed by MC and license file is not persisted

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Resolution: Done
    • Affects Version/s: 6.23.13, 7.18.3, 7.21.3
    • Fix Version/s: 7.31.10
    • Component/s: None
    • Labels:
      None
    • Severity:
      High

      Description

      Problem description:

      This issue is relevant for JFrog E+ users, who manage their Artifactory licenses via Mission Control, and there is no data persistency for the $ARTIFACTORY_HOME/etc/ directory.

      This is common for our Helm Chart users.
      (Note it does not default configuration)

      Unlike with any other setup, when having the license attached via MC you are not exposed to the actual licenses.
      With any other setup, you have Artifactory licenses which can be attached as documented on GitHub under: "Install Artifactory HA license".

      The upgrade will fail, due to:

      16-Feb-2020 11:30:01.789 SEVERE [localhost-startStop-2] org.apache.catalina.core.StandardContext.listenerStart Exception sending context initialized event to listener instance of class [org.artifactory.webapp.servlet.ArtifactoryHomeConfigListener]
      	java.lang.RuntimeException: Converter can't run since no matching license found, please add new license
      		at org.artifactory.converter.ConvertersManagerImpl.handleException(ConvertersManagerImpl.java:223)
      		at org.artifactory.converter.ConvertersManagerImpl.convert(ConvertersManagerImpl.java:149)
      		at org.artifactory.converter.ConvertersManagerImpl.convertHomeSync(ConvertersManagerImpl.java:112)
      		at org.artifactory.webapp.servlet.BasicConfigManagers.initHomes(BasicConfigManagers.java:121)
      		at org.artifactory.webapp.servlet.BasicConfigManagers.initialize(BasicConfigManagers.java:101)
      		at org.artifactory.webapp.servlet.ArtifactoryHomeConfigListener.contextInitialized(ArtifactoryHomeConfigListener.java:53)
      		at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4770)
      		at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5236)
      		at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
      		at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:754)
      		at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
      		at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:744)
      		at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:624)
      		at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1833)
      		at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
      		at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
      		at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
      		at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
      		at java.base/java.lang.Thread.run(Thread.java:834)
      	Caused by: java.lang.RuntimeException: Converter can't run since no matching license found, please add new license
      		at org.artifactory.converter.ConvertersManagerImpl.convert(ConvertersManagerImpl.java:140)
      		... 17 more
      

       

      Steps to reproduce:

      You can simulate such an environment with the following reproduction steps:
      1. Install Artifactory 6.12.2/7.21.3 with an external DB.
      2. Add an ha-node.properties file so the node will start in HA mode (even though just 1 node). (For RT v7.x configure system.yaml to support HA)
      3. Shut down Artifactory.
      4. remove the $ARTIFACTORY_HOME/etc/artifactory.cluster.license.
      5. Upgrade Artifactory. It will fail with the stacktrace as mentioned above at $ARTIFACTORY_HOME/logs/catalina/localhost.<DATE>.log.

       

      Expected behavior: 

      Artifactory Upgrade should finish without relay on licenses located in the var/etc/artifactory folder.

      Possible Solution:
      Before starting the migration, in case a license file doesn't exist locally, try to pull it from the DB.

        Attachments

          Activity

              People

              Assignee:
              Unassigned
              Reporter:
              arielk Ariel Kabov
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Sync Status

                  Connection: RTFACT Sync
                  RTMID-21267 -
                  SYNCHRONIZED
                  • Last Sync Date: