Package com.atlassian.bamboo.repository
Interface CachedRepositoryDefinitionAccessor
-
- All Known Subinterfaces:
CachedRepositoryDefinitionManager
,PermissionFilteringRepositoryDefinitionAccessor
- All Known Implementing Classes:
PermissionFilteringRepositoryDefinitionAccessorImpl
@Internal public interface CachedRepositoryDefinitionAccessor
Caching repository definition manager. As a rule, repositories that are marked for deletion are not included in returned collections but are accessible by id.- Since:
- 7.1
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description @NotNull Set<Long>
findAllTopLevelRepositoriesIds()
List ids of all top level repositories.@Nullable VcsRepositoryData
findLinkedRepositoryByName(@NotNull String name)
@Nullable VcsRepositoryData
findProjectRepositoryByName(@NotNull String name, @NotNull Long projectId)
@NotNull List<VcsRepositoryData>
findRepositoriesByProjectId(Long projectId)
Get list of all project repositories current user has permission to use in their plans.@NotNull List<VcsRepositoryData>
getAllTopLevelRepositories()
Get the list of all top level repositories that are not marked for deletion.@NotNull List<VcsRepositoryData>
getLinkedRepositories()
Get all linked repositories current user has permission to use in their plans.List<VcsRepositoryData>
getLinkedRepositoriesForAdministration()
Get all Shared repositories current user has permission to administrate.@NotNull List<VcsRepositoryData>
getVcsRepositoriesDataWithConsistencyGuarantee(@NotNull List<Long> repositoryIds)
Returns a list of cached repositories if they exist with the given ids.@Nullable VcsRepositoryData
getVcsRepositoryData(long repositoryId)
Returns a cached repository if one exists with the given id.@Nullable VcsRepositoryData
getVcsRepositoryDataWithConsistencyGuarantee(long repositoryId)
Returns a cached repository if one exists with the given id.
-
-
-
Method Detail
-
getVcsRepositoryData
@Nullable @Nullable VcsRepositoryData getVcsRepositoryData(long repositoryId)
Returns a cached repository if one exists with the given id. In clustered mode, there is NO consistency guarantee.- Parameters:
repositoryId
- unique identifier of the repository- Returns:
- cached repository object or null if one does not exist
-
getVcsRepositoryDataWithConsistencyGuarantee
@Nullable @Nullable VcsRepositoryData getVcsRepositoryDataWithConsistencyGuarantee(long repositoryId)
Returns a cached repository if one exists with the given id. There is a guarantee that the data will be up-to-date.- Parameters:
repositoryId
- unique identifier of the repository- Returns:
- cached repository object or null if one does not exist
- Since:
- 9.4
-
getVcsRepositoriesDataWithConsistencyGuarantee
@NotNull @NotNull List<VcsRepositoryData> getVcsRepositoriesDataWithConsistencyGuarantee(@NotNull @NotNull List<Long> repositoryIds)
Returns a list of cached repositories if they exist with the given ids. There is a guarantee that the data will be up-to-date.- Parameters:
repositoryIds
- unique identifiers of the repositories- Returns:
- cached repository objects or empty list if none exist
- Since:
- 9.4
-
findLinkedRepositoryByName
@Nullable @Nullable VcsRepositoryData findLinkedRepositoryByName(@NotNull @NotNull String name)
-
getLinkedRepositoriesForAdministration
List<VcsRepositoryData> getLinkedRepositoriesForAdministration()
Get all Shared repositories current user has permission to administrate.
-
getLinkedRepositories
@NotNull @NotNull List<VcsRepositoryData> getLinkedRepositories()
Get all linked repositories current user has permission to use in their plans.
-
findRepositoriesByProjectId
@NotNull @NotNull List<VcsRepositoryData> findRepositoriesByProjectId(Long projectId)
Get list of all project repositories current user has permission to use in their plans.
-
findProjectRepositoryByName
@Nullable @Nullable VcsRepositoryData findProjectRepositoryByName(@NotNull @NotNull String name, @NotNull @NotNull Long projectId)
- Parameters:
name
- - repository name.projectId
- - project id in which repository should be.- Returns:
- VcsRepositoryData if repository exists, otherwise null.
-
findAllTopLevelRepositoriesIds
@NotNull @NotNull Set<Long> findAllTopLevelRepositoriesIds()
List ids of all top level repositories.- Since:
- 8.1
-
getAllTopLevelRepositories
@NotNull @NotNull List<VcsRepositoryData> getAllTopLevelRepositories()
Get the list of all top level repositories that are not marked for deletion.- Since:
- 9.0
-
-