1. 20 7月, 2016 1 次提交
  2. 16 5月, 2016 1 次提交
  3. 09 3月, 2016 2 次提交
    • S
      Jenkins.getInstance() will be @Nonnull in Jenkins 2.0+ · 96150d3a
      Stephen Connolly 提交于
      - Code that is running from a plugin and on the master's JVM is guaranteed to never get null from this method (any cases where you do get null are bugs in core)
      - Code that is running from a plugin and on a remote JVM should never be allowed to load the Jenkins class in their classloader, so should never use Jenkins.getInstance()... we are annotating the method with @Nullable so that such code can have some evolution time
      - Code that is running in core and on one of two special paths should use the Jenkins.getInstanceOrNull() method so that the UI can be presented to users before the singleton has been instantiated / after the singleton has been destroyed
      - The remaining 95% of uses in core (and 100% of uses in plugins) can safely assume that the instance is never null
      96150d3a
    • S
      Revert "Jenkins.getInstance() should be non-null" · d1dfbd2b
      Stephen Connolly 提交于
      This reverts commit bb7c8fce.
      
      Closes #2090, I'll redo this as a PR... though if that PR is subject to multiple rounds of review before being merged then I will take that of evidence of the exact problem that committing directly was supposed to resolve... namely exponentially multiplying the effort required to make actual improvements to the code base.
      d1dfbd2b
  4. 08 3月, 2016 2 次提交
    • S
      Noting that there is a >99% certainty that these can use getInstance() · f3675ff5
      Stephen Connolly 提交于
      - Plugins using these methods will be safe
      - The code path I need to analyse is the `Jenkins.super()` constructor code path. As Jenkins extends AbstractCIBase if there is a call there that requires the queue lock during construction it may require these methods to be safe against being called before the singleton has been put in place
      f3675ff5
    • S
      Jenkins.getInstance() should be non-null · bb7c8fce
      Stephen Connolly 提交于
      - It is never too late to do the right thing.
      - The vast majority of usages of `Jenkins.getInstance()` in core currently assume that its return value is non-null
      - This commit changes those that are written to correctly check for non-null values will call `Jenkins.getInstanceOrNull()`
      - We deprecate the `Jenkins.getActiveInstance()` madness
      - I checked with @kohsuke who said not to bother with a PR and just commit this strongly opinionated change direct to master as a PR will just degrade into a bikeshedding.
      bb7c8fce
  5. 07 3月, 2016 1 次提交
  6. 30 1月, 2016 1 次提交
  7. 29 1月, 2016 1 次提交
    • A
      [JENKINS-32517] Deprecate Queue#getApproximateItemsQuickly · 638ceb23
      Andres Rodriguez 提交于
      Now that the item list is obtained lock-free the cache is no longer needed.
      Besides, the cache could be returning invalid results for requests with different authorization to the one that cached the result (in any case this invalid result is transient).
      638ceb23
  8. 26 11月, 2015 1 次提交
    • S
      [FIXED JENKINS-31649] Check should be against AccessControlled and Permission.READ · b51653d2
      Stephen Connolly 提交于
      - The previous check was to narrow.
      - We now check on AccessControlled (which is implemented by Item)
      - We now also check on Permission.READ (which is the generic read permission)
      
      This should allow subtasks who's task may not be an Item to at least implement AccessControlled to alow visibility.
      
      There remains an open question as to whether tasks that are not AccessControlled should ever be visible in the UI
      
      (cherry picked from commit cf1fdf98)
      b51653d2
  9. 25 11月, 2015 1 次提交
  10. 19 11月, 2015 2 次提交
    • S
      [FIXED JENKINS-31649] Check should be against AccessControlled and Permission.READ · cf1fdf98
      Stephen Connolly 提交于
      - The previous check was to narrow.
      - We now check on AccessControlled (which is implemented by Item)
      - We now also check on Permission.READ (which is the generic read permission)
      
      This should allow subtasks who's task may not be an Item to at least implement AccessControlled to alow visibility.
      
      There remains an open question as to whether tasks that are not AccessControlled should ever be visible in the UI
      cf1fdf98
    • J
      Incorporated pull request feedback: · 9303136c
      Johannes Ernst 提交于
      * moved to jenkins.util.SystemProperties
      * consistent naming getString/getInteger/getBoolean
      * improved code formatting
      Improved JavaDoc
      9303136c
  11. 17 11月, 2015 1 次提交
  12. 10 11月, 2015 1 次提交
    • C
      remove unused import statements · 7efb9090
      Christopher Simons 提交于
      In addition to cluttering the namespace, unused imports generate
      compiler warnings, introducing noise and obscuring more important
      compiler warnings.  This change removes them.
      7efb9090
  13. 28 10月, 2015 1 次提交
    • S
      Merge pull request #1815 from varmenise/OSS-192 · f07b3b7e
      Stephen Connolly 提交于
      [FIXED JENKINS-30084] FlyWeightTasks tied to a label will not cause node provisioning and will be blocked forever.
      
      When a flyweighttask is limited to run on a specific label (e.g. matrix project set restrict where this project can run) if there are no nodes with that label available when it enters the queue then it will immediately move to blocked.
      As it is blocked the Node provisioner will not attempt to create any slaves, so the project will sit in the queue forever (or until some other project allocates a slave with the correct label).
      (cherry picked from commit 5a5f9c5d)
      f07b3b7e
  14. 13 10月, 2015 2 次提交
  15. 12 10月, 2015 4 次提交
  16. 02 10月, 2015 18 次提交