|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sonyericsson.hudson.plugins.gerrit.trigger.config.Config
public class Config
Configuration bean for the global configuration.
Field Summary | |
---|---|
static boolean |
DEFAULT_BUILD_CURRENT_PATCHES_ONLY
Default value for isGerritBuildCurrentPatchesOnly() . |
static boolean |
DEFAULT_ENABLE_MANUAL_TRIGGER
Default manual trigger enabled. |
static boolean |
DEFAULT_ENABLE_PLUGIN_MESSAGES
Default plug-in messages enabled. |
static int |
DEFAULT_GERRIT_BUILD_FAILURE_CODE_REVIEW_VALUE
Default code review vote to Gerrit when a build is failed. |
static int |
DEFAULT_GERRIT_BUILD_FAILURE_VERIFIED_VALUE
Default verified vote to Gerrit when a build is failed. |
static int |
DEFAULT_GERRIT_BUILD_NOT_BUILT_CODE_REVIEW_VALUE
Default code review vote to Gerrit when a build is not built. |
static int |
DEFAULT_GERRIT_BUILD_NOT_BUILT_VERIFIED_VALUE
Default verified vote to Gerrit when a build is not built. |
static int |
DEFAULT_GERRIT_BUILD_STARTED_CODE_REVIEW_VALUE
Default code review vote to Gerrit when a build is started. |
static int |
DEFAULT_GERRIT_BUILD_STARTED_VERIFIED_VALUE
Default verified vote to Gerrit when a build is started. |
static int |
DEFAULT_GERRIT_BUILD_SUCCESSFUL_CODE_REVIEW_VALUE
Default code review vote to Gerrit when a build is successful. |
static int |
DEFAULT_GERRIT_BUILD_SUCCESSFUL_VERIFIED_VALUE
Default verified vote to Gerrit when a build is successful. |
static int |
DEFAULT_GERRIT_BUILD_UNSTABLE_CODE_REVIEW_VALUE
Default code review vote to Gerrit when a build is unstable. |
static int |
DEFAULT_GERRIT_BUILD_UNSTABLE_VERIFIED_VALUE
Default verified vote to Gerrit when a build is unstable. |
static int |
DEFAULT_GERRIT_WATCHDOG_TIMEOUT_MINUTES
Default timeout value in minutes for the connection watchdog. |
Constructor Summary | |
---|---|
Config()
Constructs a config with default data. |
|
Config(IGerritHudsonTriggerConfig config)
Copy constructor. |
|
Config(net.sf.json.JSONObject formData)
Constructor. |
|
Config(net.sf.json.JSONObject formData,
org.kohsuke.stapler.StaplerRequest req)
Unused Constructor? |
Method Summary | |
---|---|
int |
getBuildScheduleDelay()
Returns the BuildScheduleDelay. |
List<VerdictCategory> |
getCategories()
Get the list of available VerdictCategories. |
int |
getDynamicConfigRefreshInterval()
Returns the dynamicConfigRefreshInterval. |
com.sonymobile.tools.gerrit.gerritevents.watchdog.WatchTimeExceptionData |
getExceptionData()
|
com.sonymobile.tools.gerrit.gerritevents.ssh.Authentication |
getGerritAuthentication()
|
File |
getGerritAuthKeyFile()
|
String |
getGerritAuthKeyFilePassword()
|
int |
getGerritBuildFailedCodeReviewValue()
The default code review value for build failed. |
int |
getGerritBuildFailedVerifiedValue()
The default verified value for build failed. |
int |
getGerritBuildNotBuiltCodeReviewValue()
The default code review value for build not built. |
int |
getGerritBuildNotBuiltVerifiedValue()
The default verified value for build not built. |
int |
getGerritBuildStartedCodeReviewValue()
The default code review value for build started. |
int |
getGerritBuildStartedVerifiedValue()
The default verified value for build started. |
int |
getGerritBuildSuccessfulCodeReviewValue()
The default code review value for build successful. |
int |
getGerritBuildSuccessfulVerifiedValue()
The default verified value for build successful. |
int |
getGerritBuildUnstableCodeReviewValue()
The default code review value for build unstable. |
int |
getGerritBuildUnstableVerifiedValue()
The default verified value for build unstable. |
String |
getGerritCmdBuildFailed()
The command template to use when sending build-failed messages to Gerrit. |
String |
getGerritCmdBuildNotBuilt()
The command template to use when sending build-not-built messages to Gerrit. |
String |
getGerritCmdBuildStarted()
The command template to use when sending build-started messages to Gerrit. |
String |
getGerritCmdBuildSuccessful()
The command template to use when sending build-successful messages to Gerrit. |
String |
getGerritCmdBuildUnstable()
The command template to use when sending build-unstable messages to Gerrit. |
String |
getGerritEMail()
|
String |
getGerritFrontEndUrl()
Base URL for the Gerrit UI. |
String |
getGerritFrontEndUrlFor(com.sonymobile.tools.gerrit.gerritevents.dto.events.GerritTriggeredEvent event)
Creates a URL to the provided changeset number. |
String |
getGerritFrontEndUrlFor(String changeSetNumber,
String revision)
Creates a URL to the provided changeset number. |
String |
getGerritHostName()
|
String |
getGerritHttpPassword()
The password for the HTTP REST API. |
String |
getGerritHttpUserName()
The user name for the HTTP REST API. |
String |
getGerritProxy()
|
int |
getGerritSshPort()
|
String |
getGerritUserName()
|
org.apache.http.auth.Credentials |
getHttpCredentials()
|
int |
getNumberOfReceivingWorkerThreads()
Deprecated. |
int |
getNumberOfSendingWorkerThreads()
Deprecated. |
ReplicationConfig |
getReplicationConfig()
The configurations related to event replication. |
int |
getWatchdogTimeoutMinutes()
Convenience getter for the jelly view. |
int |
getWatchdogTimeoutSeconds()
|
boolean |
hasDefaultValues()
If the plugin still has default values for hostname and frontendurl. |
boolean |
isEnableManualTrigger()
Getter for the enableManualTrigger value. |
boolean |
isEnablePluginMessages()
If other plugins are allowed to contribute messages to be forwarded to Gerrit. |
boolean |
isGerritBuildCurrentPatchesOnly()
If enabled, then old patch revision builds will be canceled. |
boolean |
isUseRestApi()
If the HTTP REST API should be used for change approval instead of the sh API. |
void |
setBuildScheduleDelay(int buildScheduleDelay)
Setting buildScheduleDelay. |
void |
setCategories(List<VerdictCategory> categories)
Setter for the list of VerdictCategories, used to make testing easier. |
void |
setDynamicConfigRefreshInterval(int dynamicConfigRefreshInterval)
Setting dynamicConfigRefreshInterval. |
void |
setEnableManualTrigger(boolean enableManualTrigger)
Sets if the manual trigger should be enabled or not. |
void |
setGerritAuthKeyFile(File gerritAuthKeyFile)
GerritAuthKeyFile. |
void |
setGerritAuthKeyFilePassword(String gerritAuthKeyFilePassword)
GerritAuthKeyFilePassword. |
void |
setGerritBuildCurrentPatchesOnly(boolean gerritBuildCurrentPatchesOnly)
GerritBuildCurrentPatchesOnly. |
void |
setGerritEMail(String gerritEMail)
The e-mail address for the user in gerrit. |
void |
setGerritFrontEndURL(String gerritFrontEndURL)
GerritFrontEndURL. |
void |
setGerritHostName(String gerritHostName)
GerritHostName. |
void |
setGerritHttpPassword(String gerritHttpPassword)
Sets gerritHttpPassword. |
void |
setGerritHttpUserName(String gerritHttpUserName)
Sets gerritHttpUserName. |
void |
setGerritProxy(String gerritProxy)
GerritProxy. |
void |
setGerritSshPort(int gerritSshPort)
GerritSshPort. |
void |
setGerritUserName(String gerritUserName)
GerritUserName. |
void |
setGerritVerifiedCmdBuildFailed(String cmd)
GerritVerifiedCmdBuildFailed. |
void |
setGerritVerifiedCmdBuildNotBuilt(String cmd)
GerritVerifiedCmdBuildNotBuilt. |
void |
setGerritVerifiedCmdBuildStarted(String cmd)
GerritVerifiedCmdBuildStarted. |
void |
setGerritVerifiedCmdBuildSuccessful(String cmd)
GerritVerifiedCmdBuildSuccessful. |
void |
setGerritVerifiedCmdBuildUnstable(String cmd)
GerritVerifiedCmdBuildUnstable. |
void |
setNumberOfReceivingWorkerThreads(int numberOfReceivingWorkerThreads)
Deprecated. |
void |
setNumberOfSendingWorkerThreads(int numberOfSendingWorkerThreads)
Deprecated. |
void |
setUseRestApi(boolean useRestApi)
Sets useRestApi. |
void |
setValues(net.sf.json.JSONObject formData)
Sets all config values from the provided JSONObject. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int DEFAULT_GERRIT_BUILD_STARTED_VERIFIED_VALUE
public static final int DEFAULT_GERRIT_BUILD_STARTED_CODE_REVIEW_VALUE
public static final int DEFAULT_GERRIT_BUILD_UNSTABLE_VERIFIED_VALUE
public static final int DEFAULT_GERRIT_BUILD_UNSTABLE_CODE_REVIEW_VALUE
public static final int DEFAULT_GERRIT_BUILD_FAILURE_VERIFIED_VALUE
public static final int DEFAULT_GERRIT_BUILD_FAILURE_CODE_REVIEW_VALUE
public static final int DEFAULT_GERRIT_BUILD_SUCCESSFUL_CODE_REVIEW_VALUE
public static final int DEFAULT_GERRIT_BUILD_SUCCESSFUL_VERIFIED_VALUE
public static final int DEFAULT_GERRIT_BUILD_NOT_BUILT_VERIFIED_VALUE
public static final int DEFAULT_GERRIT_BUILD_NOT_BUILT_CODE_REVIEW_VALUE
public static final int DEFAULT_GERRIT_WATCHDOG_TIMEOUT_MINUTES
public static final boolean DEFAULT_ENABLE_MANUAL_TRIGGER
public static final boolean DEFAULT_ENABLE_PLUGIN_MESSAGES
public static final boolean DEFAULT_BUILD_CURRENT_PATCHES_ONLY
isGerritBuildCurrentPatchesOnly()
.
Constructor Detail |
---|
public Config(net.sf.json.JSONObject formData)
formData
- the data.public Config(IGerritHudsonTriggerConfig config)
config
- the Config object to be copied.public Config()
public Config(net.sf.json.JSONObject formData, org.kohsuke.stapler.StaplerRequest req)
formData
- the datareq
- a path.Method Detail |
---|
public void setValues(net.sf.json.JSONObject formData)
IGerritHudsonTriggerConfig
setValues
in interface IGerritHudsonTriggerConfig
formData
- the JSON object with form data.public File getGerritAuthKeyFile()
getGerritAuthKeyFile
in interface com.sonymobile.tools.gerrit.gerritevents.ssh.SshConnectionConfig
public void setGerritAuthKeyFile(File gerritAuthKeyFile)
gerritAuthKeyFile
- the filegetGerritAuthKeyFile()
public String getGerritAuthKeyFilePassword()
getGerritAuthKeyFilePassword
in interface com.sonymobile.tools.gerrit.gerritevents.ssh.SshConnectionConfig
public void setGerritAuthKeyFilePassword(String gerritAuthKeyFilePassword)
gerritAuthKeyFilePassword
- the passwordgetGerritAuthKeyFilePassword()
public void setGerritBuildCurrentPatchesOnly(boolean gerritBuildCurrentPatchesOnly)
gerritBuildCurrentPatchesOnly
- whether to only build the current patch setisGerritBuildCurrentPatchesOnly()
public String getGerritFrontEndUrl()
IGerritHudsonTriggerConfig
getGerritFrontEndUrl
in interface IGerritHudsonTriggerConfig
getGerritFrontEndUrl
in interface com.sonymobile.tools.gerrit.gerritevents.GerritConnectionConfig
getGerritFrontEndUrl
in interface com.sonymobile.tools.gerrit.gerritevents.rest.RestConnectionConfig
public void setGerritFrontEndURL(String gerritFrontEndURL)
gerritFrontEndURL
- the URLgetGerritFrontEndUrl()
public String getGerritHostName()
getGerritHostName
in interface com.sonymobile.tools.gerrit.gerritevents.ssh.SshConnectionConfig
public void setGerritHostName(String gerritHostName)
gerritHostName
- the hostnamegetGerritHostName()
public int getGerritSshPort()
getGerritSshPort
in interface com.sonymobile.tools.gerrit.gerritevents.ssh.SshConnectionConfig
public void setGerritSshPort(int gerritSshPort)
gerritSshPort
- the portgetGerritSshPort()
public String getGerritProxy()
getGerritProxy
in interface com.sonymobile.tools.gerrit.gerritevents.rest.RestConnectionConfig
getGerritProxy
in interface com.sonymobile.tools.gerrit.gerritevents.ssh.SshConnectionConfig
public void setGerritProxy(String gerritProxy)
gerritProxy
- the proxy urlgetGerritProxy()
public int getBuildScheduleDelay()
IGerritHudsonTriggerConfig
getBuildScheduleDelay
in interface IGerritHudsonTriggerConfig
public void setBuildScheduleDelay(int buildScheduleDelay)
buildScheduleDelay
- the delay timegetBuildScheduleDelay()
public int getDynamicConfigRefreshInterval()
IGerritHudsonTriggerConfig
getDynamicConfigRefreshInterval
in interface IGerritHudsonTriggerConfig
public void setDynamicConfigRefreshInterval(int dynamicConfigRefreshInterval)
dynamicConfigRefreshInterval
- the interval between the fetches.getDynamicConfigRefreshInterval()
public String getGerritUserName()
getGerritUserName
in interface com.sonymobile.tools.gerrit.gerritevents.ssh.SshConnectionConfig
public void setGerritUserName(String gerritUserName)
gerritUserName
- the usernamegetGerritUserName()
public String getGerritEMail()
getGerritEMail
in interface com.sonymobile.tools.gerrit.gerritevents.GerritConnectionConfig
public void setGerritEMail(String gerritEMail)
gerritEMail
- the e-mail address.getGerritEMail()
@Deprecated public int getNumberOfReceivingWorkerThreads()
IGerritHudsonTriggerConfig
getNumberOfReceivingWorkerThreads
in interface IGerritHudsonTriggerConfig
@Deprecated public int getNumberOfSendingWorkerThreads()
IGerritHudsonTriggerConfig
getNumberOfSendingWorkerThreads
in interface IGerritHudsonTriggerConfig
@Deprecated public void setNumberOfReceivingWorkerThreads(int numberOfReceivingWorkerThreads)
numberOfReceivingWorkerThreads
- nr of threads.getNumberOfReceivingWorkerThreads()
@Deprecated public void setNumberOfSendingWorkerThreads(int numberOfSendingWorkerThreads)
IGerritHudsonTriggerConfig
setNumberOfSendingWorkerThreads
in interface IGerritHudsonTriggerConfig
numberOfSendingWorkerThreads
- nr of threads.public boolean isGerritBuildCurrentPatchesOnly()
IGerritHudsonTriggerConfig
isGerritBuildCurrentPatchesOnly
in interface IGerritHudsonTriggerConfig
public String getGerritCmdBuildSuccessful()
IGerritHudsonTriggerConfig
getGerritCmdBuildSuccessful
in interface IGerritHudsonTriggerConfig
public void setGerritVerifiedCmdBuildSuccessful(String cmd)
cmd
- the commandgetGerritCmdBuildSuccessful()
public String getGerritCmdBuildUnstable()
IGerritHudsonTriggerConfig
getGerritCmdBuildUnstable
in interface IGerritHudsonTriggerConfig
public void setGerritVerifiedCmdBuildUnstable(String cmd)
cmd
- the commandgetGerritCmdBuildUnstable()
public String getGerritCmdBuildFailed()
IGerritHudsonTriggerConfig
getGerritCmdBuildFailed
in interface IGerritHudsonTriggerConfig
public void setGerritVerifiedCmdBuildFailed(String cmd)
cmd
- the commandsetGerritVerifiedCmdBuildFailed(java.lang.String)
public String getGerritCmdBuildStarted()
IGerritHudsonTriggerConfig
getGerritCmdBuildStarted
in interface IGerritHudsonTriggerConfig
public void setGerritVerifiedCmdBuildStarted(String cmd)
cmd
- the commandgetGerritCmdBuildStarted()
public String getGerritCmdBuildNotBuilt()
IGerritHudsonTriggerConfig
getGerritCmdBuildNotBuilt
in interface IGerritHudsonTriggerConfig
public void setGerritVerifiedCmdBuildNotBuilt(String cmd)
cmd
- the commandgetGerritCmdBuildNotBuilt()
public int getGerritBuildStartedVerifiedValue()
IGerritHudsonTriggerConfig
getGerritBuildStartedVerifiedValue
in interface IGerritHudsonTriggerConfig
public int getGerritBuildStartedCodeReviewValue()
IGerritHudsonTriggerConfig
getGerritBuildStartedCodeReviewValue
in interface IGerritHudsonTriggerConfig
public int getGerritBuildSuccessfulVerifiedValue()
IGerritHudsonTriggerConfig
getGerritBuildSuccessfulVerifiedValue
in interface IGerritHudsonTriggerConfig
public int getGerritBuildSuccessfulCodeReviewValue()
IGerritHudsonTriggerConfig
getGerritBuildSuccessfulCodeReviewValue
in interface IGerritHudsonTriggerConfig
public int getGerritBuildFailedVerifiedValue()
IGerritHudsonTriggerConfig
getGerritBuildFailedVerifiedValue
in interface IGerritHudsonTriggerConfig
public int getGerritBuildFailedCodeReviewValue()
IGerritHudsonTriggerConfig
getGerritBuildFailedCodeReviewValue
in interface IGerritHudsonTriggerConfig
public int getGerritBuildUnstableVerifiedValue()
IGerritHudsonTriggerConfig
getGerritBuildUnstableVerifiedValue
in interface IGerritHudsonTriggerConfig
public int getGerritBuildUnstableCodeReviewValue()
IGerritHudsonTriggerConfig
getGerritBuildUnstableCodeReviewValue
in interface IGerritHudsonTriggerConfig
public int getGerritBuildNotBuiltVerifiedValue()
IGerritHudsonTriggerConfig
getGerritBuildNotBuiltVerifiedValue
in interface IGerritHudsonTriggerConfig
public int getGerritBuildNotBuiltCodeReviewValue()
IGerritHudsonTriggerConfig
getGerritBuildNotBuiltCodeReviewValue
in interface IGerritHudsonTriggerConfig
public String getGerritFrontEndUrlFor(String changeSetNumber, String revision)
IGerritHudsonTriggerConfig
getGerritFrontEndUrlFor
in interface IGerritHudsonTriggerConfig
changeSetNumber
- the changeset numberrevision
- the patch set number (currently not used)
IGerritHudsonTriggerConfig.getGerritFrontEndUrl()
+ / + numberIGerritHudsonTriggerConfig.getGerritFrontEndUrl()
public String getGerritFrontEndUrlFor(com.sonymobile.tools.gerrit.gerritevents.dto.events.GerritTriggeredEvent event)
IGerritHudsonTriggerConfig
getGerritFrontEndUrlFor
in interface IGerritHudsonTriggerConfig
event
- the gerrit triggered event
IGerritHudsonTriggerConfig.getGerritFrontEndUrlFor(String, String)
public List<VerdictCategory> getCategories()
IGerritHudsonTriggerConfig
getCategories
in interface IGerritHudsonTriggerConfig
public void setCategories(List<VerdictCategory> categories)
setCategories
in interface IGerritHudsonTriggerConfig
categories
- the list.public boolean isEnableManualTrigger()
isEnableManualTrigger
in interface IGerritHudsonTriggerConfig
public void setEnableManualTrigger(boolean enableManualTrigger)
enableManualTrigger
- true if it should be enabled/shown.isEnableManualTrigger()
public com.sonymobile.tools.gerrit.gerritevents.ssh.Authentication getGerritAuthentication()
getGerritAuthentication
in interface com.sonymobile.tools.gerrit.gerritevents.ssh.SshConnectionConfig
public boolean hasDefaultValues()
IGerritHudsonTriggerConfig
hasDefaultValues
in interface IGerritHudsonTriggerConfig
public boolean isEnablePluginMessages()
IGerritHudsonTriggerConfig
isEnablePluginMessages
in interface IGerritHudsonTriggerConfig
public ReplicationConfig getReplicationConfig()
IGerritHudsonTriggerConfig
getReplicationConfig
in interface IGerritHudsonTriggerConfig
public int getWatchdogTimeoutSeconds()
getWatchdogTimeoutSeconds
in interface com.sonymobile.tools.gerrit.gerritevents.GerritConnectionConfig2
public int getWatchdogTimeoutMinutes()
getWatchdogTimeoutMinutes
in interface com.sonymobile.tools.gerrit.gerritevents.GerritConnectionConfig2
public com.sonymobile.tools.gerrit.gerritevents.watchdog.WatchTimeExceptionData getExceptionData()
getExceptionData
in interface com.sonymobile.tools.gerrit.gerritevents.GerritConnectionConfig2
public boolean isUseRestApi()
IGerritHudsonTriggerConfig
isUseRestApi
in interface IGerritHudsonTriggerConfig
public void setUseRestApi(boolean useRestApi)
useRestApi
- true if soisUseRestApi()
public String getGerritHttpPassword()
IGerritHudsonTriggerConfig
getGerritHttpPassword
in interface IGerritHudsonTriggerConfig
public void setGerritHttpPassword(String gerritHttpPassword)
gerritHttpPassword
- the passwordgetGerritHttpPassword()
public String getGerritHttpUserName()
IGerritHudsonTriggerConfig
getGerritHttpUserName
in interface IGerritHudsonTriggerConfig
public void setGerritHttpUserName(String gerritHttpUserName)
gerritHttpUserName
- the usernamegetGerritHttpUserName()
public org.apache.http.auth.Credentials getHttpCredentials()
getHttpCredentials
in interface com.sonymobile.tools.gerrit.gerritevents.rest.RestConnectionConfig
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |