Interface ArtifactRepository


public interface ArtifactRepository
Represents a remote repository instance. The DeploymentSynchronizer interacts with the remote repository through this interface.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    checkout(int tenantId, String filePath)
    Checkout all or updated artifacts from the remote repository to the local file system
    boolean
    checkout(int tenantId, String filePath, int depth)
    Deprecated.
    void
    Clean up any actions taken during initializing auto checkout
    void
    cleanupTenantContext(int tenantId)
    Cleanup the cached tenant context for the tenant specified by tenantId
    boolean
    commit(int tenantId, String filePath)
    Commit the artifacts in the local repository to the remote repository
    Get the list of configuration parameters specific for each Repository.
    Get the Repository Type of the Synchronizer
    void
    init(int tenantId)
    Initializes the remote artifact repository and prepare to synchronize the local repository against it.
    void
    initAutoCheckout(boolean useEventing)
    Setup the remote repository for auto checkouts
    boolean
    update(int tenantId, String rootPath, String filePathToUpdate, int depth)
    Deprecated.
  • Method Details

    • init

      void init(int tenantId) throws DeploymentSynchronizerException
      Initializes the remote artifact repository and prepare to synchronize the local repository against it.
      Parameters:
      tenantId - ID of the tenant to which the synchronizer/repository belongs
      Throws:
      DeploymentSynchronizerException - If an error occurs while initializing the repository
    • commit

      boolean commit(int tenantId, String filePath) throws DeploymentSynchronizerException
      Commit the artifacts in the local repository to the remote repository
      Parameters:
      tenantId - tenant Id
      filePath - File path of the local repository
      Returns:
      true if file changes were committed, false otherwise
      Throws:
      DeploymentSynchronizerException - on error
    • checkout

      boolean checkout(int tenantId, String filePath) throws DeploymentSynchronizerException
      Checkout all or updated artifacts from the remote repository to the local file system
      Parameters:
      tenantId - tenant Id
      filePath - File path of the local repository
      Returns:
      true if files were checked out or updated, false otherwise
      Throws:
      DeploymentSynchronizerException - on error
    • initAutoCheckout

      void initAutoCheckout(boolean useEventing) throws DeploymentSynchronizerException
      Setup the remote repository for auto checkouts
      Parameters:
      useEventing - If eventing based auto checkout has been requested
      Throws:
      DeploymentSynchronizerException - on error
    • cleanupAutoCheckout

      void cleanupAutoCheckout()
      Clean up any actions taken during initializing auto checkout
    • getRepositoryType

      String getRepositoryType()
      Get the Repository Type of the Synchronizer
      Returns:
      The Repository Type
    • getParameters

      Get the list of configuration parameters specific for each Repository.
      Returns:
      List of RepositoryConfigParameters
    • checkout

      @Deprecated boolean checkout(int tenantId, String filePath, int depth) throws DeploymentSynchronizerException
      Deprecated.
      This method is deprecated. This was introduced to enable partial update. That feature has been removed. Users should use checkout(int, String) method.
      Throws:
      DeploymentSynchronizerException
    • update

      @Deprecated boolean update(int tenantId, String rootPath, String filePathToUpdate, int depth) throws DeploymentSynchronizerException
      Deprecated.
      This method is deprecated. Refer checkout(int, String, int) for more information.
      Throws:
      DeploymentSynchronizerException
    • cleanupTenantContext

      void cleanupTenantContext(int tenantId)
      Cleanup the cached tenant context for the tenant specified by tenantId
      Parameters:
      tenantId - tenant Id