Skip to content

Conversation

@PawasChhokra
Copy link
Contributor

@PawasChhokra PawasChhokra commented Jun 4, 2021

New Features:

  1. This PR creates an interface inside Samza Beam Runner to get I/O information for a Samza Beam job.
  2. It also adds a PipelineJsonRenderer which renders the Beam DAG in JSON form.

Uses:

  1. The SamzaIOInfo interface can be implemented to emit I/O information of a Samza job. This is used by the PipelineJsonRenderer to add I/O information to the Beam DAG.
  2. The JSON renderer helps emit the Beam DAG in JSON form as a config.

These changes can be used in the visualization of the Beam pipeline.


Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

  • Choose reviewer(s) 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.

See the Contributor Guide for more tips on how to make review process smoother.

ValidatesRunner compliance status (on master branch)

Lang ULR Dataflow Flink Samza Spark Twister2
Go --- Build Status Build Status --- Build Status ---
Java Build Status Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Python --- Build Status
Build Status
Build Status
Build Status
Build Status
--- Build Status ---
XLang Build Status Build Status Build Status --- Build Status ---

Examples testing status on various runners

Lang ULR Dataflow Flink Samza Spark Twister2
Go --- --- --- --- --- --- ---
Java --- Build Status
Build Status
Build Status
--- --- --- --- ---
Python --- --- --- --- --- --- ---
XLang --- --- --- --- --- --- ---

Post-Commit SDK/Transform Integration Tests Status (on master branch)

Go Java Python
Build Status Build Status Build Status
Build Status
Build Status

Pre-Commit Tests Status (on master branch)

--- Java Python Go Website Whitespace Typescript
Non-portable Build Status
Build Status
Build Status
Build Status
Build Status
Build Status Build Status Build Status Build Status
Portable --- Build Status Build Status --- --- ---

See .test-infra/jenkins/README for trigger phrase, status and link of all Jenkins jobs.

GitHub Actions Tests Status (on master branch)

Build python source distribution and wheels
Python tests
Java tests

See CI.md for more information about GitHub Actions CI.

@kw2542
Copy link
Contributor

kw2542 commented Jun 4, 2021

Run Java PreCommit

@PawasChhokra PawasChhokra changed the title [BEAM-12453]: Add interface to access I/O topic information for a Samza Beam job [BEAM-12453]: Add interface to access I/O topic information for a Samza Beam job and PipelineJsonRenderer to create the JSON Beam DAG Jun 4, 2021
@kw2542
Copy link
Contributor

kw2542 commented Jun 16, 2021

Please fix the compilation error as well:

16:33:00 > Task :runners:samza:compileJava
16:33:00 /home/jenkins/jenkins-slave/workspace/beam_PreCommit_Java_Commit@2/src/runners/samza/src/main/java/org/apache/beam/runners/samza/renderer/PipelineJsonRenderer.java:52: error: [return.type.incompatible] incompatible types in return.
16:33:00     return null;
16:33:00            ^
16:33:00   type of expression: null (NullType)
16:33:00   method return type: @Initialized @NonNull String
16:33:00 /home/jenkins/jenkins-slave/workspace/beam_PreCommit_Java_Commit@2/src/runners/samza/src/main/java/org/apache/beam/runners/samza/renderer/PipelineJsonRenderer.java:74: error: [dereference.of.nullable] dereference of possibly-null reference node.getTransform()
16:33:00         escapeString(fullName.isEmpty() ? OUTERMOST_NODE : node.getTransform().getName()));
16:33:00                                                                             ^
16:33:00 /home/jenkins/jenkins-slave/workspace/beam_PreCommit_Java_Commit@2/src/runners/samza/src/main/java/org/apache/beam/runners/samza/renderer/PipelineJsonRenderer.java:103: error: [dereference.of.nullable] dereference of possibly-null reference node.getTransform()
16:33:00     writeLine("  \"shortName\":\"%s\",", escapeString(node.getTransform().getName()));
16:33:00                                                                        ^
16:33:00 /home/jenkins/jenkins-slave/workspace/beam_PreCommit_Java_Commit@2/src/runners/samza/src/main/java/org/apache/beam/runners/samza/renderer/PipelineJsonRenderer.java:116: error: [dereference.of.nullable] dereference of possibly-null reference node.getTransform()
16:33:00               if (node.getTransform().getAdditionalInputs().containsKey(key)) {

@aaltay
Copy link
Member

aaltay commented Jul 1, 2021

What is the next step on this PR?

Copy link
Contributor

@kw2542 kw2542 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

@xinyuiscool xinyuiscool left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks for the enhancements.

@xinyuiscool xinyuiscool merged commit 2b96f43 into apache:master Aug 12, 2021
PawasChhokra added a commit to PawasChhokra/beam that referenced this pull request Aug 27, 2021
…za Beam job and PipelineJsonRenderer to create the JSON Beam DAG (apache#14945)
dxichen pushed a commit to linkedin/beam that referenced this pull request Aug 27, 2021
* [BEAM-12453]: Add interface to access I/O topic information for a Samza Beam job and PipelineJsonRenderer to create the JSON Beam DAG (apache#14945)

* [BEAM-12757]: Remove call for Json Dag in Portable PipelineRunner as it's not supported yet (apache#15332)

* [BEAM-12772] Remove test implementation of SamzaIORegistrar (apache#15347)

* Increment project.version to 2.28.0.6
dxichen pushed a commit to linkedin/beam that referenced this pull request Sep 22, 2021
…za Beam job and PipelineJsonRenderer to create the JSON Beam DAG (apache#14945)

RB=2752723
G=samza-reviewers
R=xiliu,kwu
A=xiliu
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants