Class InternalErrorsHandler
- java.lang.Object
-
- jetbrains.buildServer.serverSide.impl.InternalErrorsHandler
-
public class InternalErrorsHandler extends Object
Responsible for monitoring internal errors. Integrates to theSystemProblemNotificationcomponent.Note: currently only the errors of the last problematic build are stored. E.g. if there is a sequence of failing builds:
- build #1 fails with checkout error
- build #2 fails with apply patch error
- build #3 fails with artifact dependency error
The problems are not persisted anywhere, but restored from build history on startup.
Thread safe.
Internal errors are tracked per branch since 7.1.1 (see TW-22634).
- Since:
- 6.0
- Author:
- Maxim Podkolzine (maxim.podkolzine@jetbrains.com)
-
-
Field Summary
Fields Modifier and Type Field Description static StringPROBLEM_DESCRIPTIONstatic StringPROBLEM_TYPE
-
Constructor Summary
Constructors Constructor Description InternalErrorsHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclearPotentialProblems(SBuild build)Removes "internal error" problems that were potentially raised for a build configuration.SBuildgetBuildFromProblem(SystemProblem problem)voidinit()voidraiseProblemForBuild(SBuild build, String description, String cause)Raises the problem of a build.voidraiseProblemForBuild(SBuild build, ErrorData errorData)Raises the problem of a build.voidsetBuildsManager(BuildsManager buildsManager)voidsetDispatcher(EventDispatcher<BuildServerListener> dispatcher)voidsetExecutorServices(ExecutorServices executors)voidsetProjectManager(ProjectManager projectManager)voidsetSystemProblems(SystemProblemNotification systemProblems)
-
-
-
Field Detail
-
PROBLEM_TYPE
public static final String PROBLEM_TYPE
- See Also:
- Constant Field Values
-
PROBLEM_DESCRIPTION
public static final String PROBLEM_DESCRIPTION
- See Also:
- Constant Field Values
-
-
Method Detail
-
setDispatcher
public void setDispatcher(@NotNull EventDispatcher<BuildServerListener> dispatcher)
-
setProjectManager
public void setProjectManager(@NotNull ProjectManager projectManager)
-
setSystemProblems
public void setSystemProblems(@NotNull SystemProblemNotification systemProblems)
-
setBuildsManager
public void setBuildsManager(@NotNull BuildsManager buildsManager)
-
setExecutorServices
public void setExecutorServices(@NotNull ExecutorServices executors)
-
init
public void init()
-
raiseProblemForBuild
public void raiseProblemForBuild(@NotNull SBuild build, @Nullable ErrorData errorData)Raises the problem of a build.- Parameters:
build- the build in which an internal error occurred
-
raiseProblemForBuild
public void raiseProblemForBuild(@NotNull SBuild build, @Nullable String description, @Nullable String cause)Raises the problem of a build.- Parameters:
build- the build in which an internal error occurrederrorData-
-
clearPotentialProblems
public void clearPotentialProblems(@NotNull SBuild build)Removes "internal error" problems that were potentially raised for a build configuration. Problems reported by this build (if any) are sustained.- Parameters:
build- the build that successfully passed preparation stage
-
getBuildFromProblem
@Nullable public SBuild getBuildFromProblem(@NotNull SystemProblem problem)
-
-