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

Allow access to the Jenkins instance and/or plugins

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Minor Minor
    • job-dsl-plugin
    • None

      I'd like to be able to access the Jenkins instance(probably a configurable setting) and it's plugins classes. Importing them fails...

      This will allow, for example, to use the github-api as an authenticated user(as long as it's configurable in Jenkins of course) as opposed to accessing it anonymously(and this will require additional libs in the classpath).

      The groovy post build plugin add the jenkins instance classpath as seen here.

          [JENKINS-27517] Allow access to the Jenkins instance and/or plugins

          Daniel Spilker added a comment - See https://github.com/jenkinsci/job-dsl-plugin/pull/415

          That's my PR, which I'm currently not using, I have the same feeling as this comment here

          Pedro Algarvio added a comment - That's my PR, which I'm currently not using, I have the same feeling as this comment here

          I closed my PR but I'd still like the feature in.

          Pedro Algarvio added a comment - I closed my PR but I'd still like the feature in.

          I will remove the @Grab support soon and with that a lot of class loader magic (pluginFirstClassLoader, maskClasses) will go away. And then it's more likely that this issue is realizable.

          Daniel Spilker added a comment - I will remove the @Grab support soon and with that a lot of class loader magic (pluginFirstClassLoader, maskClasses) will go away. And then it's more likely that this issue is realizable.

          Jarrad Whitaker added a comment - - edited

          Any movement on this?

          My use case is not even to use plugin code, I just want to @TypeCheck
          my Groovy code. Without being able to import hudson.plugins.git.Branch, I don't think it's possible for me to strongly type a method that takes a `Branch` parameter, even if I have no trouble getting the Branch in the first place without the import.

          Jarrad Whitaker added a comment - - edited Any movement on this? My use case is not even to use plugin code, I just want to @TypeCheck my Groovy code. Without being able to import hudson.plugins.git.Branch , I don't think it's possible for me to strongly type a method that takes a `Branch` parameter, even if I have no trouble getting the Branch in the first place without the import.

            jamietanna Jamie Tanna
            s0undt3ch Pedro Algarvio
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated: