完成品牌部分改造

This commit is contained in:
super
2026-03-24 22:22:37 +08:00
parent 7ffe5279a3
commit 2cd0fcff93
37 changed files with 2086 additions and 11 deletions

View File

@@ -0,0 +1,13 @@
package com.nanri.aiimage.config;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
@Data
@ConfigurationProperties(prefix = "aiimage.brand-progress")
public class BrandProgressProperties {
private long ttlHours = 24;
private long failedTtlHours = 2;
private long heartbeatTimeoutMinutes = 15;
private String staleCheckCron = "0 */2 * * * *";
}

View File

@@ -4,6 +4,6 @@ import org.springframework.boot.context.properties.EnableConfigurationProperties
import org.springframework.context.annotation.Configuration;
@Configuration
@EnableConfigurationProperties({OssProperties.class, StorageProperties.class})
@EnableConfigurationProperties({OssProperties.class, StorageProperties.class, BrandProgressProperties.class})
public class PropertiesConfig {
}

View File

@@ -7,4 +7,8 @@ import org.springframework.boot.context.properties.ConfigurationProperties;
@ConfigurationProperties(prefix = "aiimage.storage")
public class StorageProperties {
private String localTempDir;
private boolean cleanupEnabled = true;
private String cleanupCron = "0 0 */6 * * *";
private long sourceRetentionHours = 48;
private long resultRetentionHours = 24;
}