From 53c315297a3906e567b01107a85836528a664206 Mon Sep 17 00:00:00 2001
From: seatonwan9
Date: 星期二, 19 八月 2025 18:11:38 +0800
Subject: [PATCH] 产品订购sql

---
 src/main/java/com/webmanage/config/AsyncExecutorProperties.java |   40 ++++++++++++++++++++++++++++++++++++++++
 1 files changed, 40 insertions(+), 0 deletions(-)

diff --git a/src/main/java/com/webmanage/config/AsyncExecutorProperties.java b/src/main/java/com/webmanage/config/AsyncExecutorProperties.java
new file mode 100644
index 0000000..4b06d45
--- /dev/null
+++ b/src/main/java/com/webmanage/config/AsyncExecutorProperties.java
@@ -0,0 +1,40 @@
+package com.webmanage.config;
+
+import org.springframework.boot.context.properties.ConfigurationProperties;
+import org.springframework.stereotype.Component;
+
+@Component
+@ConfigurationProperties(prefix = "async.executor")
+public class AsyncExecutorProperties {
+    /** 鏍稿績绾跨▼鏁� */
+    private int corePoolSize = 4;
+    /** 鏈�澶х嚎绋嬫暟 */
+    private int maxPoolSize = 8;
+    /** 闃熷垪瀹归噺 */
+    private int queueCapacity = 200;
+    /** 绾跨▼瀛樻椿鏃堕棿锛堢锛� */
+    private int keepAliveSeconds = 60;
+    /** 绾跨▼鍚嶅墠缂� */
+    private String threadNamePrefix = "async-exec-";
+    /** 鍏抽棴鏃舵槸鍚︾瓑寰呬换鍔″畬鎴� */
+    private boolean waitForTasksToCompleteOnShutdown = true;
+    /** 鍏抽棴鏃舵渶澶х瓑寰呯鏁� */
+    private int awaitTerminationSeconds = 30;
+
+    public int getCorePoolSize() { return corePoolSize; }
+    public void setCorePoolSize(int corePoolSize) { this.corePoolSize = corePoolSize; }
+    public int getMaxPoolSize() { return maxPoolSize; }
+    public void setMaxPoolSize(int maxPoolSize) { this.maxPoolSize = maxPoolSize; }
+    public int getQueueCapacity() { return queueCapacity; }
+    public void setQueueCapacity(int queueCapacity) { this.queueCapacity = queueCapacity; }
+    public int getKeepAliveSeconds() { return keepAliveSeconds; }
+    public void setKeepAliveSeconds(int keepAliveSeconds) { this.keepAliveSeconds = keepAliveSeconds; }
+    public String getThreadNamePrefix() { return threadNamePrefix; }
+    public void setThreadNamePrefix(String threadNamePrefix) { this.threadNamePrefix = threadNamePrefix; }
+    public boolean isWaitForTasksToCompleteOnShutdown() { return waitForTasksToCompleteOnShutdown; }
+    public void setWaitForTasksToCompleteOnShutdown(boolean waitForTasksToCompleteOnShutdown) { this.waitForTasksToCompleteOnShutdown = waitForTasksToCompleteOnShutdown; }
+    public int getAwaitTerminationSeconds() { return awaitTerminationSeconds; }
+    public void setAwaitTerminationSeconds(int awaitTerminationSeconds) { this.awaitTerminationSeconds = awaitTerminationSeconds; }
+}
+
+

--
Gitblit v1.8.0