@Extension @Symbol(value="mq-notifier") public final class MQNotifierConfig extends GlobalConfiguration
Descriptor.FormException, Descriptor.PropertyType, Descriptor.SelfExtensionPoint.LegacyInstancesAreScopedToHudsonclazz| Constructor and Description |
|---|
MQNotifierConfig()
Load configuration on invoke.
|
MQNotifierConfig(boolean enableNotifier,
String serverUri,
String userName,
Secret userPassword,
String exchangeName,
String virtualHost,
String routingKey,
boolean persistentDelivery,
String appId,
boolean enableVerboseLogging)
Creates an instance with specified parameters.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
configure(org.kohsuke.stapler.StaplerRequest req,
net.sf.json.JSONObject formData) |
FormValidation |
doTestConnection(String uri,
String name,
Secret pw)
Tests connection to the server URI.
|
String |
getAppId()
Returns application id.
|
protected XmlFile |
getConfigFile()
For backwards-compatibility with the previous Plugin derived version.
|
String |
getDisplayName() |
boolean |
getEnableNotifier()
Gets whether this plugin is enabled or not.
|
boolean |
getEnableVerboseLogging()
Gets whether verbose logging is enabled or not.
|
String |
getExchangeName()
Gets the exchange name.
|
static MQNotifierConfig |
getInstance()
Gets this extension's instance.
|
boolean |
getPersistentDelivery()
Returns true if persistentDelivery is to be used.
|
String |
getRoutingKey()
Gets the routing key.
|
String |
getServerUri()
Gets URI for MQ server.
|
String |
getUserName()
Gets user name.
|
Secret |
getUserPassword()
Gets user password.
|
String |
getVirtualHost()
Gets the virtual host name.
|
void |
setAppId(String appId)
Sets application id.
|
void |
setEnableNotifier(boolean enableNotifier)
Sets flag whether this plugin is enabled or not.
|
void |
setEnableVerboseLogging(boolean enableVerboseLogging)
Sets flag whether verbose logging is enabled or not.
|
void |
setExchangeName(String exchangeName)
Sets the exchange name.
|
void |
setPersistentDelivery(boolean pd)
Sets persistent delivery mode.
|
void |
setRoutingKey(String routingKey)
Sets the routing key.
|
void |
setServerUri(String serverUri)
Sets URI for MQ server.
|
void |
setUserName(String userName)
Sets user name.
|
void |
setUserPassword(Secret userPassword)
Sets user password.
|
void |
setVirtualHost(String virtualHost)
Sets the virtual host name.
|
all, getDescriptor, getGlobalConfigPageaddHelpFileRedirect, calcAutoCompleteSettings, calcFillSettings, configure, doHelp, find, find, findByDescribableClassName, findById, getCategory, getCheckMethod, getCheckUrl, getConfigPage, getCurrentDescriptorByNameUrl, getDescriptorFullUrl, getDescriptorUrl, getGlobalPropertyType, getHelpFile, getHelpFile, getHelpFile, getId, getJsonSafeClassName, getKlass, getPlugin, getPossibleViewNames, getPropertyType, getPropertyType, getPropertyTypeOrDie, getRequiredGlobalConfigPagePermission, getT, getViewPage, isInstance, isSubTypeOf, load, newInstance, newInstance, newInstancesFromHeteroList, newInstancesFromHeteroList, save, self, toArray, toList, toMap@DataBoundConstructor
public MQNotifierConfig(boolean enableNotifier,
String serverUri,
String userName,
Secret userPassword,
String exchangeName,
String virtualHost,
String routingKey,
boolean persistentDelivery,
String appId,
boolean enableVerboseLogging)
enableNotifier - if this plugin is enabledserverUri - the server uriuserName - the user nameuserPassword - the user passwordexchangeName - the name of the exchangevirtualHost - the name of the virtual hostroutingKey - the routing keypersistentDelivery - if using persistent delivery modeappId - the application idenableVerboseLogging - if verbose logging is enabledpublic MQNotifierConfig()
public boolean configure(org.kohsuke.stapler.StaplerRequest req,
net.sf.json.JSONObject formData)
throws Descriptor.FormException
configure in class GlobalConfigurationDescriptor.FormExceptionprotected XmlFile getConfigFile()
getConfigFile in class Descriptor<GlobalConfiguration>public boolean getEnableNotifier()
public void setEnableNotifier(boolean enableNotifier)
enableNotifier - true if this plugin is enabled.public boolean getEnableVerboseLogging()
public void setEnableVerboseLogging(boolean enableVerboseLogging)
enableVerboseLogging - true if this verbose logging is enabled.public String getServerUri()
public void setServerUri(String serverUri)
serverUri - the URI.public String getUserName()
public void setUserName(String userName)
userName - the user name.public Secret getUserPassword()
public void setUserPassword(Secret userPassword)
userPassword - the user password.public static MQNotifierConfig getInstance()
If Jenkins.getInstance() isn't available
or the plugin class isn't registered null will be returned.
public String getExchangeName()
public void setExchangeName(String exchangeName)
exchangeName - the exchange name.public String getVirtualHost()
public void setVirtualHost(String virtualHost)
virtualHost - the exchange name.public String getRoutingKey()
public void setRoutingKey(String routingKey)
routingKey - the routing key.public boolean getPersistentDelivery()
public void setPersistentDelivery(boolean pd)
pd - if persistentDelivery is to be used.public String getAppId()
public void setAppId(String appId)
appId - Application id to usepublic String getDisplayName()
getDisplayName in class Descriptor<GlobalConfiguration>public FormValidation doTestConnection(@QueryParameter(value="serverUri") String uri, @QueryParameter(value="userName") String name, @QueryParameter(value="userPassword") Secret pw) throws javax.servlet.ServletException
uri - the URI.name - the user name.pw - the user password.javax.servlet.ServletException - Exception for servlet.Copyright © 2016–2022. All rights reserved.