Class RepositoryStoredSpecsLogServiceImpl
- java.lang.Object
-
- com.atlassian.bamboo.configuration.external.RepositoryStoredSpecsLogServiceImpl
-
- All Implemented Interfaces:
RepositoryStoredSpecsLogService
public class RepositoryStoredSpecsLogServiceImpl extends Object implements RepositoryStoredSpecsLogService
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.atlassian.bamboo.configuration.external.RepositoryStoredSpecsLogService
RepositoryStoredSpecsLogService.RepositoryStoredSpecsLogAccessor
-
-
Constructor Summary
Constructors Constructor Description RepositoryStoredSpecsLogServiceImpl(BootstrapManager bootstrapManager, ResultsSummaryManager resultsManager, BambooSpecsStateDao bambooSpecsStateDao)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Path
createBambooSpecLogFile(long repositoryId, @NotNull String logFilename)
Create log file for Bamboo Specs execution.@NotNull String
generateFileName(@NotNull List<? extends CommitContext> commits)
Generate log file nameString
generateSpecsLogsUrl(long repositoryId, @NotNull String logFilename, @Nullable String referrer)
@Nullable RepositoryStoredSpecsLogService.RepositoryStoredSpecsLogAccessor
getBambooSpecsExecutionLogAccessor(@NotNull PlanResultKey planResultKey)
Provides log file accessor for build result.@Nullable Path
getBambooSpecsExecutionLogFile(long repositoryId, @NotNull String changesetId)
@Nullable Path
getBambooSpecsExecutionLogFile(@NotNull PlanResultKey planResultKey)
@Nullable Path
getBambooSpecsExecutionLogFile(@NotNull VcsLocationBambooSpecsState specsState)
@NotNull String
getChangeSetForFilename(@NotNull List<? extends CommitContext> commits)
-
-
-
Constructor Detail
-
RepositoryStoredSpecsLogServiceImpl
public RepositoryStoredSpecsLogServiceImpl(BootstrapManager bootstrapManager, ResultsSummaryManager resultsManager, BambooSpecsStateDao bambooSpecsStateDao)
-
-
Method Detail
-
createBambooSpecLogFile
public Path createBambooSpecLogFile(long repositoryId, @NotNull @NotNull String logFilename)
Description copied from interface:RepositoryStoredSpecsLogService
Create log file for Bamboo Specs execution.- Specified by:
createBambooSpecLogFile
in interfaceRepositoryStoredSpecsLogService
- Parameters:
repositoryId
- root repository idlogFilename
- log file name
-
getBambooSpecsExecutionLogAccessor
@Nullable public @Nullable RepositoryStoredSpecsLogService.RepositoryStoredSpecsLogAccessor getBambooSpecsExecutionLogAccessor(@NotNull @NotNull PlanResultKey planResultKey) throws IllegalStateException
Description copied from interface:RepositoryStoredSpecsLogService
Provides log file accessor for build result.- Specified by:
getBambooSpecsExecutionLogAccessor
in interfaceRepositoryStoredSpecsLogService
- Parameters:
planResultKey
- result key- Returns:
- file accessor if result key is linked to Bamboo Specs execution.
- Throws:
IllegalStateException
-
getBambooSpecsExecutionLogFile
@Nullable public @Nullable Path getBambooSpecsExecutionLogFile(@NotNull @NotNull PlanResultKey planResultKey)
- Specified by:
getBambooSpecsExecutionLogFile
in interfaceRepositoryStoredSpecsLogService
- Parameters:
planResultKey
- result key- Returns:
- log file if result key is linked to Bamboo Specs execution
-
getBambooSpecsExecutionLogFile
@Nullable public @Nullable Path getBambooSpecsExecutionLogFile(long repositoryId, @NotNull @NotNull String changesetId)
- Specified by:
getBambooSpecsExecutionLogFile
in interfaceRepositoryStoredSpecsLogService
- Parameters:
repositoryId
- id of Bamboo repositorychangesetId
- changeset id- Returns:
- log file if the changeset in the repository is linked to Bamboo Specs execution failure
-
getBambooSpecsExecutionLogFile
@Nullable public @Nullable Path getBambooSpecsExecutionLogFile(@NotNull @NotNull VcsLocationBambooSpecsState specsState)
- Specified by:
getBambooSpecsExecutionLogFile
in interfaceRepositoryStoredSpecsLogService
- Returns:
- log file
-
generateFileName
@NotNull public @NotNull String generateFileName(@NotNull @NotNull List<? extends CommitContext> commits)
Description copied from interface:RepositoryStoredSpecsLogService
Generate log file name- Specified by:
generateFileName
in interfaceRepositoryStoredSpecsLogService
- Parameters:
commits
- associated with Bamboo Specs processing- Returns:
-
getChangeSetForFilename
@NotNull public @NotNull String getChangeSetForFilename(@NotNull @NotNull List<? extends CommitContext> commits)
- Specified by:
getChangeSetForFilename
in interfaceRepositoryStoredSpecsLogService
- Returns:
- commit which might be used for log filename.
-
generateSpecsLogsUrl
public String generateSpecsLogsUrl(long repositoryId, @NotNull @NotNull String logFilename, @Nullable @Nullable String referrer)
- Specified by:
generateSpecsLogsUrl
in interfaceRepositoryStoredSpecsLogService
- Returns:
- relative URL for Bamboo Specs execution log file
-
-