Merge branch '3.1.1-release' into apache-3.1
diff --git a/.codecov.yml b/.codecov.yml
index 4b49c86..0b498ec 100644
--- a/.codecov.yml
+++ b/.codecov.yml
@@ -1,3 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
coverage:
status:
# pull-requests only
@@ -8,4 +23,4 @@
- "dubbo-demo/.*"
- "dubbo-common/src/main/java/org/apache/dubbo/common/json/*.java" # internal JSON impl is deprecate, ignore test coverage for them
- "dubbo-config/dubbo-config-spring/src/main/java/org/apache/dubbo/config/spring/AnnotationBean.java" # Deprecated
- - "dubbo-rpc/dubbo-rpc-thrift/.*"
\ No newline at end of file
+ - "dubbo-rpc/dubbo-rpc-thrift/.*"
diff --git a/.github/workflows/build-and-test-3.1.yml b/.github/workflows/build-and-test-3.1.yml
index 6cbd004..f8c4370 100644
--- a/.github/workflows/build-and-test-3.1.yml
+++ b/.github/workflows/build-and-test-3.1.yml
@@ -18,8 +18,16 @@
'
jobs:
+ license:
+ runs-on: ubuntu-20.04
+ steps:
+ - uses: actions/checkout@v2
+ - name: Check License
+ uses: apache/skywalking-eyes@main
+ env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
build-source:
- runs-on: ubuntu-18.04
+ runs-on: ubuntu-20.04
outputs:
version: ${{ steps.dubbo-version.outputs.version }}
steps:
@@ -74,7 +82,7 @@
strategy:
fail-fast: false
matrix:
- os: [ ubuntu-18.04, windows-2019 ]
+ os: [ ubuntu-20.04, windows-2019 ]
jdk: [ 8, 11, 17 ]
env:
DISABLE_FILE_SYSTEM_TEST: true
@@ -126,7 +134,7 @@
strategy:
fail-fast: false
matrix:
- os: [ ubuntu-18.04, windows-2019 ]
+ os: [ ubuntu-20.04, windows-2019 ]
jdk: [ 8, 11, 17 ]
env:
DISABLE_FILE_SYSTEM_TEST: true
@@ -161,7 +169,7 @@
strategy:
fail-fast: false
matrix:
- os: [ ubuntu-18.04, windows-2019 ]
+ os: [ ubuntu-20.04, windows-2019 ]
jdk: [ 8, 11, 17 ]
env:
DISABLE_FILE_SYSTEM_TEST: true
@@ -192,7 +200,7 @@
uses: codecov/codecov-action@v1
integration-test-prepare:
- runs-on: ubuntu-18.04
+ runs-on: ubuntu-20.04
env:
JOB_COUNT: 3
steps:
@@ -211,8 +219,8 @@
integration-test-job:
needs: [build-source, integration-test-prepare]
- name: "Integration Test on ubuntu-18.04 (JobId: ${{matrix.job_id}})"
- runs-on: ubuntu-18.04
+ name: "Integration Test on ubuntu-20.04 (JobId: ${{matrix.job_id}})"
+ runs-on: ubuntu-20.04
timeout-minutes: 30
env:
JAVA_VER: 8
@@ -267,7 +275,7 @@
integration-test-result:
needs: [integration-test-job]
if: always()
- runs-on: ubuntu-18.04
+ runs-on: ubuntu-20.04
env:
JAVA_VER: 8
steps:
diff --git a/.licenserc.yaml b/.licenserc.yaml
new file mode 100644
index 0000000..00b7286
--- /dev/null
+++ b/.licenserc.yaml
@@ -0,0 +1,82 @@
+header:
+ license:
+ spdx-id: Apache-2.0
+ content: |
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+ paths-ignore:
+ - '**/*.versionsBackup'
+ - '**/.idea/'
+ - '**/*.iml'
+ - '**/.settings/*'
+ - '**/.classpath'
+ - '**/.project'
+ - '**/target/**'
+ - '**/generated/**'
+ - '**/*.log'
+ - '**/codestyle/*'
+ - '**/resources/META-INF/**'
+ - '**/resources/mockito-extensions/**'
+ - '**/*.proto'
+ - '**/*.cache'
+ - '**/*.txt'
+ - '**/*.load'
+ - '**/*.flex'
+ - '**/*.fc'
+ - '**/*.javascript'
+ - '**/*.properties'
+ - '**/*.thrift'
+ - '**/*.sh'
+ - '**/*.bat'
+ - '**/*.md'
+ - '**/*.svg'
+ - '**/*.png'
+ - '**/*.json'
+ - '**/*.conf'
+ - '**/*.ftl'
+ - '**/*.tpl'
+ - '**/*.factories'
+ - '**/*.handlers'
+ - '**/*.schemas'
+ - '**/*.nojekyll'
+ - '.git/'
+ - '.github/**'
+ - '**/.gitignore'
+ - '**/.helmignore'
+ - '.repository/'
+ - 'compiler/**'
+ - '.gitmodules'
+ - '.mvn'
+ - 'mvnw'
+ - 'mvnw.cmd'
+ - 'LICENSE'
+ - 'NOTICE'
+ - 'CNAME'
+ - 'Jenkinsfile'
+ - '**/vendor/**'
+ - 'dubbo-common/src/main/java/org/apache/dubbo/common/threadlocal/InternalThreadLocal.java'
+ - 'dubbo-common/src/main/java/org/apache/dubbo/common/threadlocal/InternalThreadLocalMap.java'
+ - 'dubbo-common/src/main/java/org/apache/dubbo/common/timer/HashedWheelTimer.java'
+ - 'dubbo-common/src/main/java/org/apache/dubbo/common/timer/Timeout.java'
+ - 'dubbo-common/src/main/java/org/apache/dubbo/common/timer/Timer.java'
+ - 'dubbo-common/src/main/java/org/apache/dubbo/common/timer/TimerTask.java'
+ - 'dubbo-common/src/main/java/org/apache/dubbo/common/utils/CIDRUtils.java'
+ - 'dubbo-common/src/main/java/org/apache/dubbo/common/utils/Utf8Utils.java'
+ - 'dubbo-config/dubbo-config-spring/src/test/java/org/apache/dubbo/config/spring/EmbeddedZooKeeper.java'
+
+ comment: on-failure
+
+ license-location-threshold: 130
diff --git a/.travis.yml b/.travis.yml
index 6b59c76..a7b6c63 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,3 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
sudo: false # faster builds
os: linux
dist: focal
diff --git a/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/LeastActiveBalanceTest.java b/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/LeastActiveBalanceTest.java
index 89dc66b..0e172e4 100644
--- a/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/LeastActiveBalanceTest.java
+++ b/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/LeastActiveBalanceTest.java
@@ -3,7 +3,7 @@
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License")); you may not use this file except in compliance with
+ * (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
diff --git a/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/LoadBalanceBaseTest.java b/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/LoadBalanceBaseTest.java
index 0331873..c96c0fc 100644
--- a/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/LoadBalanceBaseTest.java
+++ b/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/LoadBalanceBaseTest.java
@@ -3,7 +3,7 @@
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License")); you may not use this file except in compliance with
+ * (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
diff --git a/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/RandomLoadBalanceTest.java b/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/RandomLoadBalanceTest.java
index f18a07d..7bd0a76 100644
--- a/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/RandomLoadBalanceTest.java
+++ b/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/RandomLoadBalanceTest.java
@@ -3,7 +3,7 @@
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License")); you may not use this file except in compliance with
+ * (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
diff --git a/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/ShortestResponseLoadBalanceTest.java b/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/ShortestResponseLoadBalanceTest.java
index aebaf00..9d43790 100644
--- a/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/ShortestResponseLoadBalanceTest.java
+++ b/dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/loadbalance/ShortestResponseLoadBalanceTest.java
@@ -3,7 +3,7 @@
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License")); you may not use this file except in compliance with
+ * (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
diff --git a/dubbo-common/src/test/java/org/apache/dubbo/common/beanutil/Bean.java b/dubbo-common/src/test/java/org/apache/dubbo/common/beanutil/Bean.java
index e17a538..4ea53cb 100644
--- a/dubbo-common/src/test/java/org/apache/dubbo/common/beanutil/Bean.java
+++ b/dubbo-common/src/test/java/org/apache/dubbo/common/beanutil/Bean.java
@@ -1,12 +1,3 @@
-package org.apache.dubbo.common.beanutil;
-
-import org.apache.dubbo.rpc.model.person.FullAddress;
-import org.apache.dubbo.rpc.model.person.PersonStatus;
-import org.apache.dubbo.rpc.model.person.Phone;
-
-import java.util.Collection;
-import java.util.Date;
-import java.util.Map;
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
@@ -23,6 +14,16 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+package org.apache.dubbo.common.beanutil;
+
+import org.apache.dubbo.rpc.model.person.FullAddress;
+import org.apache.dubbo.rpc.model.person.PersonStatus;
+import org.apache.dubbo.rpc.model.person.Phone;
+
+import java.util.Collection;
+import java.util.Date;
+import java.util.Map;
+
public class Bean {
private Class<?> type;
diff --git a/dubbo-dependencies-bom/pom.xml b/dubbo-dependencies-bom/pom.xml
index 554308d..92f70b2 100644
--- a/dubbo-dependencies-bom/pom.xml
+++ b/dubbo-dependencies-bom/pom.xml
@@ -126,7 +126,7 @@
<fst_version>2.48-jdk-6</fst_version>
<avro_version>1.8.2</avro_version>
<apollo_client_version>1.8.0</apollo_client_version>
- <snakeyaml_version>1.31</snakeyaml_version>
+ <snakeyaml_version>1.32</snakeyaml_version>
<commons_lang3_version>3.8.1</commons_lang3_version>
<protostuff_version>1.5.9</protostuff_version>
<envoy_api_version>0.1.23</envoy_api_version>
diff --git a/dubbo-metadata/dubbo-metadata-processor/src/test/java/org/apache/dubbo/metadata/annotation/processing/model/SimpleTypeModel.java b/dubbo-metadata/dubbo-metadata-processor/src/test/java/org/apache/dubbo/metadata/annotation/processing/model/SimpleTypeModel.java
index 4b3523a..c745c92 100644
--- a/dubbo-metadata/dubbo-metadata-processor/src/test/java/org/apache/dubbo/metadata/annotation/processing/model/SimpleTypeModel.java
+++ b/dubbo-metadata/dubbo-metadata-processor/src/test/java/org/apache/dubbo/metadata/annotation/processing/model/SimpleTypeModel.java
@@ -2,15 +2,15 @@
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License; Version 2.0
+ * The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
- * Unless required by applicable law or agreed to in writing; software
- * distributed under the License is distributed on an "AS IS" BASIS;
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND; either express or implied.
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
diff --git a/dubbo-plugin/dubbo-qos/src/main/java/org/apache/dubbo/qos/command/decoder/TelnetCommandDecoder.java b/dubbo-plugin/dubbo-qos/src/main/java/org/apache/dubbo/qos/command/decoder/TelnetCommandDecoder.java
index 52e58b5..3c559a5 100644
--- a/dubbo-plugin/dubbo-qos/src/main/java/org/apache/dubbo/qos/command/decoder/TelnetCommandDecoder.java
+++ b/dubbo-plugin/dubbo-qos/src/main/java/org/apache/dubbo/qos/command/decoder/TelnetCommandDecoder.java
@@ -25,11 +25,15 @@
public static final CommandContext decode(String str) {
CommandContext commandContext = null;
if (!StringUtils.isBlank(str)) {
+ str = str.trim();
String[] array = str.split("(?<![\\\\]) ");
if (array.length > 0) {
- String name = array[0];
String[] targetArgs = new String[array.length - 1];
System.arraycopy(array, 1, targetArgs, 0, array.length - 1);
+ String name = array[0].trim();
+ if (name.equals("invoke") && array.length > 2) {
+ targetArgs = reBuildInvokeCmdArgs(str);
+ }
commandContext = CommandContextFactory.newInstance( name, targetArgs,false);
commandContext.setOriginRequest(str);
}
@@ -38,4 +42,8 @@
return commandContext;
}
+ private static String[] reBuildInvokeCmdArgs(String cmd) {
+ return new String[] {cmd.substring(cmd.indexOf(" ") + 1).trim()};
+ }
+
}