cn.herodotus.stirrup.logic.bpmn.autoconfigure.BpmnLogicAutoConfiguration Maven / Gradle / Ivy
The newest version!
/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
*
* Copyright (c) 2020-2030 郑庚伟 ZHENGGENGWEI (码匠君), Licensed under the AGPL License
*
* This file is part of Herodotus Stirrup.
*
* Herodotus Stirrup is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published
* by the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Herodotus Stirrup is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see .
*/
package cn.herodotus.stirrup.logic.bpmn.autoconfigure;
import cn.herodotus.stirrup.core.autoconfigure.oauth2.servlet.ServletOAuth2AuthorizationAutoConfiguration;
import cn.herodotus.stirrup.core.identity.oauth2.BearerTokenResolver;
import cn.herodotus.stirrup.logic.bpmn.configuration.BpmnLogicCamundaConfiguration;
import cn.herodotus.stirrup.logic.bpmn.configuration.BpmnLogicMongodbConfiguration;
import cn.herodotus.stirrup.logic.bpmn.interceptor.ProcessEngineAuthenticationFilter;
import jakarta.annotation.PostConstruct;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Import;
import org.springframework.data.mongodb.config.EnableMongoAuditing;
/**
* Description: Bpmn Logic 模块配置
*
* @author : gengwei.zheng
* @date : 2023/1/18 15:10
*/
@AutoConfiguration(after = ServletOAuth2AuthorizationAutoConfiguration.class)
@EnableMongoAuditing
@Import({
BpmnLogicCamundaConfiguration.class,
BpmnLogicMongodbConfiguration.class
})
public class BpmnLogicAutoConfiguration {
private static final Logger log = LoggerFactory.getLogger(BpmnLogicAutoConfiguration.class);
@PostConstruct
public void postConstruct() {
log.debug("[Herodotus] |- SDK [Module Bpmn Logic] Auto Configure.");
}
@Bean
public ProcessEngineAuthenticationFilter processEngineAuthenticationFilter(BearerTokenResolver bearerTokenResolver) {
ProcessEngineAuthenticationFilter processEngineAuthenticationFilter = new ProcessEngineAuthenticationFilter(bearerTokenResolver);
log.trace("[Herodotus] |- Bean [Process Engine Authentication Filter] Auto Configure.");
return processEngineAuthenticationFilter;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy