Class RemoteBuildLogger
java.lang.Object
com.atlassian.bamboo.build.logger.AbstractBuildLogger
com.atlassian.bamboo.v2.build.agent.remote.RemoteBuildLogger
- All Implemented Interfaces:
BuildLogger
,BuildLoggerWithoutLogAccess
-
Field Summary
Fields inherited from class com.atlassian.bamboo.build.logger.AbstractBuildLogger
MAX_BUILDLOG_SIZE
-
Constructor Summary
ConstructorDescriptionRemoteBuildLogger
(File logFile, LoggerId<? extends Key> loggerId, BambooAgentMessageSender sender, ExpiryTicker expiryTicker, BuildHangingConfig buildHangingConfig) -
Method Summary
Modifier and TypeMethodDescription@NotNull String
addBuildLogEntry
(@NotNull LogEntry logEntry) Add a new build log entry.@NotNull String
addErrorLogEntry
(@NotNull LogEntry logEntry) Add a new build error log entry.boolean
void
onAddLogEntry
(@NotNull LogEntry logEntry) void
onEvent
(LogsAreWatchedAgentMessage watchedAgentMessage) void
Stop streaming any logs to the build logs fileboolean
Methods inherited from class com.atlassian.bamboo.build.logger.AbstractBuildLogger
addBuildLogEntry, addErrorLogEntry, addErrorLogEntry, addErrorLogEntryInternal, addLogEntry, close, getBuildLog, getErrorLog, getInterceptorStack, getLastNLogEntries, getLogEntryCount, getMutatorStack, getTimeOfLastLog, interceptAndMutate, interceptAndMutateError, setTimeOfLastLog
-
Constructor Details
-
RemoteBuildLogger
public RemoteBuildLogger(File logFile, LoggerId<? extends Key> loggerId, BambooAgentMessageSender sender, ExpiryTicker expiryTicker, BuildHangingConfig buildHangingConfig)
-
-
Method Details
-
onEvent
-
addBuildLogEntry
Description copied from interface:BuildLoggerWithoutLogAccess
Add a new build log entry. This will get appended to the end of the log.- Specified by:
addBuildLogEntry
in interfaceBuildLoggerWithoutLogAccess
- Overrides:
addBuildLogEntry
in classAbstractBuildLogger
- Parameters:
logEntry
- The data being logged- Returns:
- The line of text being logged. From
LogEntry.getUnstyledLog()
.
-
addErrorLogEntry
Description copied from interface:BuildLoggerWithoutLogAccess
Add a new build error log entry. This will get appended to the end of the log and to the end of the errors.- Specified by:
addErrorLogEntry
in interfaceBuildLoggerWithoutLogAccess
- Overrides:
addErrorLogEntry
in classAbstractBuildLogger
- Parameters:
logEntry
- The data being logged- Returns:
- The line of text being logged. From
LogEntry.getUnstyledLog()
.
-
onAddLogEntry
- Specified by:
onAddLogEntry
in classAbstractBuildLogger
-
stopStreamingBuildLogs
public void stopStreamingBuildLogs()Description copied from interface:BuildLoggerWithoutLogAccess
Stop streaming any logs to the build logs file- Specified by:
stopStreamingBuildLogs
in interfaceBuildLoggerWithoutLogAccess
- Specified by:
stopStreamingBuildLogs
in classAbstractBuildLogger
-
transfersLogsAsArtifact
public boolean transfersLogsAsArtifact() -
isPersistent
public boolean isPersistent()- Returns:
- true if underlying logger saves to disk
-