You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@beam.apache.org by GitBox <gi...@apache.org> on 2022/04/13 21:36:08 UTC

[GitHub] [beam] denisecase opened a new pull request, #17369: Update programming-guide w/Java GroupByKey example

denisecase opened a new pull request, #17369:
URL: https://github.com/apache/beam/pull/17369

   Added the following content to provide a Java example at the end of section 4.2.2. GroupByKey.
   
   Using <span class="language-java">`GroupByKey`</span> is straightforward:
   	
   {{< highlight java >}}
   // The input PCollection.
    PCollection<KV<String, String>> mapped = ...;
   
   // Apply GroupByKey to the PCollection mapped.
   // Save the result as the PCollection reduced.
   PCollection<KV<String, Iterable<String>>> reduced = 
    mapped.apply(GroupByKey.<String, String>create());
   {{< /highlight >}}
   
   **Please** add a meaningful description for your change here
   
   Minor addition to assist new users with a GroupByKey example in Java. Specifically:
   
   Added the following content to provide a Java example at the end of section 4.2.2. GroupByKey.
   
   Using <span class="language-java">`GroupByKey`</span> is straightforward:
   	
   {{< highlight java >}}
   // The input PCollection.
    PCollection<KV<String, String>> mapped = ...;
   
   // Apply GroupByKey to the PCollection mapped.
   // Save the result as the PCollection reduced.
   PCollection<KV<String, Iterable<String>>> reduced = 
    mapped.apply(GroupByKey.<String, String>create());
   {{< /highlight >}}
   
   ------------------------
   
   Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:
   
    - [ ] [**Choose reviewer(s)**](https://beam.apache.org/contribute/#make-your-change) and mention them in a comment (`R: @username`).
    - [ ] Format the pull request title like `[BEAM-XXX] Fixes bug in ApproximateQuantiles`, where you replace `BEAM-XXX` with the appropriate JIRA issue, if applicable. This will automatically link the pull request to the issue.
    - [ ] Update `CHANGES.md` with noteworthy changes.
    - [ ] If this contribution is large, please file an Apache [Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   See the [Contributor Guide](https://beam.apache.org/contribute) for more tips on [how to make review process smoother](https://beam.apache.org/contribute/#make-reviewers-job-easier).
   
   To check the build health, please visit [https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md](https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md)
   
   GitHub Actions Tests Status (on master branch)
   ------------------------------------------------------------------------------------------------
   [![Build python source distribution and wheels](https://github.com/apache/beam/workflows/Build%20python%20source%20distribution%20and%20wheels/badge.svg?branch=master&event=schedule)](https://github.com/apache/beam/actions?query=workflow%3A%22Build+python+source+distribution+and+wheels%22+branch%3Amaster+event%3Aschedule)
   [![Python tests](https://github.com/apache/beam/workflows/Python%20tests/badge.svg?branch=master&event=schedule)](https://github.com/apache/beam/actions?query=workflow%3A%22Python+Tests%22+branch%3Amaster+event%3Aschedule)
   [![Java tests](https://github.com/apache/beam/workflows/Java%20Tests/badge.svg?branch=master&event=schedule)](https://github.com/apache/beam/actions?query=workflow%3A%22Java+Tests%22+branch%3Amaster+event%3Aschedule)
   
   See [CI.md](https://github.com/apache/beam/blob/master/CI.md) for more information about GitHub Actions CI.
   


-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] pcoet commented on pull request #17369: [BEAM-14320] Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
pcoet commented on PR #17369:
URL: https://github.com/apache/beam/pull/17369#issuecomment-1108910631

   LGTM. Thanks, @denisecase !


-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] TheNeuralBit merged pull request #17369: [BEAM-14320] Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
TheNeuralBit merged PR #17369:
URL: https://github.com/apache/beam/pull/17369


-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] denisecase commented on pull request #17369: [BEAM-14320] Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
denisecase commented on PR #17369:
URL: https://github.com/apache/beam/pull/17369#issuecomment-1108790583

   @pcoet - thanks again! Should be revised as requested - just line 1103.


-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] denisecase commented on a diff in pull request #17369: [BEAM-14320] Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
denisecase commented on code in PR #17369:
URL: https://github.com/apache/beam/pull/17369#discussion_r856478520


##########
website/www/site/content/en/documentation/programming-guide.md:
##########
@@ -1100,6 +1100,18 @@ tree, [2]
 Thus, `GroupByKey` represents a transform from a multimap (multiple keys to
 individual values) to a uni-map (unique keys to collections of values).
 
+Using <span class="language-java">`GroupByKey`</span> is straightforward:

Review Comment:
   Thank you @pcoet - will do



-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] asf-ci commented on pull request #17369: Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
asf-ci commented on PR #17369:
URL: https://github.com/apache/beam/pull/17369#issuecomment-1098512738

   Can one of the admins verify this patch?


-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] asf-ci commented on pull request #17369: Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
asf-ci commented on PR #17369:
URL: https://github.com/apache/beam/pull/17369#issuecomment-1098512731

   Can one of the admins verify this patch?


-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] pcoet commented on a diff in pull request #17369: [BEAM-14320] Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
pcoet commented on code in PR #17369:
URL: https://github.com/apache/beam/pull/17369#discussion_r856674033


##########
website/www/site/content/en/documentation/programming-guide.md:
##########
@@ -1100,7 +1100,7 @@ tree, [2]
 Thus, `GroupByKey` represents a transform from a multimap (multiple keys to
 individual values) to a uni-map (unique keys to collections of values).
 
-Using <span class="language-java">`GroupByKey`</span> is straightforward:
+<span class="language-java">Using `GroupByKey` is straightforward:

Review Comment:
   @denisecase Sorry, just this line, 1103, should be wrapped in `language-java` class.



-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] pcoet commented on a diff in pull request #17369: [BEAM-14320] Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
pcoet commented on code in PR #17369:
URL: https://github.com/apache/beam/pull/17369#discussion_r856392438


##########
website/www/site/content/en/documentation/programming-guide.md:
##########
@@ -1100,6 +1100,18 @@ tree, [2]
 Thus, `GroupByKey` represents a transform from a multimap (multiple keys to
 individual values) to a uni-map (unique keys to collections of values).
 
+Using <span class="language-java">`GroupByKey`</span> is straightforward:

Review Comment:
   @denisecase I believe you need to wrap this whole sentence in the "language-java" class, so that it only appears if Java is the selected language.



-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] kennknowles commented on pull request #17369: [BEAM-14320] Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
kennknowles commented on PR #17369:
URL: https://github.com/apache/beam/pull/17369#issuecomment-1105528933

   @pcoet maybe you would also take a look?


-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] denisecase commented on pull request #17369: Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
denisecase commented on PR #17369:
URL: https://github.com/apache/beam/pull/17369#issuecomment-1098528546

   Whitespace issues:
   
   16:41:46 ./website/www/site/content/en/documentation/programming-guide.md:1102:0: W202 Blank line contains whitespace
   
   16:41:46 ./website/www/site/content/en/documentation/programming-guide.md:1104:0: W202 Blank line contains whitespace
   
   16:41:46 ./website/www/site/content/en/documentation/programming-guide.md:1111:51: W201 Trailing whitespace
   


-- 
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: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] denisecase commented on pull request #17369: [BEAM-14320] Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
denisecase commented on PR #17369:
URL: https://github.com/apache/beam/pull/17369#issuecomment-1104320296

   R: @AydarZaynutdinov would you be willing to review 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.

To unsubscribe, e-mail: github-unsubscribe@beam.apache.org

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


[GitHub] [beam] denisecase commented on pull request #17369: [BEAM-14320] Update programming-guide w/Java GroupByKey example

Posted by GitBox <gi...@apache.org>.
denisecase commented on PR #17369:
URL: https://github.com/apache/beam/pull/17369#issuecomment-1109011568

   Thanks @pcoet and @TheNeuralBit - & many thanks to the Apache Beam team and their great product & documentation! 


-- 
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: github-unsubscribe@beam.apache.org

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