Class JSONWebHook
java.lang.Object
org.jenkinsci.plugins.registry.notification.webhook.JSONWebHook
- All Implemented Interfaces:
ExtensionPoint,Action,ModelObject,RootAction,UnprotectedRootAction
- Direct Known Subclasses:
ACRWebHook,DockerHubWebHook,DockerRegistryWebHook
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract WebHookPayloadcreatePushNotification(net.sf.json.JSONObject data) voiddoIndex(org.kohsuke.stapler.StaplerRequest2 request, org.kohsuke.stapler.StaplerResponse2 response) If someone wanders in to the index page, redirect to Jenkins root.voiddoNotify(String payload, org.kohsuke.stapler.StaplerRequest2 request, org.kohsuke.stapler.StaplerResponse2 response) getDetails(String sha) Stapler entry for the multi build result pagegetDynamic(String token, org.kohsuke.stapler.StaplerResponse2 rsp) protected voidtrigger(org.kohsuke.stapler.StaplerResponse2 response, PushNotification pushNotification) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface hudson.model.Action
getUrlName
-
Constructor Details
-
JSONWebHook
public JSONWebHook()
-
-
Method Details
-
getIconFileName
- Specified by:
getIconFileNamein interfaceAction
-
getDisplayName
- Specified by:
getDisplayNamein interfaceAction- Specified by:
getDisplayNamein interfaceModelObject
-
doNotify
public void doNotify(@QueryParameter(required=false) String payload, org.kohsuke.stapler.StaplerRequest2 request, org.kohsuke.stapler.StaplerResponse2 response) throws IOException - Throws:
IOException
-
getDynamic
public JSONWebHook.ValidApiToken getDynamic(String token, org.kohsuke.stapler.StaplerResponse2 rsp) throws IOException - Throws:
IOException
-
getDetails
Stapler entry for the multi build result page- Parameters:
sha- the id of the trigger data.- Returns:
- the details
- Throws:
IOException- if soInterruptedException- if so
-
trigger
protected void trigger(org.kohsuke.stapler.StaplerResponse2 response, PushNotification pushNotification) throws IOException - Throws:
IOException
-
doIndex
public void doIndex(org.kohsuke.stapler.StaplerRequest2 request, org.kohsuke.stapler.StaplerResponse2 response) throws IOException If someone wanders in to the index page, redirect to Jenkins root.- Parameters:
request- the request objectresponse- the response object- Throws:
IOException- if so
-
createPushNotification
-