From ee229770caf9364928e9d0714c8e499cc3fb59c1 Mon Sep 17 00:00:00 2001 From: greysonfang Date: Fri, 8 Sep 2023 23:12:01 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=8C=87=E5=AE=9A=E6=A8=A1=E5=9D=97?= =?UTF-8?q?=E7=BB=9F=E4=B8=80=E6=89=93=E5=8C=85=E6=8F=92=E4=BB=B6=20#8672?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/tencent/devops/misc/config/JooqConfiguration.kt | 2 +- .../boot-multijar}/build.gradle.kts | 0 .../devops/multijar}/DataSourceDefinitionRegistrar.kt | 5 +---- .../com/tencent/devops/multijar}/JooqDefinitionRegistrar.kt | 3 +-- .../com/tencent/devops/multijar/MultijarApplication.kt} | 2 +- .../devops/multijar/MultijarDslContextConfiguration.kt} | 6 ++---- .../boot-multijar}/src/main/resources/application.yml | 6 +++--- src/backend/ci/core/{mutijar => multijar}/build.gradle.kts | 2 +- src/backend/ci/settings.gradle.kts | 4 ++-- 9 files changed, 12 insertions(+), 18 deletions(-) rename src/backend/ci/core/{mutijar/boot-mutijar => multijar/boot-multijar}/build.gradle.kts (100%) rename src/backend/ci/core/{mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar => multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar}/DataSourceDefinitionRegistrar.kt (95%) rename src/backend/ci/core/{mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar => multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar}/JooqDefinitionRegistrar.kt (97%) rename src/backend/ci/core/{mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/MutijarApplication.kt => multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/MultijarApplication.kt} (98%) rename src/backend/ci/core/{mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/MutijarDslContextConfiguration.kt => multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/MultijarDslContextConfiguration.kt} (96%) rename src/backend/ci/core/{mutijar/boot-mutijar => multijar/boot-multijar}/src/main/resources/application.yml (83%) rename src/backend/ci/core/{mutijar => multijar}/build.gradle.kts (96%) diff --git a/src/backend/ci/core/misc/biz-misc/src/main/kotlin/com/tencent/devops/misc/config/JooqConfiguration.kt b/src/backend/ci/core/misc/biz-misc/src/main/kotlin/com/tencent/devops/misc/config/JooqConfiguration.kt index 0ee046bdc7b..b67142b17c5 100644 --- a/src/backend/ci/core/misc/biz-misc/src/main/kotlin/com/tencent/devops/misc/config/JooqConfiguration.kt +++ b/src/backend/ci/core/misc/biz-misc/src/main/kotlin/com/tencent/devops/misc/config/JooqConfiguration.kt @@ -56,7 +56,7 @@ import javax.sql.DataSource */ @Configuration @Import(DataSourceConfig::class, DBBaseConfiguration::class) -@ConditionalOnMissingClass("com.tencent.devops.mutijar.MutijarDslContextConfiguration") +@ConditionalOnMissingClass("com.tencent.devops.multijar.MultijarDslContextConfiguration") @AutoConfigureAfter(DBBaseConfiguration::class) class JooqConfiguration { diff --git a/src/backend/ci/core/mutijar/boot-mutijar/build.gradle.kts b/src/backend/ci/core/multijar/boot-multijar/build.gradle.kts similarity index 100% rename from src/backend/ci/core/mutijar/boot-mutijar/build.gradle.kts rename to src/backend/ci/core/multijar/boot-multijar/build.gradle.kts diff --git a/src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/DataSourceDefinitionRegistrar.kt b/src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/DataSourceDefinitionRegistrar.kt similarity index 95% rename from src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/DataSourceDefinitionRegistrar.kt rename to src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/DataSourceDefinitionRegistrar.kt index 1c6c848cb3a..47ddf72902d 100644 --- a/src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/DataSourceDefinitionRegistrar.kt +++ b/src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/DataSourceDefinitionRegistrar.kt @@ -1,7 +1,6 @@ -package com.tencent.devops.mutijar +package com.tencent.devops.multijar import com.mysql.jdbc.Driver -import com.tencent.devops.common.web.jasypt.DefaultEncryptor import com.zaxxer.hikari.HikariDataSource import org.slf4j.LoggerFactory import org.springframework.beans.factory.config.YamlPropertiesFactoryBean @@ -12,11 +11,9 @@ import org.springframework.boot.autoconfigure.AutoConfigureOrder import org.springframework.context.annotation.Configuration import org.springframework.context.annotation.ImportBeanDefinitionRegistrar import org.springframework.core.Ordered -import org.springframework.core.env.Environment import org.springframework.core.io.ClassPathResource import org.springframework.core.type.AnnotationMetadata import org.springframework.transaction.annotation.EnableTransactionManagement -import java.util.Properties @Configuration diff --git a/src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/JooqDefinitionRegistrar.kt b/src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/JooqDefinitionRegistrar.kt similarity index 97% rename from src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/JooqDefinitionRegistrar.kt rename to src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/JooqDefinitionRegistrar.kt index 33ceb828a5c..375877a79f6 100644 --- a/src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/JooqDefinitionRegistrar.kt +++ b/src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/JooqDefinitionRegistrar.kt @@ -1,11 +1,10 @@ -package com.tencent.devops.mutijar +package com.tencent.devops.multijar import com.tencent.devops.common.db.listener.BkJooqExecuteListener import org.jooq.SQLDialect import org.jooq.impl.DataSourceConnectionProvider import org.jooq.impl.DefaultConfiguration import org.jooq.impl.DefaultExecuteListenerProvider -import org.slf4j.LoggerFactory import org.springframework.beans.factory.support.BeanDefinitionBuilder import org.springframework.beans.factory.support.BeanDefinitionRegistry import org.springframework.beans.factory.support.BeanNameGenerator diff --git a/src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/MutijarApplication.kt b/src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/MultijarApplication.kt similarity index 98% rename from src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/MutijarApplication.kt rename to src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/MultijarApplication.kt index fd3dbeced32..0dd7dc85295 100644 --- a/src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/MutijarApplication.kt +++ b/src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/MultijarApplication.kt @@ -25,7 +25,7 @@ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -package com.tencent.devops.mutijar +package com.tencent.devops.multijar import com.tencent.devops.common.service.MicroService import com.tencent.devops.common.service.MicroServiceApplication diff --git a/src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/MutijarDslContextConfiguration.kt b/src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/MultijarDslContextConfiguration.kt similarity index 96% rename from src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/MutijarDslContextConfiguration.kt rename to src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/MultijarDslContextConfiguration.kt index a7816beff06..e1440abe441 100644 --- a/src/backend/ci/core/mutijar/boot-mutijar/src/main/kotlin/com/tencent/devops/mutijar/MutijarDslContextConfiguration.kt +++ b/src/backend/ci/core/multijar/boot-multijar/src/main/kotlin/com/tencent/devops/multijar/MultijarDslContextConfiguration.kt @@ -24,13 +24,12 @@ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -package com.tencent.devops.mutijar +package com.tencent.devops.multijar import com.tencent.devops.common.db.config.DBBaseConfiguration import org.jooq.DSLContext import org.jooq.impl.DSL import org.jooq.impl.DefaultConfiguration -import org.slf4j.LoggerFactory import org.springframework.beans.factory.InjectionPoint import org.springframework.beans.factory.NoSuchBeanDefinitionException import org.springframework.beans.factory.config.ConfigurableBeanFactory @@ -43,7 +42,6 @@ import java.lang.reflect.AnnotatedElement import java.lang.reflect.Constructor import java.lang.reflect.Field import java.lang.reflect.Method -import java.lang.reflect.Parameter /** * @@ -51,7 +49,7 @@ import java.lang.reflect.Parameter */ @Configuration @Import(DBBaseConfiguration::class, DataSourceDefinitionRegistrar::class, JooqDefinitionRegistrar::class) -class MutijarDslContextConfiguration { +class MultijarDslContextConfiguration { @Bean @Primary @Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) diff --git a/src/backend/ci/core/mutijar/boot-mutijar/src/main/resources/application.yml b/src/backend/ci/core/multijar/boot-multijar/src/main/resources/application.yml similarity index 83% rename from src/backend/ci/core/mutijar/boot-mutijar/src/main/resources/application.yml rename to src/backend/ci/core/multijar/boot-multijar/src/main/resources/application.yml index 784630be524..d2acda23cee 100644 --- a/src/backend/ci/core/mutijar/boot-mutijar/src/main/resources/application.yml +++ b/src/backend/ci/core/multijar/boot-multijar/src/main/resources/application.yml @@ -27,7 +27,7 @@ spring: - store - quality application: - name: mutijar - desc: DevOps MUTIJAR Service + name: multijar + desc: DevOps MULTIJAR Service version: 4.0.0 - packageName: com.tencent.devops.mutijar + packageName: com.tencent.devops.multijar diff --git a/src/backend/ci/core/mutijar/build.gradle.kts b/src/backend/ci/core/multijar/build.gradle.kts similarity index 96% rename from src/backend/ci/core/mutijar/build.gradle.kts rename to src/backend/ci/core/multijar/build.gradle.kts index 1216a155ec6..81207f18ecc 100644 --- a/src/backend/ci/core/mutijar/build.gradle.kts +++ b/src/backend/ci/core/multijar/build.gradle.kts @@ -26,5 +26,5 @@ */ subprojects { - group = "com.tencent.bk.devops.ci.mutijar" + group = "com.tencent.bk.devops.ci.multijar" } diff --git a/src/backend/ci/settings.gradle.kts b/src/backend/ci/settings.gradle.kts index 61aa2ef5016..94b6c8a0c78 100644 --- a/src/backend/ci/settings.gradle.kts +++ b/src/backend/ci/settings.gradle.kts @@ -268,5 +268,5 @@ include(":core:metrics:biz-metrics-sample") include(":core:metrics:boot-metrics") include(":core:metrics:model-metrics") -include("core:mutijar") -include("core:mutijar:boot-mutijar") +include("core:multijar") +include("core:multijar:boot-multijar")