Skip to content

Commit

Permalink
切面开关
Browse files Browse the repository at this point in the history
  • Loading branch information
yangwenzea committed Nov 21, 2023
1 parent b800fe5 commit 29c0a61
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Component;
import org.springframework.web.context.request.RequestContextHolder;
Expand All @@ -34,6 +35,7 @@

@Aspect
@Component
@ConditionalOnProperty(name = "feature.enabled", havingValue = "true", matchIfMissing = true)
public class AuditLogAspect {

@Autowired
Expand Down
4 changes: 4 additions & 0 deletions streamis-server/src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,7 @@ management:
include: refresh,info
logging:
config: classpath:log4j2.xml

# 切面开启配置参数
feature:
enabled: true

0 comments on commit 29c0a61

Please sign in to comment.