hudson.ivy
Class IvyModule

java.lang.Object
  extended by hudson.model.AbstractModelObject
      extended by hudson.model.Actionable
          extended by hudson.model.AbstractItem
              extended by hudson.model.Job<P,R>
                  extended by hudson.model.AbstractProject<P,R>
                      extended by hudson.ivy.AbstractIvyProject<IvyModule,IvyBuild>
                          extended by hudson.ivy.IvyModule
All Implemented Interfaces:
hudson.ExtensionPoint, hudson.model.BuildableItem, hudson.model.DescriptorByNameOwner, hudson.model.Item, hudson.model.ModelObject, hudson.model.PersistenceRoot, hudson.model.queue.SubTask, hudson.model.Queue.Task, hudson.model.ResourceActivity, hudson.model.Saveable, hudson.search.SearchableModelObject, hudson.search.SearchItem, hudson.security.AccessControlled, org.eclipse.hudson.api.model.IAbstractProject, org.eclipse.hudson.api.model.ICascadingJob, org.eclipse.hudson.api.model.IJob, org.kohsuke.stapler.HttpDeletable, org.kohsuke.stapler.StaplerOverridable

public final class IvyModule
extends AbstractIvyProject<IvyModule,IvyBuild>
implements hudson.model.Saveable

Job that builds projects based on Ivy.

Author:
Timothy Bingaman

Nested Class Summary
static class IvyModule.BecauseOfUpstreamModuleBuildInProgress
          Because the upstream module build is in progress, and we are configured to wait for that.
 
Nested classes/interfaces inherited from class hudson.model.AbstractProject
hudson.model.AbstractProject.AbstractProjectDescriptor, hudson.model.AbstractProject.BecauseOfBuildInProgress, hudson.model.AbstractProject.BecauseOfDownstreamBuildInProgress, hudson.model.AbstractProject.BecauseOfUpstreamBuildInProgress
 
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
hudson.ExtensionPoint.LegacyInstancesAreScopedToHudson
 
Field Summary
 
Fields inherited from class hudson.model.AbstractProject
ABORT, AFFINITY_CHO0SER_KEY, APPOINTED_NODE_PROPERTY_NAME, ASSIGNED_LABEL_KEY, BASIC_KEY, BLOCK_BUILD_WHEN_DOWNSTREAM_BUILDING_PROPERTY_NAME, BLOCK_BUILD_WHEN_UPSTREAM_BUILDING_PROPERTY_NAME, blockBuildWhenDownstreamBuilding, blockBuildWhenUpstreamBuilding, BUILD_TRIGGER_PROPERTY_NAME, builds, CLEAN_WORKSPACE_REQUIRED_PROPERTY_NAME, CONCURRENT_BUILD_PROPERTY_NAME, CUSTOM_WORKSPACE_PROPERTY_NAME, disabled, HAS_QUIET_PERIOD_PROPERTY_NAME, HAS_SCM_CHECKOUT_RETRY_COUNT_PROPERTY_NAME, JDK_PROPERTY_NAME, QUIET_PERIOD_PROPERTY_NAME, SCM_CHECKOUT_RETRY_COUNT_PROPERTY_NAME, SCM_PROPERTY_NAME, SLAVE_KEY, transientActions, triggers
 
Fields inherited from class hudson.model.Job
cascadingProject, createdBy, HISTORY_ADAPTER, LOG_ROTATOR_PROPERTY_NAME, nextBuildNumber, PARAMETERS_DEFINITION_JOB_PROPERTY_PROPERTY_NAME, properties, PROPERTY_NAME_SEPARATOR
 
Fields inherited from class hudson.model.AbstractItem
description, name
 
Fields inherited from interface hudson.model.Saveable
NOOP
 
Fields inherited from interface hudson.model.Item
BUILD, CONFIGURE, CREATE, DELETE, EXTENDED_READ, PERMISSIONS, READ, WIPEOUT, WORKSPACE
 
Method Summary
protected  void addTransientActionsFromBuild(IvyBuild build, List<hudson.model.Action> collection, Set<Class> added)
           
 ModuleDependency asDependency()
          Gets organisation+name+revision as ModuleDependency.
protected  void buildDependencyGraph(hudson.model.DependencyGraph graph)
           
protected  List<hudson.tasks.Publisher> createModulePublishers()
          Creates a list of Publishers to be used for a build of this project.
