mirror of
https://github.com/corda/corda.git
synced 2025-01-29 15:43:55 +00:00
ENT-3496 Create log directory to place dumps if it does not already exist
This commit is contained in:
parent
684e9cdf58
commit
d8395baf62
@ -89,6 +89,7 @@ class CheckpointDumper(private val checkpointStorage: CheckpointStorage, private
|
||||
try {
|
||||
val file = serviceHub.configuration.baseDirectory / "logs" / "checkpoints_dump-${TIME_FORMATTER.format(serviceHub.clock.instant())}.zip"
|
||||
if (lock.getAndIncrement() == 0 && !file.exists()) {
|
||||
file.parent.toFile().mkdirs()
|
||||
database.transaction {
|
||||
checkpointStorage.getAllCheckpoints().use { stream ->
|
||||
ZipOutputStream(file.outputStream()).use { zip ->
|
||||
|
Loading…
x
Reference in New Issue
Block a user