Skip to content

[云原生 - 3. 分布式配置云原生架构] 作业二:为 microsphere-configuration 新增 Nacos Spring 实现 #44

Description

@mercyblitz

要求:

  • 基于 Microsphere Spring Context 配置整合 Nacos
    • Maven 依赖
<dependencies>
  <!-- Spring Framework 6.x+ -->
  <dependency>
    <groupId>io.github.microsphere-projects</groupId>
    <artifactId>microsphere-spring-context</artifactId>
    <version>2.0.0-SNAPSHOT</version>
  </dependency>

  <!-- Spring Framework 4.x+ -->
  <dependency>
    <groupId>io.github.microsphere-projects</groupId>
    <artifactId>microsphere-spring-context</artifactId>
    <version>0.0.3</version>
  </dependency>
</dependencies>

<repositories>
  <repository>
    <id>snapshot</id>
    <snapshots>
      <enabled>true</enabled>
    </snapshots>
    <releases>
      <enabled>false</enabled>
    </releases>
    <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
  </repository>
</repositories>
  • 基于 Microsphere Nacos Open API

    • Maven 依赖
      <dependencies>
        <dependency>
        <groupId>io.github.microsphere-projects</groupId>
        <artifactId>microsphere-nacos-openapi</artifactId>
        <version>1.0.0-SNAPSHOT</version>
        </dependency>
      </dependencies>
    
      <repositories>
          <repository>
              <id>snapshot</id>
              <snapshots>
                  <enabled>true</enabled>
              </snapshots>
              <releases>
                  <enabled>false</enabled>
              </releases>
              <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
          </repository>
      </repositories>
  • 功能清单

    • 模块注解 @NacosPropertySource
    • 扩展 PropertySourceExtensionLoader 实现
    • 扩展 `PropertySourceExtensionAttributes 实现

推荐 PR 到 https://github.com/microsphere-projects/microsphere-configuration

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions