Class AnyVcsRepository


public final class AnyVcsRepository extends VcsRepository<AnyVcsRepository,AnyVcsRepositoryProperties>
Represents a vcs repository of any type.

Since knowledge of internal representation of plugin data is required to properly construct this object, this class should only be used if the specialised implementation of a given credential type is not available.

  • Constructor Details

    • AnyVcsRepository

      public AnyVcsRepository(AtlassianModuleProperties atlassianPlugin)
      Specifies a repository of given type.
      Parameters:
      atlassianPlugin - type of the repository identified by its plugin module key
      See Also:
    • AnyVcsRepository

      public AnyVcsRepository(AtlassianModule atlassianPlugin)
      Specifies a repository of given type.
      Parameters:
      atlassianPlugin - type of the repository identified by its plugin module key
      See Also:
  • Method Details

    • serverConfiguration

      public AnyVcsRepository serverConfiguration(@Nullable @Nullable Map<String,Object> serverConfiguration) throws PropertiesValidationException
      Sets server part of the configuration. Server configuration is mandatory if no parent is defined.

      Repository configuration in Bamboo is split into chunks that allow parts of data to be inherited (and to be overridden). Server configuration typically contains data like: url, credentials, repository name or path, advanced options nb. command timeouts, caching etc.

      The configuration should be in the format used by respective plugin. No syntactical nor semantic validation is performed on the source data. The configuration is stored 'as is' in the Bamboo DB.

      Throws:
      PropertiesValidationException
    • branchConfiguration

      public AnyVcsRepository branchConfiguration(@Nullable @Nullable Map<String,Object> branchConfiguration) throws PropertiesValidationException
      Sets branch part of the configuration. Branch configuration is mandatory for most repository types if no parent is defined.

      Repository configuration in Bamboo is split into chunks that allow parts of data to be inherited (and to be overridden). Branch configuration defines which particular branch of the repository this object represents.

      The configuration should be in the format used by respective plugin. No syntactical nor semantic validation is performed on the source data. The configuration is stored 'as is' in the Bamboo DB.

      Throws:
      PropertiesValidationException
    • branchDetectionConfiguration

      public AnyVcsRepository branchDetectionConfiguration(@Nullable @Nullable Map<String,Object> branchDetectionConfiguration) throws PropertiesValidationException
      Sets branch detection part of the configuration. Branch detection options are typically optional.

      Repository configuration in Bamboo is split into chunks that allow parts of data to be inherited (and to be overridden). Branch detection options contain configuration specific to automatic branch management in Bamboo.

      The configuration should be in the format used by respective plugin. No syntactical nor semantic validation is performed on the source data. The configuration is stored 'as is' in the Bamboo DB.

      Throws:
      PropertiesValidationException
    • changeDetectionConfiguration

      public AnyVcsRepository changeDetectionConfiguration(@Nullable @Nullable VcsChangeDetection changeDetectionConfiguration) throws PropertiesValidationException
      Sets change detection part of the configuration. These options are typically optional as Bamboo is usually able to set reasonable defaults.

      Repository configuration in Bamboo is split into chunks that allow parts of data to be inherited (and to be overridden). Change detection options contain configuration specific to change detection in Bamboo, such us commit isolation, filtering etc.

      Throws:
      PropertiesValidationException
      See Also:
    • build

      protected AnyVcsRepositoryProperties build()
      Specified by:
      build in class VcsRepository<AnyVcsRepository,AnyVcsRepositoryProperties>