io.loader.jenkins
Class LoaderPublisher

java.lang.Object
  extended by hudson.tasks.BuildStepCompatibilityLayer
      extended by hudson.tasks.Publisher
          extended by hudson.tasks.Notifier
              extended by io.loader.jenkins.LoaderPublisher
All Implemented Interfaces:
hudson.ExtensionPoint, hudson.model.Describable<hudson.tasks.Publisher>, hudson.tasks.BuildStep

public class LoaderPublisher
extends hudson.tasks.Notifier

Sample Builder.

When the user configures the project and enables this builder, Descriptor.newInstance(StaplerRequest) is invoked and a new LoaderPublisher is created. The created instance is persisted to the project configuration XML by using XStream, so this allows you to use instance fields (like #name) to remember the configuration.

When a build is performed, the perform(AbstractBuild, Launcher, BuildListener) method will be invoked.

Author:

Nested Class Summary
static class LoaderPublisher.DescriptorImpl
           
static class LoaderPublisher.LoaderioPerformancePublisherDescriptor
           
 
Nested classes/interfaces inherited from class hudson.tasks.Publisher
hudson.tasks.Publisher.DescriptorExtensionListImpl
 
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
hudson.ExtensionPoint.LegacyInstancesAreScopedToHudson
 
Nested classes/interfaces inherited from interface hudson.tasks.BuildStep
hudson.tasks.BuildStep.PublisherList
 
Field Summary
static LoaderPublisher.LoaderioPerformancePublisherDescriptor DESCRIPTOR
           
 
Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS
 
Constructor Summary
LoaderPublisher(String apiKey, String testId, int errorFailedThreshold, int errorUnstableThreshold, int responseTimeFailedThreshold, int responseTimeUnstableThreshold)
           
 
Method Summary
 String getApiKey()
           
 LoaderPublisher.LoaderioPerformancePublisherDescriptor getDescriptor()
           
 int getErrorFailedThreshold()
           
 int getErrorUnstableThreshold()
           
 hudson.tasks.BuildStepMonitor getRequiredMonitorService()
           
 int getResponseTimeFailedThreshold()
           
 int getResponseTimeUnstableThreshold()
           
 String getTestId()
           
 boolean perform(hudson.model.AbstractBuild build, hudson.Launcher launcher, hudson.model.BuildListener listener)
           
 void setErrorFailedThreshold(int errorFailedThreshold)
           
 void setErrorUnstableThreshold(int errorUnstableThreshold)
           
 void setResponseTimeFailedThreshold(int responseTimeFailedThreshold)
           
 void setResponseTimeUnstableThreshold(int responseTimeUnstableThreshold)
           
 void setTestId(String testId)
           
 
Methods inherited from class hudson.tasks.Publisher
all, getProjectAction, needsToRunAfterFinalized, prebuild
 
Methods inherited from class hudson.tasks.BuildStepCompatibilityLayer
getProjectAction, getProjectActions, perform, prebuild
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface hudson.tasks.BuildStep
getProjectAction, getProjectActions, prebuild
 

Field Detail

DESCRIPTOR

@Extension
public static final LoaderPublisher.LoaderioPerformancePublisherDescriptor DESCRIPTOR
Constructor Detail

LoaderPublisher

@DataBoundConstructor
public LoaderPublisher(String apiKey,
                                            String testId,
                                            int errorFailedThreshold,
                                            int errorUnstableThreshold,
                                            int responseTimeFailedThreshold,
                                            int responseTimeUnstableThreshold)
Method Detail

perform

public boolean perform(hudson.model.AbstractBuild build,
                       hudson.Launcher launcher,
                       hudson.model.BuildListener listener)
                throws InterruptedException,
                       IOException
Specified by:
perform in interface hudson.tasks.BuildStep
Overrides:
perform in class hudson.tasks.BuildStepCompatibilityLayer
Throws:
InterruptedException
IOException

getRequiredMonitorService

public hudson.tasks.BuildStepMonitor getRequiredMonitorService()

getApiKey

public String getApiKey()

getResponseTimeFailedThreshold

public int getResponseTimeFailedThreshold()

setResponseTimeFailedThreshold

public void setResponseTimeFailedThreshold(int responseTimeFailedThreshold)

getResponseTimeUnstableThreshold

public int getResponseTimeUnstableThreshold()

setResponseTimeUnstableThreshold

public void setResponseTimeUnstableThreshold(int responseTimeUnstableThreshold)

getErrorFailedThreshold

public int getErrorFailedThreshold()

setErrorFailedThreshold

public void setErrorFailedThreshold(int errorFailedThreshold)

getErrorUnstableThreshold

public int getErrorUnstableThreshold()

setErrorUnstableThreshold

public void setErrorUnstableThreshold(int errorUnstableThreshold)

getTestId

public String getTestId()

setTestId

public void setTestId(String testId)

getDescriptor

public LoaderPublisher.LoaderioPerformancePublisherDescriptor getDescriptor()
Specified by:
getDescriptor in interface hudson.model.Describable<hudson.tasks.Publisher>
Overrides:
getDescriptor in class hudson.tasks.Notifier


Copyright © 2004-2013 SendGrid Labs. All Rights Reserved.