org.wso2.carbon.appfactory.jenkins
Class AppfactoryPluginManager

java.lang.Object
  extended by hudson.tasks.BuildStepCompatibilityLayer
      extended by hudson.tasks.Publisher
          extended by hudson.tasks.Notifier
              extended by org.wso2.carbon.appfactory.jenkins.AppfactoryPluginManager
All Implemented Interfaces:
hudson.ExtensionPoint, hudson.model.Describable<hudson.tasks.Publisher>, hudson.tasks.BuildStep, Serializable

public class AppfactoryPluginManager
extends hudson.tasks.Notifier
implements Serializable

The plugin for storing build artifact permanently, deploy artifacts and notify appfactory with build status

See Also:
Serialized Form

Nested Class Summary
static class AppfactoryPluginManager.DescriptorImpl
          Descriptor for this plugin(represents server wide configs)
 
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
 
Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS
 
Constructor Summary
AppfactoryPluginManager(String applicationId, String applicationVersion, String applicationArtifactExtension, String userName, String repositoryFrom)
           
 
Method Summary
 AppfactoryPluginManager.DescriptorImpl getDescriptor()
           
 hudson.tasks.BuildStepMonitor getRequiredMonitorService()
           
 boolean perform(hudson.model.AbstractBuild<?,?> build, hudson.Launcher launcher, hudson.model.BuildListener listener)
          When the user configures the project and enables this Notifier, when a build is performed this method will be invoked by jenkins This method is mainly used to notify appfactory regarding the build status and store the tagged artifacts by user
 void sendMessageToDeploy(String applicationId, String version, String revision, String stage, String deployAction, String tenantUserName, String repoFrom)
          Sending a request to DeployArtifact
 
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
 

Constructor Detail

AppfactoryPluginManager

@DataBoundConstructor
public AppfactoryPluginManager(String applicationId,
                                                    String applicationVersion,
                                                    String applicationArtifactExtension,
                                                    String userName,
                                                    String repositoryFrom)
Method Detail

perform

public boolean perform(hudson.model.AbstractBuild<?,?> build,
                       hudson.Launcher launcher,
                       hudson.model.BuildListener listener)
                throws InterruptedException,
                       IOException
When the user configures the project and enables this Notifier, when a build is performed this method will be invoked by jenkins This method is mainly used to notify appfactory regarding the build status and store the tagged artifacts by user

Specified by:
perform in interface hudson.tasks.BuildStep
Overrides:
perform in class hudson.tasks.BuildStepCompatibilityLayer
Parameters:
build -
launcher -
listener -
Returns:
Throws:
InterruptedException
IOException

getRequiredMonitorService

public hudson.tasks.BuildStepMonitor getRequiredMonitorService()
Specified by:
getRequiredMonitorService in interface hudson.tasks.BuildStep

getDescriptor

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

sendMessageToDeploy

public void sendMessageToDeploy(String applicationId,
                                String version,
                                String revision,
                                String stage,
                                String deployAction,
                                String tenantUserName,
                                String repoFrom)
Sending a request to DeployArtifact

Parameters:
applicationId - the application id
version - the version of the application
revision - the revision of the build
stage - stage of the application
repoFrom - TODO


Copyright © 2015 WSO2 Inc. All rights reserved.