You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ratis.apache.org by GitBox <gi...@apache.org> on 2020/12/25 12:35:49 UTC

[GitHub] [incubator-ratis] ferhui opened a new pull request #377: RATIS-1267. Fix ratis examples after supporting streaming

ferhui opened a new pull request #377:
URL: https://github.com/apache/incubator-ratis/pull/377


   ## What changes were proposed in this pull request?
   
   (Please fill in changes proposed in this fix)
   
   ## What is the link to the Apache JIRA
   
   (Please create an issue in ASF JIRA before opening a pull request,
   and you need to set the title of the pull request which starts with
   the corresponding JIRA issue number. (e.g. RATIS-XXXX. Fix a typo in YYY.)
   
   Please replace this section with the link to the Apache JIRA)
   
   ## How was this patch tested?
   
   (Please explain how this patch was tested. Ex: unit tests, manual tests)
   (If this patch involves UI changes, please attach a screen-shot; otherwise, remove this)
   


----------------------------------------------------------------
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.

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



[GitHub] [incubator-ratis] szetszwo merged pull request #377: RATIS-1267. Fix ratis examples after supporting streaming

Posted by GitBox <gi...@apache.org>.
szetszwo merged pull request #377:
URL: https://github.com/apache/incubator-ratis/pull/377


   


----------------------------------------------------------------
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.

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



[GitHub] [incubator-ratis] szetszwo commented on pull request #377: RATIS-1267. Fix ratis examples after supporting streaming

Posted by GitBox <gi...@apache.org>.
szetszwo commented on pull request #377:
URL: https://github.com/apache/incubator-ratis/pull/377#issuecomment-751257201


   @ferhui , thanks a lot for working on this.  We should make Streaming port optional for these examples since they are not using Streaming.


----------------------------------------------------------------
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.

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



[GitHub] [incubator-ratis] ferhui commented on pull request #377: RATIS-1267. Fix ratis examples after supporting streaming

Posted by GitBox <gi...@apache.org>.
ferhui commented on pull request #377:
URL: https://github.com/apache/incubator-ratis/pull/377#issuecomment-751590617


   @szetszwo Thanks for review! 
   New commits:
   
   - datastream port is optional
   - fix client argument
   


----------------------------------------------------------------
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.

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



[GitHub] [incubator-ratis] runzhiwang commented on a change in pull request #377: RATIS-1267. Fix ratis examples after supporting streaming

Posted by GitBox <gi...@apache.org>.
runzhiwang commented on a change in pull request #377:
URL: https://github.com/apache/incubator-ratis/pull/377#discussion_r549242773



##########
File path: ratis-examples/src/main/java/org/apache/ratis/examples/common/SubCommandBase.java
##########
@@ -43,8 +43,12 @@
   public static RaftPeer[] parsePeers(String peers) {
     return Stream.of(peers.split(",")).map(address -> {
       String[] addressParts = address.split(":");
-      return RaftPeer.newBuilder().setId(addressParts[0]).setAddress(addressParts[1] + ":" + addressParts[2])
-          .setDataStreamAddress(addressParts[1] + ":" + addressParts[3]).build();
+      RaftPeer.Builder builder = RaftPeer.newBuilder();
+      builder.setId(addressParts[0]).setAddress(addressParts[1] + ":" + addressParts[2]);

Review comment:
       maybe we can override parsePeers in DataStream.java 




----------------------------------------------------------------
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.

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