protected  void doSetName(String name)
           
protected  Collection<IvyModule> getAllIvyModules()
          Returns all Ivy modules in this Jenkins instance.
 hudson.model.Label getAssignedLabel()
          IvyModule uses the workspace of the IvyModuleSet, so it always needs to be built on the same slave as the parent.
protected  Class<IvyBuild> getBuildClass()
           
 hudson.util.DescribableList<hudson.tasks.BuildWrapper,hudson.model.Descriptor<hudson.tasks.BuildWrapper>> getBuildWrappersList()
           
 hudson.model.queue.CauseOfBlockage getCauseOfBlockage()
           
 String getDisplayName()
           
 String getIvyBranch()
          Gets the Ivy branch in the ivy.xml file as of the last build.
 hudson.model.JDK getJDK()
           
 hudson.tasks.LogRotator getLogRotator()
          IvyModule follows the same log rotation schedule as its parent.
 ModuleName getModuleName()
           
 IvyModuleSet getParent()
           
 String getPronoun()
           
 hudson.util.DescribableList<hudson.tasks.Publisher,hudson.model.Descriptor<hudson.tasks.Publisher>> getPublishers()
          List of active Publishers configured for this module.
 hudson.util.DescribableList<hudson.tasks.Publisher,hudson.model.Descriptor<hudson.tasks.Publisher>> getPublishersList()
           
 String getRelativePath()
          Relative path to this module's root directory from the workspace of a IvyModuleSet.
 String getRelativePathToDescriptorFromModuleRoot()
           
 String getRelativePathToModuleRoot()
           
 String getRevision()
          Gets the revision number in the ivy.xml file as of the last build.
 String getShortUrl()
           
 String getTargets()
          Gets the list of targets to execute for this module.
 String getUserConfiguredRelativePathToDescriptorFromModuleRoot()
           
 hudson.model.Resource getWorkspaceResource()
          Deprecated. as of 1.319 in AbstractProject.
 boolean isBuildable()
           
 boolean isFingerprintConfigured()
           
 boolean isNameEditable()
           
 boolean isUseUpstreamParameters()
           
protected  IvyBuild newBuild()
           
 void onLoad(hudson.model.ItemGroup<? extends hudson.model.Item> parent, String name)
           
protected  void performDelete()
           
 void setLogRotator(hudson.tasks.LogRotator logRotator)
          Deprecated. Not allowed to configure log rotation per module.
protected  void submit(org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp)
           
 boolean supportsLogRotator()
           
protected  void updateTransientActions()
           
 
Methods inherited from class hudson.ivy.AbstractIvyProject
createTransientActions, scheduleBuild
 
Methods inherited from class hudson.model.AbstractProject
_getRuns, addProperty, addToList, addTrigger, blockBuildWhenDownstreamBuilding, blockBuildWhenUpstreamBuilding, buildDescribable, buildDescribable, buildProjectProperties, buildTriggers, checkAbortPermission, checkout, cleanWorkspace, createExecutable, createHistoryWidget, disable, doBuild, doBuildWithParameters, doCancelQueue, doCheckRetryCount, doConfigSubmit, doDisable, doDoWipeOutWorkspace, doEnable, doPolling, doRssChangelog, doWs, enable, findNearest, getActions, getAppointedNode, getAssignedLabelString, getAuthToken, getBuildingDownstream, getBuildingUpstream, getBuildTriggerUpstreamProjects, getDelay, getDownstreamProjects, getHasCustomQuietPeriod, getIconColor, getJDKName, getLastBuiltOn, getModuleRoot, getModuleRoots, getOwnerTask, getProminentActions, getQueueItem, getQuietPeriod, getRelationship, getResourceActivities, getResourceList, getRootProject, getSameNodeConstraint, getScm, getScmCheckoutRetryCount, getSomeBuildWithWorkspace, getSomeWorkspace, getSubTasks, getTransitiveDownstreamProjects, getTransitiveUpstreamProjects, getTrigger, getTriggerDescribableList, getTriggers, getTriggersList, getUpstreamProjects, getWhyBlocked, getWorkspace, hasAbortPermission, hasCustomScmCheckoutRetryCount, hasParticipant, isAdvancedAffinityChooser, isBuildBlocked, isCleanWorkspaceRequired, isConcurrentBuild, isConfigurable, isDisabled, isInQueue, isParameterized, loadBuild, makeDisabled, makeSearchIndex, onCreatedFromScratch, poll, pollSCMChanges, removeFromList, removeRun, removeTrigger, resolveForCLI, scheduleBuild, scheduleBuild, scheduleBuild, scheduleBuild, scheduleBuild2, scheduleBuild2, scheduleBuild2, scheduleBuild2, schedulePolling, setAdvancedAffinityChooser, setAppointedNode, setAssignedLabel, setAssignedNode, setBlockBuildWhenDownstreamBuilding, setBlockBuildWhenUpstreamBuilding, setCleanWorkspaceRequired, setConcurrentBuild, setJDK, setJDK, setQuietPeriod, setQuietPeriod, setScm, setScmCheckoutRetryCount, setScmCheckoutRetryCount, setTriggers
 
