Skip to content

Commit

Permalink
✨ Nacos v2.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
twelvet-s committed Feb 5, 2025
1 parent 5e69891 commit 0e6d097
Show file tree
Hide file tree
Showing 15 changed files with 167 additions and 611 deletions.
31 changes: 31 additions & 0 deletions data/sql/base/twelvet_nacos.sql
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,37 @@ CREATE TABLE `config_info_beta`
-- Records of config_info_beta
-- ----------------------------

-- ----------------------------
-- Table structure for config_info_gray
-- ----------------------------
DROP TABLE IF EXISTS `config_info_gray`;
CREATE TABLE `config_info_gray`
(
`id` bigint unsigned NOT NULL AUTO_INCREMENT COMMENT 'id',
`data_id` varchar(255) NOT NULL COMMENT 'data_id',
`group_id` varchar(128) NOT NULL COMMENT 'group_id',
`content` longtext NOT NULL COMMENT 'content',
`md5` varchar(32) DEFAULT NULL COMMENT 'md5',
`src_user` text COMMENT 'src_user',
`src_ip` varchar(100) DEFAULT NULL COMMENT 'src_ip',
`gmt_create` datetime(3) NOT NULL DEFAULT CURRENT_TIMESTAMP(3) COMMENT 'gmt_create',
`gmt_modified` datetime(3) NOT NULL DEFAULT CURRENT_TIMESTAMP(3) COMMENT 'gmt_modified',
`app_name` varchar(128) DEFAULT NULL COMMENT 'app_name',
`tenant_id` varchar(128) DEFAULT '' COMMENT 'tenant_id',
`gray_name` varchar(128) NOT NULL COMMENT 'gray_name',
`gray_rule` text NOT NULL COMMENT 'gray_rule',
`encrypted_data_key` varchar(256) NOT NULL DEFAULT '' COMMENT 'encrypted_data_key',
PRIMARY KEY (`id`),
UNIQUE KEY `uk_configinfogray_datagrouptenantgray` (`data_id`, `group_id`, `tenant_id`, `gray_name`),
KEY `idx_dataid_gmt_modified` (`data_id`, `gmt_modified`),
KEY `idx_gmt_modified` (`gmt_modified`)
) ENGINE = InnoDB
DEFAULT CHARSET = utf8 COMMENT ='config_info_gray';

-- ----------------------------
-- Records of config_info_gray
-- ----------------------------

-- ----------------------------
-- Table structure for config_info_tag
-- ----------------------------
Expand Down
54 changes: 34 additions & 20 deletions twelvet-nacos/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,71 +14,84 @@
<description>nacos 注册配置中心</description>

<properties>
<nacos.version>2.3.2-OEM</nacos.version>
<spring-boot-dependencies.version>2.7.18</spring-boot-dependencies.version>
<spring-cloud.version>2021.0.9</spring-cloud.version>
<nacos.version>2.5.0</nacos.version>
<tomcat.version>9.0.98</tomcat.version>
<spring-boot.version>2.7.18</spring-boot.version>
<spring-boot-admin.version>2.7.16</spring-boot-admin.version>
</properties>

<!--依赖版本声明-->
<dependencyManagement>
<dependencies>

<!-- SpringBoot 依赖配置 -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-dependencies</artifactId>
<version>${spring-boot-dependencies.version}</version>
<version>${spring-boot.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>

<!-- SpringCloud 微服务 -->
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-dependencies</artifactId>
<version>${spring-cloud.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>

<!-- SpringBoot Admin -->
<dependency>
<groupId>de.codecentric</groupId>
<artifactId>spring-boot-admin-starter-client</artifactId>
<version>${spring-boot-admin.version}</version>
</dependency>

<!-- 覆盖nacos tomcat version 避免CVE-2024-24549-->
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-websocket</artifactId>
<version>${tomcat.version}</version>
</dependency>

<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-core</artifactId>
<version>${tomcat.version}</version>
</dependency>

<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-el</artifactId>
<version>${tomcat.version}</version>
</dependency>

<dependency>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-annotations-api</artifactId>
<version>${tomcat.version}</version>
</dependency>
</dependencies>
</dependencyManagement>

<dependencies>
<dependency>
<groupId>group.springframework.nacos</groupId>
<groupId>io.github.pig-mesh.nacos</groupId>
<artifactId>nacos-config</artifactId>
<version>${nacos.version}</version>
</dependency>

<dependency>
<groupId>group.springframework.nacos</groupId>
<groupId>io.github.pig-mesh.nacos</groupId>
<artifactId>nacos-naming</artifactId>
<version>${nacos.version}</version>
</dependency>

<dependency>
<groupId>group.springframework.nacos</groupId>
<groupId>io.github.pig-mesh.nacos</groupId>
<artifactId>nacos-istio</artifactId>
<version>${nacos.version}</version>
</dependency>

<dependency>
<groupId>group.springframework.nacos</groupId>
<groupId>io.github.pig-mesh.nacos</groupId>
<artifactId>nacos-default-plugin-all</artifactId>
<version>${nacos.version}</version>
</dependency>

<dependency>
<groupId>group.springframework.nacos</groupId>
<groupId>io.github.pig-mesh.nacos</groupId>
<artifactId>nacos-prometheus</artifactId>
<version>${nacos.version}</version>
</dependency>
Expand All @@ -94,6 +107,7 @@
</dependency>

</dependencies>

<build>
<plugins>
<plugin>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.alibaba.nacos;

import com.alibaba.nacos.config.ConfigConstants;
import com.alibaba.nacos.console.config.ConfigConstants;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/*
* Copyright (c) 2018-2025, lengleng All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* Neither the name of the pig4cloud.com developer nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
* Author: lengleng ([email protected])
*/

package com.alibaba.nacos.console.config;

/**
* @author lengleng
* @date 2019-10-31
* <p>
* 覆盖nacos 默认配置
*/
public interface ConfigConstants {

/**
* The System property name of Standalone mode
*/
String STANDALONE_MODE = "nacos.standalone";

/**
* 是否开启认证
*/
String AUTH_ENABLED = "nacos.core.auth.enabled";

/**
* 日志目录
*/
String LOG_BASEDIR = "server.tomcat.basedir";

/**
* access_log日志开关
*/
String LOG_ENABLED = "server.tomcat.accesslog.enabled";

/**
* 路径 nacos context path
*/
String NACOS_CONTEXT_PATH = "server.servlet.contextPath";

}
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.alibaba.nacos.config;
package com.alibaba.nacos.console.config;

import com.alibaba.nacos.console.filter.XssFilter;
import com.alibaba.nacos.core.code.ControllerMethodsCache;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@

package com.alibaba.nacos.console.config;

import com.alibaba.nacos.config.ConsoleConfig;
import com.alibaba.nacos.sys.module.ModuleState;
import com.alibaba.nacos.sys.module.ModuleStateBuilder;
import com.alibaba.nacos.sys.utils.ApplicationUtils;
Expand Down
78 changes: 0 additions & 78 deletions twelvet-nacos/src/main/resources/META-INF/nacos-default.properties

This file was deleted.

Loading

0 comments on commit 0e6d097

Please sign in to comment.