Skip to content

[BEAM-4776] consolidate MetricResult implementations - #7890

Merged
mxm merged 1 commit into
apache:masterfrom
ryan-williams:ac
Feb 22, 2019
Merged

mxm merged 1 commit into
apache:masterfrom
ryan-williams:ac

Conversation

@ryan-williams

@ryan-williams ryan-williams commented Feb 19, 2019 •

Copy link
Copy Markdown
Contributor

(factored out of #7823)

This simplifies something I found confusing while learning how the Java SDK metrics worked: there were many implementations of MetricResult laying around, all with almost the same semantics (and a fair amount of copy-paste having happened between them).

I think I've reduced this to a minimal interface here:

  • keyed by "step name" (@Nullable, for pcollection-scoped system metrics; first-class support of these is coming in [DO NOT MERGE] [BEAM-4775] Second take on portable metrics over the job-server API #7823) and MetricName (namespace, name)
  • containing an "attempted" value and (possibly null / "unsupported") "committed" value
    • throws UnsupportedOperationException on attempting to access absent/unsupported "committed" value
  • buildable from MetricUpdates, including a transient interim step where "attempted" but not "committed" may be set, for a MetricResult that will ultimately contain both.

R: @robertwb, @ajamato

I'll CC @mxm @tweise as well since I've sent a bunch to Robert/Alex on this topic, and this one doesn't directly involve the new metrics API design

Post-Commit Tests Status (on master branch)

Lang SDK Apex Dataflow Flink Gearpump Samza Spark
Go Build Status --- --- --- --- --- ---
Java 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 --- --- ---

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

@ajamato ajamato left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Good code deletion

@ryan-williams

Copy link
Copy Markdown
Contributor Author

Run Java_Examples_Dataflow PreCommit

@ryan-williams

Copy link
Copy Markdown
Contributor Author

Looks like flaky tests:

:beam-runners-google-cloud-dataflow-java-examples-streaming:preCommit FAILED
--
 
org.apache.beam.examples.WordCountIT > testE2EWordCount FAILED
java.lang.RuntimeException at WordCountIT.java:69
Caused by: java.io.IOException at WordCountIT.java:69
 
1 test completed, 1 failed

:beam-runners-google-cloud-dataflow-java-examples:preCommitLegacyWorker FAILED
-- 
org.apache.beam.examples.WordCountIT > testE2EWordCount FAILED
java.lang.RuntimeException at WordCountIT.java:69
Caused by: java.io.IOException at WordCountIT.java:69
 
4 tests completed, 1 failed

@mxm mxm left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good!

@mxm
mxm merged commit 692d2ef into apache:master Feb 22, 2019
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.

3 participants