Methods inherited from class hudson.model.Job
addCascadingChild, assignBuildNumber, doBuildStatus, doDescription, doDoRename, doModifyCascadingProperty, doResetProjectProperty, doRssAll, doRssFailed, doUpdateCascadingProject, getACL, getAllJobs, getAllProperties, getBuild, getBuildByNumber, getBuildDir, getBuildForCLI, getBuildHealth, getBuildHealthReports, getBuilds, getBuilds, getBuildsAsMap, getBuildsByTimestamp, getBuildStatusUrl, getBuildTimeGraph, getCascadingChildrenNames, getCascadingProject, getCascadingProjectName, getCreatedBy, getCreationTime, getDynamic, getEstimatedDuration, getFirstBuild, getLastBuild, getLastBuildsOverThreshold, getLastCompletedBuild, getLastFailedBuild, getLastStableBuild, getLastSuccessfulBuild, getLastUnstableBuild, getLastUnsuccessfulBuild, getNearestBuild, getNearestOldBuild, getNextBuildNumber, getOverrides, getPermalinks, getProjectProperties, getProperties, getProperty, getProperty, getProperty, getTimeline, getWidgets, grantProjectMatrixPermissions, hasCascadingChild, hasCascadingProject, initAllowSave, initProjectProperties, isAllowSave, isBuilding, isHoldOffBuildUntilSave, isKeepDependencies, logRotate, onCopiedFrom, performBeforeItemRenaming, putAllProjectProperties, putProjectProperty, removeCascadingChild, removeProjectProperty, removeProperty, removeProperty, renameCascadingChildName, renameCascadingProjectNameTo, renameTo, save, saveNextBuildNumber, setAllowSave, setCascadingProjectName, setCreatedBy, setCreationTime, updateNextBuildNumber
 
Methods inherited from class hudson.model.AbstractItem
checkPermission, delete, delete, doConfigDotXml, doDoDelete, doSubmitDescription, getAbsoluteUrl, getApi, getConfigFile, getDescription, getDescriptorByName, getFullDisplayName, getFullName, getName, getRootDir, getSearchUrl, getUrl, hasPermission, setDescription, toString
 
Methods inherited from class hudson.model.Actionable
addAction, getAction, getAction, getActions
 
Methods inherited from class hudson.model.AbstractModelObject
getConfiguredHudsonProperty, getSearch, getSearchIndex, getSearchName, requirePOST, sendError, sendError, sendError, sendError, sendError
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface hudson.model.Saveable
save
 
Methods inherited from interface hudson.model.Queue.Task
getFullDisplayName, getName, getUrl
 
Methods inherited from interface hudson.model.queue.SubTask
getEstimatedDuration
 
Methods inherited from interface org.eclipse.hudson.api.model.IJob
assignBuildNumber, getAllProperties, getBuildByNumber, getBuildHealth, getBuildHealthReports, getBuilds, getBuilds, getBuildsAsMap, getBuildStatusUrl, getBuildTimeGraph, getCreatedBy, getCreationTime, getFirstBuild, getLastBuild, getLastBuildsOverThreshold, getLastCompletedBuild, getLastFailedBuild, getLastStableBuild, getLastSuccessfulBuild, getLastUnstableBuild, getLastUnsuccessfulBuild, getNearestBuild, getNearestOldBuild, getNextBuildNumber, getPermalinks, getProperties, getTimeline, getWidgets, isBuilding, isKeepDependencies, logRotate, updateNextBuildNumber
 
