14

I am trying to create a simple jenkins plug-in that will run a job but Project.doBuild() requires StaplerRequest and StaplerResponse.

What is the Stapler (org.kohsuke.stapler.Stapler), StaplerRequest(org.kohsuke.stapler.StaplerRequest), and StaplerResponse(org.kohsuke.stapler.StaplerResponse)? What do they do and how do they work?

Thanks for any help.

1 Answer 1

18

Check out http://stapler.kohsuke.org

Stapler is a library that "staples" your application objects to URLs, making it easier to write web applications. The core idea of Stapler is to automatically assign URLs for your objects, creating an intuitive URL hierarchy.

2
  • 1
    Thanks! that looks helpful. Is there any reason doBuild() needs that hough?
    – user833970
    Commented Jul 7, 2011 at 17:43
  • @user833970: If this answer was what you were looking for, the way to accept it is to click the check mark beside the answer.
    – Jonathan M
    Commented Aug 18, 2011 at 15:40

Not the answer you're looking for? Browse other questions tagged or ask your own question.