Closed Bug 1175115 Opened 9 years ago Closed 8 years ago

Spark API for telemetry needs proper test coverage

Categories

(Cloud Services Graveyard :: Metrics: Pipeline, defect, P2)

defect

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: rvitillo, Assigned: mdoglio)

References

Details

(Whiteboard: spark)

The telemetry API can be found at [1]. As the API is slowly growing, we should write a proper test-suite for it.

[1] https://github.com/vitillo/python_moztelemetry/
Writing tests is my favorite way to learn a code base, so I grabbed this. Feel free to reassign if it makes sense.
Assignee: nobody → spenrose
Priority: -- → P2
Whiteboard: spark
I am increasing the priority as the data validation depends on it.
Priority: P2 → P1
Assignee: spenrose → nobody
Iteration: --- → 43.1 - Aug 24
Iteration: 43.1 - Aug 24 → ---
Any progress on this?  I'm looking at adding support for derived streams, and it'd be nice to be able to test things before sending a possibly-broken PR :)
Sadly no.

(In reply to Mark Reid [:mreid] from comment #3)
> Any progress on this?  I'm looking at adding support for derived streams,
> and it'd be nice to be able to test things before sending a possibly-broken
> PR :)
My approach to testing this was:
1. Spin up a single-instance Spark cluster from telemetry-dash.mozilla.org
2. Copy over the modified files using scp
3. Restart the Spark kernel
4. Run the "Telemetry Hello World" notebook and make sure the results look OK.
Priority: P1 → P2
Blocks: 1251580
Blocks: 1255748
No longer blocks: 1251580
Assignee: nobody → mdoglio
No longer blocks: 1263189
:gfritzsche the python_moztelemetry library has a test suite already running in CI so
Summary: Spark API for telemetry needs proper test-suite → Spark API for telemetry needs proper test coverage
:gfritzsche the python_moztelemetry library has a test suite already running in CI so you should be able to add as many tests as you want to it. I fixed the bug title to reflect that. Can we remove bug 1264984 from the block list?
Flags: needinfo?(gfritzsche)
Depends on: 1283218, 1282803
Added some refactoring work to the block list because it would make it much easier to write unittest.
No longer depends on: 1283218
Now that bug 1282803 is fixed, the test coverage is 35% (was more or less 0% before). Another coverage bump up should come from solving bug 1288154.
The overall coverage is now 54%. As shown here [1], the modules used by get_pings have a very high coverage (93%, 100%) which is what matters the most.

[1]https://coveralls.io/github/mozilla/python_moztelemetry?branch=master
Status: NEW → RESOLVED
Closed: 8 years ago
Flags: needinfo?(gfritzsche)
Resolution: --- → FIXED
Product: Cloud Services → Cloud Services Graveyard
You need to log in before you can comment on or make changes to this bug.