You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by "ZLBer (via GitHub)" <gi...@apache.org> on 2023/03/04 12:51:39 UTC

[GitHub] [dubbo-go-samples] ZLBer opened a new pull request, #523: feat: protobuf v2 integrate test

ZLBer opened a new pull request, #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523

   
   - [ ] tls integrate test
   
   - [ ] registrt-all integrate test
   
   - [ ] protobuf v2 integrate test


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go-samples] justxuewei commented on a diff in pull request #523: feat: protobuf v2 integrate test

Posted by "justxuewei (via GitHub)" <gi...@apache.org>.
justxuewei commented on code in PR #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523#discussion_r1135235796


##########
start_integrate_test.sh:
##########
@@ -64,13 +64,17 @@ array+=("rpc/triple/msgpack")
 array+=("rpc/triple/pb/dubbogo-grpc")
 array+=("rpc/grpc")
 array+=("rpc/jsonrpc")
+array+=("rpc/triple/pb2")
 
 #tls
 array+=("tls/dubbo")
 array+=("tls/triple")
 array+=("tls/grpc")
 
 
+# replace tls config
+find $(pwd)/tls -type f -print0 | xargs -0 sed -i  's#\.\.\/\.\.\/\.\.#'"$(pwd)/tls"'#g'

Review Comment:
   Furthermore, it would be better to print a message so that other users are aware of what we are doing.
   
   ```bash
   echo "The certificate paths were replaced to "$(pwd)/tls/x509" for tls/dubbo/go-client/conf/dubbogo.yml, tls/dubbo/go-server/conf/dubbogo.yml, <others..>"
   ```
   
   In order to make it more convenient to maintain, you could create an array to contain those config paths. Eventually, it looks like this:
   
   ```bash
   tls_configs=("config path1" "config path2")
   for (( i=0; i<${#tls_configs[@]}; i++ ))
   do
     sed -i 's#../../../x509#'"$(pwd)/tls/x509"'#g' ${tls_configs[i]}
     echo "${tls_configs[i]}: The certificate paths were replaced to \"$(pwd)/tls/x509\""
   done
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go-samples] justxuewei commented on a diff in pull request #523: feat: protobuf v2 integrate test

Posted by "justxuewei (via GitHub)" <gi...@apache.org>.
justxuewei commented on code in PR #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523#discussion_r1135235796


##########
start_integrate_test.sh:
##########
@@ -64,13 +64,17 @@ array+=("rpc/triple/msgpack")
 array+=("rpc/triple/pb/dubbogo-grpc")
 array+=("rpc/grpc")
 array+=("rpc/jsonrpc")
+array+=("rpc/triple/pb2")
 
 #tls
 array+=("tls/dubbo")
 array+=("tls/triple")
 array+=("tls/grpc")
 
 
+# replace tls config
+find $(pwd)/tls -type f -print0 | xargs -0 sed -i  's#\.\.\/\.\.\/\.\.#'"$(pwd)/tls"'#g'

Review Comment:
   Furthermore, it would be better to print a message so that other users are aware of what we are doing.
   
   ```bash
   echo "The prefix of certificate path were replaced to "$(pwd)/tls/x509" for tls/dubbo/go-client/conf/dubbogo.yml, tls/dubbo/go-server/conf/dubbogo.yml, <others..>"
   ```
   
   In order to make it more convenient to maintain, you could create an array to contain those config paths. Eventually, it looks like this:
   
   ```bash
   tls_configs=("config path1" "config path2")
   for (( i=0; i<${#tls_configs[@]}; i++ ))
   do
     sed -i 's#../../..#'"$(pwd)/tls"'#g' ${tls_configs[i]}
     echo "${tls_configs[i]}: The prefix of certificate path was replaced to \"$(pwd)/tls\""
   done
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go-samples] justxuewei commented on a diff in pull request #523: feat: protobuf v2 integrate test

Posted by "justxuewei (via GitHub)" <gi...@apache.org>.
justxuewei commented on code in PR #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523#discussion_r1135235796


##########
start_integrate_test.sh:
##########
@@ -64,13 +64,17 @@ array+=("rpc/triple/msgpack")
 array+=("rpc/triple/pb/dubbogo-grpc")
 array+=("rpc/grpc")
 array+=("rpc/jsonrpc")
+array+=("rpc/triple/pb2")
 
 #tls
 array+=("tls/dubbo")
 array+=("tls/triple")
 array+=("tls/grpc")
 
 
+# replace tls config
+find $(pwd)/tls -type f -print0 | xargs -0 sed -i  's#\.\.\/\.\.\/\.\.#'"$(pwd)/tls"'#g'

Review Comment:
   Furthermore, it would be better to print a message so that other users are aware of what we are doing.
   
   ```bash
   echo "The prefix of certificate path were replaced to "$(pwd)/tls/x509" for tls/dubbo/go-client/conf/dubbogo.yml, tls/dubbo/go-server/conf/dubbogo.yml, <others..>"
   ```
   
   In order to make it more convenient to maintain, you could create an array to contain those config paths. Eventually, it looks like this:
   
   ```bash
   tls_configs=("config path1" "config path2")
   for (( i=0; i<${#tls_configs[@]}; i++ ))
   do
     sed -i 's#../../../x509#'"$(pwd)/tls/x509"'#g' ${tls_configs[i]}
     echo "${tls_configs[i]}: The certificate paths were replaced to \"$(pwd)/tls/x509\""
   done
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go-samples] ZLBer commented on a diff in pull request #523: feat: protobuf v2 integrate test

Posted by "ZLBer (via GitHub)" <gi...@apache.org>.
ZLBer commented on code in PR #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523#discussion_r1135628710


##########
tls/triple/go-server/conf/dubbogo.yml:
##########
@@ -9,7 +9,7 @@ dubbo:
         serialization: json
         interface: com.apache.dubbogo.samples.rpc.extension.UserProvider
   tls_config:
-    ca-cert-file: /home/runner/work/dubbo-go-samples/dubbo-go-samples/tls/x509/client_ca_cert.pem
-    tls-cert-file: /home/runner/work/dubbo-go-samples/dubbo-go-samples/tls/x509/server1_cert.pem
-    tls-key-file: /home/runner/work/dubbo-go-samples/dubbo-go-samples/tls/x509/server1_key.pem
+    ca-cert-file: ../../../x509/client_ca_cert.pem
+    tls-cert-file: ../../../x509/server2_cert.pem
+    tls-key-file: ../../../x509/server2_key.pem

Review Comment:
   server1  is similar to server2, all generate by server_ca
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go-samples] justxuewei commented on a diff in pull request #523: feat: protobuf v2 integrate test

Posted by "justxuewei (via GitHub)" <gi...@apache.org>.
justxuewei commented on code in PR #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523#discussion_r1135215650


##########
start_integrate_test.sh:
##########
@@ -64,13 +64,17 @@ array+=("rpc/triple/msgpack")
 array+=("rpc/triple/pb/dubbogo-grpc")
 array+=("rpc/grpc")
 array+=("rpc/jsonrpc")
+array+=("rpc/triple/pb2")
 
 #tls
 array+=("tls/dubbo")
 array+=("tls/triple")
 array+=("tls/grpc")
 
 
+# replace tls config
+find $(pwd)/tls -type f -print0 | xargs -0 sed -i  's#\.\.\/\.\.\/\.\.#'"$(pwd)/tls"'#g'

Review Comment:
   It is not a good idea to replace all of `../../..` with `$(pwd)/tls`, as this pattern may appear in other files. Therefore, I suggest replacing them one by one.
   
   ```bash
   sed -i 's#../../../#'"$(pwd)/tls"'#g' tls/dubbo/go-client/conf/dubbogo.yml
   sed -i 's#../../..#'"$(pwd)/tls"'#g' tls/dubbo/go-server/conf/dubbogo.yml
   # etc..
   ```
   
   



##########
start_integrate_test.sh:
##########
@@ -64,13 +64,17 @@ array+=("rpc/triple/msgpack")
 array+=("rpc/triple/pb/dubbogo-grpc")
 array+=("rpc/grpc")
 array+=("rpc/jsonrpc")
+array+=("rpc/triple/pb2")
 
 #tls
 array+=("tls/dubbo")
 array+=("tls/triple")
 array+=("tls/grpc")
 
 
+# replace tls config
+find $(pwd)/tls -type f -print0 | xargs -0 sed -i  's#\.\.\/\.\.\/\.\.#'"$(pwd)/tls"'#g'

Review Comment:
   Furthermore, it would be better to print a message so that other users are aware of what we are doing.
   
   ```bash
   echo "The prefix of certificate path were replaced to "$(pwd)/tls/x509" for tls/dubbo/go-client/conf/dubbogo.yml, tls/dubbo/go-server/conf/dubbogo.yml, <others..>"
   ```
   
   In order to make it more convenient to maintain, you could create an array to contain those config paths. Eventually, it looks like this:
   
   ```bash
   tls_configs=("config path1" "config path2")
   for (( i=0; i<${#tls_configs[@]}; i++ ))
   do
     sed -i 's#../../..#'"$(pwd)/tls"'#g' ${tls_configs[i]}
     echo "${tls_configs[i]}: The prefix of certificate path was replaced to \"$(pwd)/tls/x509\""
   done
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go-samples] ZLBer commented on a diff in pull request #523: feat: protobuf v2 integrate test

Posted by "ZLBer (via GitHub)" <gi...@apache.org>.
ZLBer commented on code in PR #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523#discussion_r1135664205


##########
start_integrate_test.sh:
##########
@@ -64,13 +64,17 @@ array+=("rpc/triple/msgpack")
 array+=("rpc/triple/pb/dubbogo-grpc")
 array+=("rpc/grpc")
 array+=("rpc/jsonrpc")
+array+=("rpc/triple/pb2")
 
 #tls
 array+=("tls/dubbo")
 array+=("tls/triple")
 array+=("tls/grpc")
 
 
+# replace tls config
+find $(pwd)/tls -type f -print0 | xargs -0 sed -i  's#\.\.\/\.\.\/\.\.#'"$(pwd)/tls"'#g'

Review Comment:
   @justxuewei  we can only find yml type `find $(pwd)/tls -type f -name '*.yml' `



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go-samples] justxuewei commented on a diff in pull request #523: feat: protobuf v2 integrate test

Posted by "justxuewei (via GitHub)" <gi...@apache.org>.
justxuewei commented on code in PR #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523#discussion_r1135666977


##########
start_integrate_test.sh:
##########
@@ -64,13 +64,17 @@ array+=("rpc/triple/msgpack")
 array+=("rpc/triple/pb/dubbogo-grpc")
 array+=("rpc/grpc")
 array+=("rpc/jsonrpc")
+array+=("rpc/triple/pb2")
 
 #tls
 array+=("tls/dubbo")
 array+=("tls/triple")
 array+=("tls/grpc")
 
 
+# replace tls config
+find $(pwd)/tls -type f -print0 | xargs -0 sed -i  's#\.\.\/\.\.\/\.\.#'"$(pwd)/tls"'#g'

Review Comment:
   Lgtm



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go-samples] justxuewei commented on a diff in pull request #523: feat: protobuf v2 integrate test

Posted by "justxuewei (via GitHub)" <gi...@apache.org>.
justxuewei commented on code in PR #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523#discussion_r1135217321


##########
tls/triple/go-server/conf/dubbogo.yml:
##########
@@ -9,7 +9,7 @@ dubbo:
         serialization: json
         interface: com.apache.dubbogo.samples.rpc.extension.UserProvider
   tls_config:
-    ca-cert-file: /home/runner/work/dubbo-go-samples/dubbo-go-samples/tls/x509/client_ca_cert.pem
-    tls-cert-file: /home/runner/work/dubbo-go-samples/dubbo-go-samples/tls/x509/server1_cert.pem
-    tls-key-file: /home/runner/work/dubbo-go-samples/dubbo-go-samples/tls/x509/server1_key.pem
+    ca-cert-file: ../../../x509/client_ca_cert.pem
+    tls-cert-file: ../../../x509/server2_cert.pem
+    tls-key-file: ../../../x509/server2_key.pem

Review Comment:
   What is the difference between the server1_key and the server2_key?



##########
start_integrate_test.sh:
##########
@@ -64,13 +64,17 @@ array+=("rpc/triple/msgpack")
 array+=("rpc/triple/pb/dubbogo-grpc")
 array+=("rpc/grpc")
 array+=("rpc/jsonrpc")
+array+=("rpc/triple/pb2")
 
 #tls
 array+=("tls/dubbo")
 array+=("tls/triple")
 array+=("tls/grpc")
 
 
+# replace tls config
+find $(pwd)/tls -type f -print0 | xargs -0 sed -i  's#\.\.\/\.\.\/\.\.#'"$(pwd)/tls"'#g'

Review Comment:
   It is not a good idea to replace all of `../../..` with `$(pwd)/tls`, as this pattern may appear in other files. Therefore, I suggest replacing them one by one with a more specific pattern (including `x509`).
   
   ```bash
   sed -i 's#../../../x509#'"$(pwd)/tls/x509"'#g' tls/dubbo/go-client/conf/dubbogo.yml
   sed -i 's#../../../x509#'"$(pwd)/tls/x509"'#g' tls/dubbo/go-server/conf/dubbogo.yml
   # etc..
   ```
   
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go-samples] justxuewei commented on a diff in pull request #523: feat: protobuf v2 integrate test

Posted by "justxuewei (via GitHub)" <gi...@apache.org>.
justxuewei commented on code in PR #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523#discussion_r1135235796


##########
start_integrate_test.sh:
##########
@@ -64,13 +64,17 @@ array+=("rpc/triple/msgpack")
 array+=("rpc/triple/pb/dubbogo-grpc")
 array+=("rpc/grpc")
 array+=("rpc/jsonrpc")
+array+=("rpc/triple/pb2")
 
 #tls
 array+=("tls/dubbo")
 array+=("tls/triple")
 array+=("tls/grpc")
 
 
+# replace tls config
+find $(pwd)/tls -type f -print0 | xargs -0 sed -i  's#\.\.\/\.\.\/\.\.#'"$(pwd)/tls"'#g'

Review Comment:
   Furthermore, it would be better to print a message so that other users are aware of what we are doing.
   
   ```bash
   echo "The prefix of certificate path were replaced to "$(pwd)/tls/x509" for tls/dubbo/go-client/conf/dubbogo.yml, tls/dubbo/go-server/conf/dubbogo.yml, <others..>"
   ```
   
   In order to make it more convenient to maintain, you could create an array to contain those config paths. Eventually, it looks like this:
   
   ```bash
   tls_configs=("config path1" "config path2")
   for (( i=0; i<${#tls_configs[@]}; i++ ))
   do
     sed -i 's#../../../x509#'"$(pwd)/tls/x509"'#g' ${tls_configs[i]}
     echo "${tls_configs[i]}: The prefix of certificate path was replaced to \"$(pwd)/tls/x509\""
   done
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go-samples] justxuewei merged pull request #523: feat: protobuf v2 integrate test

Posted by "justxuewei (via GitHub)" <gi...@apache.org>.
justxuewei merged PR #523:
URL: https://github.com/apache/dubbo-go-samples/pull/523


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org