Methods inherited from interface hudson.model.Item
delete, getAbsoluteUrl, getAllJobs, getFullDisplayName, getFullName, getName, getUrl, onCopiedFrom, save
 
Methods inherited from interface hudson.model.PersistenceRoot
getRootDir
 
Methods inherited from interface hudson.search.SearchableModelObject
getSearch
 
Methods inherited from interface hudson.search.SearchItem
getSearchIndex, getSearchName, getSearchUrl
 
Methods inherited from interface hudson.security.AccessControlled
checkPermission, getACL, hasPermission
 

Method Detail

getBuildWrappersList

public hudson.util.DescribableList<hudson.tasks.BuildWrapper,hudson.model.Descriptor<hudson.tasks.BuildWrapper>> getBuildWrappersList()

getLogRotator

public hudson.tasks.LogRotator getLogRotator()
IvyModule follows the same log rotation schedule as its parent.

Specified by:
getLogRotator in interface org.eclipse.hudson.api.model.IJob
Overrides:
getLogRotator in class hudson.model.Job<IvyModule,IvyBuild>

setLogRotator

@Deprecated
public void setLogRotator(hudson.tasks.LogRotator logRotator)
Deprecated. Not allowed to configure log rotation per module.

Specified by:
setLogRotator in interface org.eclipse.hudson.api.model.IJob
Overrides:
setLogRotator in class hudson.model.Job<IvyModule,IvyBuild>

supportsLogRotator

public boolean supportsLogRotator()
Specified by:
supportsLogRotator in interface org.eclipse.hudson.api.model.IJob
Overrides:
supportsLogRotator in class hudson.model.Job<IvyModule,IvyBuild>

isBuildable

public boolean isBuildable()
Specified by:
isBuildable in interface org.eclipse.hudson.api.model.IJob
Overrides:
isBuildable in class hudson.model.AbstractProject<IvyModule,IvyBuild>

doSetName

protected void doSetName(String name)
Overrides:
doSetName in class hudson.model.AbstractItem

onLoad

public void onLoad(hudson.model.ItemGroup<? extends hudson.model.Item> parent,
                   String name)
            throws IOException
Specified by:
onLoad in interface hudson.model.Item
Overrides:
onLoad in class hudson.model.AbstractProject<IvyModule,IvyBuild>
Throws:
IOException

getRelativePath

public String getRelativePath()
Relative path to this module's root directory from the workspace of a IvyModuleSet. The path separator is normalized to '/'.


getRevision

public String getRevision()
Gets the revision number in the ivy.xml file as of the last build.

Returns:
This method can return null if Hudson loaded old data that didn't record this information, so that situation needs to be handled gracefully.

getIvyBranch

public String getIvyBranch()
Gets the Ivy branch in the ivy.xml file as of the last build.

Returns:
This method can return null if Hudson loaded old data that didn't record this information, so that situation needs to be handled gracefully.

getTargets

public String getTargets()
Gets the list of targets to execute for this module.


getRelativePathToDescriptorFromModuleRoot

public String getRelativePathToDescriptorFromModuleRoot()

getUserConfiguredRelativePathToDescriptorFromModuleRoot

public String getUserConfiguredRelativePathToDescriptorFromModuleRoot()

getRelativePathToModuleRoot

public String getRelativePathToModuleRoot()

getPublishersList

public hudson.util.DescribableList<hudson.tasks.Publisher,hudson.model.Descriptor<hudson.tasks.Publisher>> getPublishersList()
Specified by:
getPublishersList in class hudson.model.AbstractProject<IvyModule,IvyBuild>

getJDK

public hudson.model.JDK getJDK()
Specified by:
getJDK in interface org.eclipse.hudson.api.model.IAbstractProject
Overrides:
getJDK in class hudson.model.AbstractProject<IvyModule,IvyBuild>

getBuildClass

protected Class<IvyBuild> getBuildClass()
Specified by:
getBuildClass in class hudson.model.AbstractProject<IvyModule,IvyBuild>

newBuild

protected IvyBuild newBuild()
                     throws IOException
Overrides:
newBuild in class hudson.model.AbstractProject<IvyModule,IvyBuild>
Throws:
IOException

getModuleName

public ModuleName getModuleName()

asDependency

public ModuleDependency asDependency()
Gets organisation+name+revision as ModuleDependency.


getShortUrl

public String getShortUrl()
Specified by:
getShortUrl in interface hudson.model.Item
Overrides:
getShortUrl in class hudson.model.AbstractItem

