稳定版。没重构之前。稳定的限流。

This commit is contained in:
Leo
2025-03-04 14:29:48 +08:00
parent 72b7a125e0
commit 645b025172
16 changed files with 182 additions and 130 deletions

View File

@@ -1,15 +0,0 @@
package cn.van.business.config;
import org.apache.rocketmq.spring.core.RocketMQTemplate;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@Configuration
public class RocketMQConfig {
@Bean
public RocketMQTemplate rocketMQTemplate() {
System.out.println("RocketMQTemplate init");
return new RocketMQTemplate();
}
}

View File

@@ -1,12 +1,12 @@
package cn.van.business.config;
import jakarta.annotation.PreDestroy;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.annotation.Configuration;
import org.springframework.scheduling.annotation.SchedulingConfigurer;
import org.springframework.scheduling.config.ScheduledTaskRegistrar;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import jakarta.annotation.PreDestroy; // 使用 jakarta.annotation 包
import java.util.Collection;
import java.util.List;
import java.util.concurrent.*;