Class AbstractBuildLog
java.lang.Object
org.springframework.boot.buildpack.platform.build.AbstractBuildLog
- All Implemented Interfaces:
BuildLog
Base class for
BuildLog
implementations.- Since:
- 2.3.0
- Author:
- Phillip Webb, Scott Frederick, Andrey Shlykov, Rafael Ceccone
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
executedLifecycle
(BuildRequest request) Log that the lifecycle has executed.void
executingLifecycle
(BuildRequest request, org.springframework.boot.buildpack.platform.build.LifecycleVersion version, Cache buildCache) Log that the lifecycle is executing.void
executingLifecycle
(BuildRequest request, org.springframework.boot.buildpack.platform.build.LifecycleVersion version, VolumeName buildCacheVolume) Log that the lifecycle is executing.void
failedCleaningWorkDir
(Cache cache, Exception exception) Log that a cache cleanup step was not completed successfully.protected abstract Consumer<TotalProgressEvent>
getProgressConsumer
(String message) protected void
log()
protected abstract void
void
pulledImage
(Image image, org.springframework.boot.buildpack.platform.build.ImageType imageType) Log that an image has been pulled.pullingImage
(ImageReference imageReference, ImagePlatform platform, org.springframework.boot.buildpack.platform.build.ImageType imageType) Log that an image is being pulled.void
pushedImage
(ImageReference imageReference) Log that an image has been pushed.pushingImage
(ImageReference imageReference) Log that an image is being pushed.runningPhase
(BuildRequest request, String name) Log that a specific phase is running.void
sensitiveTargetBindingDetected
(Binding binding) Log that a binding with a sensitive target has been detected.void
skippingPhase
(String name, String reason) Log that a specific phase is being skipped.void
start
(BuildRequest request) Log that a build is starting.void
Log that a tag has been created.
-
Constructor Details
-
AbstractBuildLog
public AbstractBuildLog()
-
-
Method Details
-
start
Description copied from interface:BuildLog
Log that a build is starting. -
pullingImage
public Consumer<TotalProgressEvent> pullingImage(ImageReference imageReference, ImagePlatform platform, org.springframework.boot.buildpack.platform.build.ImageType imageType) Description copied from interface:BuildLog
Log that an image is being pulled.- Specified by:
pullingImage
in interfaceBuildLog
- Parameters:
imageReference
- the image referenceplatform
- the platform of the imageimageType
- the image type- Returns:
- a consumer for progress update events
-
pulledImage
public void pulledImage(Image image, org.springframework.boot.buildpack.platform.build.ImageType imageType) Description copied from interface:BuildLog
Log that an image has been pulled.- Specified by:
pulledImage
in interfaceBuildLog
- Parameters:
image
- the image that was pulledimageType
- the image type that was pulled
-
pushingImage
Description copied from interface:BuildLog
Log that an image is being pushed.- Specified by:
pushingImage
in interfaceBuildLog
- Parameters:
imageReference
- the image reference- Returns:
- a consumer for progress update events
-
pushedImage
Description copied from interface:BuildLog
Log that an image has been pushed.- Specified by:
pushedImage
in interfaceBuildLog
- Parameters:
imageReference
- the image reference
-
executingLifecycle
public void executingLifecycle(BuildRequest request, org.springframework.boot.buildpack.platform.build.LifecycleVersion version, VolumeName buildCacheVolume) Description copied from interface:BuildLog
Log that the lifecycle is executing.- Specified by:
executingLifecycle
in interfaceBuildLog
- Parameters:
request
- the build requestversion
- the lifecycle versionbuildCacheVolume
- the name of the build cache volume in use
-
executingLifecycle
public void executingLifecycle(BuildRequest request, org.springframework.boot.buildpack.platform.build.LifecycleVersion version, Cache buildCache) Description copied from interface:BuildLog
Log that the lifecycle is executing.- Specified by:
executingLifecycle
in interfaceBuildLog
- Parameters:
request
- the build requestversion
- the lifecycle versionbuildCache
- the build cache in use
-
runningPhase
Description copied from interface:BuildLog
Log that a specific phase is running.- Specified by:
runningPhase
in interfaceBuildLog
- Parameters:
request
- the build requestname
- the name of the phase- Returns:
- a consumer for log updates
-
skippingPhase
Description copied from interface:BuildLog
Log that a specific phase is being skipped.- Specified by:
skippingPhase
in interfaceBuildLog
- Parameters:
name
- the name of the phasereason
- the reason the phase is skipped
-
executedLifecycle
Description copied from interface:BuildLog
Log that the lifecycle has executed.- Specified by:
executedLifecycle
in interfaceBuildLog
- Parameters:
request
- the build request
-
taggedImage
Description copied from interface:BuildLog
Log that a tag has been created.- Specified by:
taggedImage
in interfaceBuildLog
- Parameters:
tag
- the tag reference
-
failedCleaningWorkDir
Description copied from interface:BuildLog
Log that a cache cleanup step was not completed successfully.- Specified by:
failedCleaningWorkDir
in interfaceBuildLog
- Parameters:
cache
- the cacheexception
- any exception that caused the failure
-
sensitiveTargetBindingDetected
Description copied from interface:BuildLog
Log that a binding with a sensitive target has been detected.- Specified by:
sensitiveTargetBindingDetected
in interfaceBuildLog
- Parameters:
binding
- the binding
-
log
protected void log() -
log
-
getProgressConsumer
-