public class GitBasedArtifactRepository extends Object implements org.wso2.carbon.deployment.synchronizer.ArtifactRepository
Constructor and Description |
---|
GitBasedArtifactRepository() |
Modifier and Type | Method and Description |
---|---|
boolean |
checkout(int tenantId,
String localRepoPath)
Method inherited from ArtifactRepository for initializing checkout
|
boolean |
checkout(int tenantId,
String filePath,
int depth)
Partial checkout with defined depth.
|
void |
cleanupAutoCheckout() |
void |
cleanupTenantContext(int tenantId)
removed tenant's information from the cache
|
boolean |
commit(int tenantId,
String localRepoPath)
Commits any changes in the local repository to the relevant remote repository
|
List<org.wso2.carbon.deployment.synchronizer.util.RepositoryConfigParameter> |
getParameters() |
String |
getRepositoryType()
Return the repository type
|
void |
init(int tenantId)
Called at tenant load to do initialization related to the tenant
|
void |
initAutoCheckout(boolean b) |
boolean |
update(int tenantId,
String rootPath,
String filePath,
int depth)
Partial update with defined depth.Currently not supported in GIT.
|
public void init(int tenantId) throws org.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
init
in interface org.wso2.carbon.deployment.synchronizer.ArtifactRepository
tenantId
- id of the tenantorg.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
- in case of an errorpublic boolean commit(int tenantId, String localRepoPath) throws org.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
commit
in interface org.wso2.carbon.deployment.synchronizer.ArtifactRepository
localRepoPath
- tenant's local repository pathorg.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
- in case of an errorpublic boolean checkout(int tenantId, String localRepoPath) throws org.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
checkout
in interface org.wso2.carbon.deployment.synchronizer.ArtifactRepository
localRepoPath
- local repository path of the tenantorg.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
- if an error occurspublic void initAutoCheckout(boolean b) throws org.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
initAutoCheckout
in interface org.wso2.carbon.deployment.synchronizer.ArtifactRepository
org.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
public void cleanupAutoCheckout()
cleanupAutoCheckout
in interface org.wso2.carbon.deployment.synchronizer.ArtifactRepository
public String getRepositoryType()
getRepositoryType
in interface org.wso2.carbon.deployment.synchronizer.ArtifactRepository
public List<org.wso2.carbon.deployment.synchronizer.util.RepositoryConfigParameter> getParameters()
getParameters
in interface org.wso2.carbon.deployment.synchronizer.ArtifactRepository
public boolean checkout(int tenantId, String filePath, int depth) throws org.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
checkout
in interface org.wso2.carbon.deployment.synchronizer.ArtifactRepository
tenantId
- tenant idfilePath
- local repository pathdepth
- depth to checkout (0 - 3)org.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
- if an error occurspublic boolean update(int tenantId, String rootPath, String filePath, int depth) throws org.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
update
in interface org.wso2.carbon.deployment.synchronizer.ArtifactRepository
tenantId
- tenant IdrootPath
- root path to the local repositoryfilePath
- path to sub directory to updatedepth
- depth to update (0 - 3)org.wso2.carbon.deployment.synchronizer.DeploymentSynchronizerException
- if an error occurspublic void cleanupTenantContext(int tenantId)
cleanupTenantContext
in interface org.wso2.carbon.deployment.synchronizer.ArtifactRepository
tenantId
- tenant IdCopyright © 2019 WSO2. All rights reserved.