getDisplayName

@Exported(visibility=2)
public String getDisplayName()
Specified by:
getDisplayName in interface hudson.model.Item
Specified by:
getDisplayName in interface hudson.model.ModelObject
Specified by:
getDisplayName in interface hudson.model.ResourceActivity
Overrides:
getDisplayName in class hudson.model.AbstractItem

getPronoun

public String getPronoun()
Overrides:
getPronoun in class hudson.model.AbstractProject<IvyModule,IvyBuild>

isNameEditable

public boolean isNameEditable()
Specified by:
isNameEditable in interface org.eclipse.hudson.api.model.IJob
Overrides:
isNameEditable in class hudson.model.Job<IvyModule,IvyBuild>

getParent

public IvyModuleSet getParent()
Specified by:
getParent in interface hudson.model.Item
Overrides:
getParent in class hudson.model.AbstractItem

getAssignedLabel

public hudson.model.Label getAssignedLabel()
IvyModule uses the workspace of the IvyModuleSet, so it always needs to be built on the same slave as the parent.

Specified by:
getAssignedLabel in interface hudson.model.queue.SubTask
Specified by:
getAssignedLabel in interface org.eclipse.hudson.api.model.IAbstractProject
Overrides:
getAssignedLabel in class hudson.model.AbstractProject<IvyModule,IvyBuild>

getWorkspaceResource

@Deprecated
public hudson.model.Resource getWorkspaceResource()
Deprecated. as of 1.319 in AbstractProject.

Workspace of a IvyModule is a part of the parent's workspace.

That is, builds are incompatible with any IvyModule builds, whereas IvyModule builds are compatible with each other.

Overrides:
getWorkspaceResource in class hudson.model.AbstractProject<IvyModule,IvyBuild>

isFingerprintConfigured

public boolean isFingerprintConfigured()
Specified by:
isFingerprintConfigured in class hudson.model.AbstractProject<IvyModule,IvyBuild>

updateTransientActions

protected void updateTransientActions()
Overrides:
updateTransientActions in class hudson.model.AbstractProject<IvyModule,IvyBuild>

buildDependencyGraph

protected void buildDependencyGraph(hudson.model.DependencyGraph graph)
Specified by:
buildDependencyGraph in class hudson.model.AbstractProject<IvyModule,IvyBuild>

getAllIvyModules

protected Collection<IvyModule> getAllIvyModules()
Returns all Ivy modules in this Jenkins instance.


getCauseOfBlockage

public hudson.model.queue.CauseOfBlockage getCauseOfBlockage()
Specified by:
getCauseOfBlockage in interface hudson.model.Queue.Task
Overrides:
getCauseOfBlockage in class hudson.model.AbstractProject<IvyModule,IvyBuild>

addTransientActionsFromBuild

protected void addTransientActionsFromBuild(IvyBuild build,
                                            List<hudson.model.Action> collection,
                                            Set<Class> added)
Specified by:
addTransientActionsFromBuild in class AbstractIvyProject<IvyModule,IvyBuild>
collection - Add the transient actions to this collection.

getPublishers

public hudson.util.DescribableList<hudson.tasks.Publisher,hudson.model.Descriptor<hudson.tasks.Publisher>> getPublishers()
List of active Publishers configured for this module.


submit

protected void submit(org.kohsuke.stapler.StaplerRequest req,
                      org.kohsuke.stapler.StaplerResponse rsp)
               throws IOException,
                      javax.servlet.ServletException,
                      hudson.model.Descriptor.FormException
Overrides:
submit in class hudson.model.AbstractProject<IvyModule,IvyBuild>
Throws:
IOException
javax.servlet.ServletException
hudson.model.Descriptor.FormException

performDelete

protected void performDelete()
                      throws IOException,
                             InterruptedException
Overrides:
performDelete in class hudson.model.AbstractProject<IvyModule,IvyBuild>
Throws:
IOException
InterruptedException

createModulePublishers

protected final List<hudson.tasks.Publisher> createModulePublishers()
Creates a list of Publishers to be used for a build of this project.


isUseUpstreamParameters

public boolean isUseUpstreamParameters()
Specified by:
isUseUpstreamParameters in class AbstractIvyProject<IvyModule,IvyBuild>


Copyright © 2004-2012 Hudson. All Rights Reserved.