Skip to content

[JENKINS-54662] hudson.model.UsageStatistics not compatible with CasC plugin #20125

Closed

Description

@jenkins-infra-bot

When trying to configure Jenkins through CASC plugin, one desired feature is to enable / disable "Usage Statistics". Unfortunately, the hudson.model.UsageStatistics descriptor is lacking a @​DataBoundSetter and just relies on the configure function to apply the appropriate configuration to the Jenkins instance.

According to: https://github.com/jenkinsci/configuration-as-code-plugin/blob/master/docs/REQUIREMENTS.md, we need a boolean field with a getter and setter annotated with @​DataBoundSetter so that we can configure it from within the CASC plugin. We would also have to modify the configure function according to the requirements of the CASC plugin, which should follow best-practices.

I would like to contribute with this change if one of the Core Developers agree.


Originally reported by dgarzon, imported from: hudson.model.UsageStatistics not compatible with CasC plugin
  • assignee: timja
  • status: Resolved
  • priority: Minor
  • component(s): core
  • label(s): jcasc-compatibility, stalled-pr
  • resolution: Fixed
  • resolved: 2020-03-16T10:22:31+00:00
  • votes: 0
  • watchers: 4
  • imported: 2025-11-24
Raw content of original issue

When trying to configure Jenkins through CASC plugin, one desired feature is to enable / disable "Usage Statistics". Unfortunately, the hudson.model.UsageStatistics descriptor is lacking a @DataBoundSetter and just relies on the configure function to apply the appropriate configuration to the Jenkins instance.

According to: https://github.com/jenkinsci/configuration-as-code-plugin/blob/master/docs/REQUIREMENTS.md, we need a boolean field with a getter and setter annotated with @DataBoundSetter so that we can configure it from within the CASC plugin. We would also have to modify the configure function according to the requirements of the CASC plugin, which should follow best-practices.

I would like to contribute with this change if one of the Core Developers agree.

Activity

  1. jenkins-infra-bot commented on Nov 16, 2018

    @jenkins-infra-bot
    Author
    oleg_nenashev:

    #3762

  2. jenkins-infra-bot commented on Sep 8, 2019

    @jenkins-infra-bot
    Author
    twalter:
    • Original comment link
    • Raw content of original comment:

      oleg_nenashev Any update on this? The linked PR was closed without being merged.

    oleg_nenashev Any update on this? The linked PR was closed without being merged.

  3. jenkins-infra-bot commented on Sep 16, 2019

    @jenkins-infra-bot
    Author
    oleg_nenashev:
    • Original comment link
    • Raw content of original comment:

      Does not look so. I reset the status

    Does not look so. I reset the status

  4. jenkins-infra-bot commented on Mar 6, 2020

    @jenkins-infra-bot
    Author
    timja:

    Another attempt:
    #4549

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions