Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-53353

Jenkins requires restart when installing plugins with TransientViewActionFactories

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • core
    • None
    • jenkins-core:2.140
    • 2.144

      TransientViewActionFactories are only ever called once per view, see here

       

      This means that if you install a plugin that affects the view (via a TransientViewActionFactory) and getActions() has already been called for that view, your implementation of TransientViewActionFactory will not be called and your action will not happen (eg, populating a sidepanel entry etc).

       

      We should either implement an ExtensionListener to dirty the cached transientActions when a new plugin is loaded, or do away with the caching altogether

          [JENKINS-53353] Jenkins requires restart when installing plugins with TransientViewActionFactories

          Steve Arch created issue -
          Steve Arch made changes -
          Summary Original: Jenkins requires restart when installing plugins with TransientActionFactories New: Jenkins requires restart when installing plugins with TransientViewActionFactories
          Steve Arch made changes -
          Description Original: TransientViewActionFactories are only ever called once per view, see [here|[https://github.com/jenkinsci/jenkins/blob/jenkins-2.140/core/src/main/java/hudson/model/View.java#L555-L557].]

           

          This means that if you install a plugin that affects the view (via a TransientViewActionFactory) and getActions() has already been called for that view, your implementation of TransientViewActionFactory will not be called and your action will not happen (eg, populating a sidepanel entry etc).

           

          We should either implement an ExtensionListener to dirty the cached transientActions when a new plugin is loaded, or do away with the caching altogether
          New: TransientViewActionFactories are only ever called once per view, see [here|https://github.com/jenkinsci/jenkins/blob/992100ac4223b3d5eab11e8dccae5e55c2a18484/core/src/main/java/hudson/model/View.java#L555-L557]

           

          This means that if you install a plugin that affects the view (via a TransientViewActionFactory) and getActions() has already been called for that view, your implementation of TransientViewActionFactory will not be called and your action will not happen (eg, populating a sidepanel entry etc).

           

          We should either implement an ExtensionListener to dirty the cached transientActions when a new plugin is loaded, or do away with the caching altogether
          Steve Arch made changes -
          Assignee New: Steve Arch [ agentgonzo ]
          Steve Arch made changes -
          Status Original: Open [ 1 ] New: In Progress [ 3 ]

          Steve Arch added a comment -

          Steve Arch added a comment - https://github.com/jenkinsci/jenkins/pull/3608/files
          Steve Arch made changes -
          Status Original: In Progress [ 3 ] New: In Review [ 10005 ]
          Steve Arch made changes -
          Released As New: 2.144
          Resolution New: Fixed [ 1 ]
          Status Original: In Review [ 10005 ] New: Resolved [ 5 ]

            agentgonzo Steve Arch
            agentgonzo Steve Arch
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: