Skip to content

Commit

Permalink
rebase
Browse files Browse the repository at this point in the history
support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

fix

support sofa registry kubernetes

fix KubernetesRegistryHelper

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support k8s registry

support k8s registry

update rpc version to 5.13.0-SNAPSHOT (#1396)

Co-authored-by: liujianjun.ljj <[email protected]>

optimize UserThreadPoolManager (#1390)

Co-authored-by: 呈铭 <[email protected]>

fix #1380, create NacosRegistryProviderObserver when init method is executed  (#1401)

* fix #1380

* fix #1380

---------

Co-authored-by: 呈铭 <[email protected]>

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes

support sofa registry kubernetes
  • Loading branch information
呈铭 committed Mar 22, 2024
1 parent a477e3e commit 49349b2
Show file tree
Hide file tree
Showing 23 changed files with 1,009 additions and 338 deletions.
8 changes: 7 additions & 1 deletion all/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>com.alipay.sofa</groupId>
<artifactId>sofa-rpc-all</artifactId>
<version>5.12.0</version>
<version>5.13.0-SNAPSHOT</version>


<name>${project.groupId}:${project.artifactId}</name>
Expand Down Expand Up @@ -244,6 +244,11 @@
<artifactId>sofa-rpc-registry-polaris</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>com.alipay.sofa</groupId>
<artifactId>sofa-rpc-registry-kubernetes</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>com.alipay.sofa</groupId>
<artifactId>sofa-rpc-remoting-bolt</artifactId>
Expand Down Expand Up @@ -545,6 +550,7 @@
<include>com.alipay.sofa:sofa-rpc-registry-multicast</include>
<include>com.alipay.sofa:sofa-rpc-registry-sofa</include>
<include>com.alipay.sofa:sofa-rpc-registry-polaris</include>
<include>com.alipay.sofa:sofa-rpc-registry-kubernetes</include>
<include>com.alipay.sofa:sofa-rpc-remoting-bolt</include>
<include>com.alipay.sofa:sofa-rpc-remoting-http</include>
<include>com.alipay.sofa:sofa-rpc-remoting-resteasy</include>
Expand Down
32 changes: 16 additions & 16 deletions bom/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<packaging>pom</packaging>

<properties>
<revision>5.12.0</revision>
<revision>5.13.0-SNAPSHOT</revision>
<javassist.version>3.29.2-GA</javassist.version>
<bytebuddy.version>1.9.8</bytebuddy.version>
<netty.version>4.1.77.Final</netty.version>
Expand All @@ -31,8 +31,6 @@
<asm.version>7.0</asm.version>
<guava.version>32.0.0-jre</guava.version>
<prometheus.client.version>0.16.0</prometheus.client.version>
<!-- Fabric8 for Kubernetes -->
<fabric8_kubernetes_version>6.9.2</fabric8_kubernetes_version>
<!-- serialization -->
<hessian.version>3.5.2</hessian.version>
<thrift.version>0.9.2</thrift.version>
Expand Down Expand Up @@ -62,6 +60,8 @@
<!-- Build args -->
<module.install.skip>true</module.install.skip>
<module.deploy.skip>true</module.deploy.skip>
<!-- Fabric8 for Kubernetes -->
<fabric8_kubernetes_version>6.9.2</fabric8_kubernetes_version>
</properties>

<dependencyManagement>
Expand Down Expand Up @@ -516,6 +516,19 @@
<version>${grpc.version}</version>
</dependency>

<!-- Fabric8 for Kubernetes -->
<dependency>
<groupId>io.fabric8</groupId>
<artifactId>kubernetes-client</artifactId>
<version>${fabric8_kubernetes_version}</version>
</dependency>
<dependency>
<groupId>io.fabric8</groupId>
<artifactId>kubernetes-server-mock</artifactId>
<scope>test</scope>
<version>${fabric8_kubernetes_version}</version>
</dependency>

<!-- Test libs -->
<dependency>
<groupId>org.apache.curator</groupId>
Expand Down Expand Up @@ -600,19 +613,6 @@
<version>0.16.0</version>
<scope>test</scope>
</dependency>

<!-- Fabric8 for Kubernetes -->
<dependency>
<groupId>io.fabric8</groupId>
<artifactId>kubernetes-client</artifactId>
<version>${fabric8_kubernetes_version}</version>
</dependency>
<dependency>
<groupId>io.fabric8</groupId>
<artifactId>kubernetes-server-mock</artifactId>
<scope>test</scope>
<version>${fabric8_kubernetes_version}</version>
</dependency>
</dependencies>
</dependencyManagement>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,16 @@ public final class Version {
/**
* 当前RPC版本,例如:5.6.7
*/
public static final String VERSION = "5.12.0";
public static final String VERSION = "5.13.0";

/**
* 当前RPC版本,例如: 5.6.7 对应 50607
*/
public static final int RPC_VERSION = 51200;
public static final int RPC_VERSION = 51300;

/**
* 当前Build版本,每次发布修改
*/
public static final String BUILD_VERSION = "5.12.0_20240122111527";
public static final String BUILD_VERSION = "5.13.0_20240222103719";

}
Original file line number Diff line number Diff line change
Expand Up @@ -398,6 +398,36 @@ public String getParameter(String key) {
return parameters == null ? null : parameters.get(key);
}

/**
* Gets parameter or default.
*
* @param key the key
* @return the value
*/
public String getParameter(String key, String defaultValue) {
return getParameter(key) == null ? defaultValue : getParameter(key);
}

/**
* Gets parameter or default.
*
* @param key the key
* @return the value
*/
public int getParameter(String key, int defaultValue) {
return getParameter(key) == null ? defaultValue : Integer.parseInt(parameters.get(key));
}

/**
* Gets parameter or default.
*
* @param key the key
* @return the value
*/
public boolean getParameter(String key, boolean defaultValue) {
return getParameter(key) == null ? defaultValue : Boolean.parseBoolean(parameters.get(key));
}

@Override
public String toString() {
return "RegistryConfig{" +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,7 @@ public static UserThreadPool getUserThread(String service) {
public static Set<UserThreadPool> getUserThreadPoolSet() {
Set<UserThreadPool> userThreadPoolSet = new HashSet<>();
if (hasUserThread()) {
for (UserThreadPool userThreadPool : userThreadMap.values()) {
userThreadPoolSet.add(userThreadPool);
}
userThreadPoolSet.addAll(userThreadMap.values());
}
return userThreadPoolSet;
}
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@

<properties>
<!-- Build args -->
<revision>5.12.0</revision>
<revision>5.13.0-SNAPSHOT</revision>
<jmh.version>1.33</jmh.version>
<module.install.skip>true</module.install.skip>
<module.deploy.skip>true</module.deploy.skip>
Expand Down
72 changes: 0 additions & 72 deletions registry/registry-kubernetes/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -34,78 +34,6 @@
<artifactId>kubernetes-server-mock</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>

<build>
<sourceDirectory>src/main/java</sourceDirectory>
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>false</filtering>
<includes>
<include>**/**</include>
</includes>
</resource>
</resources>
<testSourceDirectory>src/test/java</testSourceDirectory>
<testResources>
<testResource>
<directory>src/test/resources</directory>
<filtering>false</filtering>
<includes>
<include>**/**</include>
</includes>
</testResource>
</testResources>

<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>${maven.compiler.source}</source>
<target>${maven.compiler.target}</target>
<encoding>${project.build.sourceEncoding}</encoding>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<configuration>
<skip>${module.install.skip}</skip>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-deploy-plugin</artifactId>
<configuration>
<skip>${module.deploy.skip}</skip>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<skipTests>${skipTests}</skipTests>
<includes>
<!-- 这里需要根据自己的需要指定要跑的单元测试 -->
<include>**/*Test.java</include>
</includes>
<!-- 如无特殊需求,将forkMode设置为once -->
<forkMode>once</forkMode>
</configuration>
</plugin>
</plugins>
</build>

</project>

This file was deleted.

Loading

0 comments on commit 49349b2

Please sign in to comment.