You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@impala.apache.org by "Joe McDonnell (Code Review)" <ge...@cloudera.org> on 2018/06/22 00:56:49 UTC

[Impala-ASF-CR] Add scripts to create code coverage reports

Joe McDonnell has uploaded this change for review. ( http://gerrit.cloudera.org:8080/10791


Change subject: Add scripts to create code coverage reports
......................................................................

Add scripts to create code coverage reports

gcovr is a python library that uses gcov to generate
code coverage reports. This adds gcovr to the python
dependencies and adds bin/impala-gcovr to provide
easy access to gcovr's command line. gcovr 3.4
supports python 2.6+.

This also adds bin/coverage_helper.sh to provide a
simplified interface to generate reports and zero
coverage counters.

Code coverage data is written out when a program
exits, so it is important to avoid hard kills
to shut down the impalads when generating coverage.
This modifies testdata/bin/kill-all.sh to call
start-impala-cluster.py --kill when shutting down
the minicluster to try to avoid doing a hard kill.
It will still do a hard kill if impala is still
running after the softer kill.

Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
---
A bin/coverage_helper.sh
A bin/impala-gcovr
M infra/python/deps/requirements.txt
M testdata/bin/kill-all.sh
4 files changed, 111 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/91/10791/1
-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 1
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>

[Impala-ASF-CR] IMPALA-7199: Add scripts to create code coverage reports

Posted by "Joe McDonnell (Code Review)" <ge...@cloudera.org>.
Joe McDonnell has posted comments on this change. ( http://gerrit.cloudera.org:8080/10791 )

Change subject: IMPALA-7199: Add scripts to create code coverage reports
......................................................................


Patch Set 2:

(2 comments)

http://gerrit.cloudera.org:8080/#/c/10791/2/bin/coverage_helper.sh
File bin/coverage_helper.sh:

http://gerrit.cloudera.org:8080/#/c/10791/2/bin/coverage_helper.sh@44
PS2, Line 44:        shift;
> is that semicolon doing anything?
Removed (I copy/pasted from buildall.sh)


http://gerrit.cloudera.org:8080/#/c/10791/2/bin/coverage_helper.sh@51
PS2, Line 51:   shift;
> I don't think that semicolon needs to be tehre?
Removed



-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 2
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Philip Zeyliger <ph...@cloudera.com>
Gerrit-Comment-Date: Mon, 16 Jul 2018 21:51:40 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-7199: Add scripts to create code coverage reports

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/10791 )

Change subject: IMPALA-7199: Add scripts to create code coverage reports
......................................................................


Patch Set 3:

Build started: https://jenkins.impala.io/job/gerrit-verify-dryrun/2818/ DRY_RUN=true


-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 3
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Philip Zeyliger <ph...@cloudera.com>
Gerrit-Comment-Date: Mon, 16 Jul 2018 21:52:46 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-7199: Add scripts to create code coverage reports

Posted by "Joe McDonnell (Code Review)" <ge...@cloudera.org>.
Joe McDonnell has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/10791 )

Change subject: IMPALA-7199: Add scripts to create code coverage reports
......................................................................

IMPALA-7199: Add scripts to create code coverage reports

gcovr is a python library that uses gcov to generate
code coverage reports. This adds gcovr to the python
dependencies and adds bin/impala-gcovr to provide
easy access to gcovr's command line. gcovr 3.4
supports python 2.6+.

This also adds bin/coverage_helper.sh to provide a
simplified interface to generate reports and zero
coverage counters.

Code coverage data is written out when a program
exits, so it is important to avoid hard kills
to shut down the impalads when generating coverage.
This modifies testdata/bin/kill-all.sh to call
start-impala-cluster.py --kill when shutting down
the minicluster to try to avoid doing a hard kill.
It will still do a hard kill if impala is still
running after the softer kill.

Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Reviewed-on: http://gerrit.cloudera.org:8080/10791
Reviewed-by: Joe McDonnell <jo...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
A bin/coverage_helper.sh
A bin/impala-gcovr
M infra/python/deps/requirements.txt
M testdata/bin/kill-all.sh
4 files changed, 111 insertions(+), 0 deletions(-)

Approvals:
  Joe McDonnell: Looks good to me, approved
  Impala Public Jenkins: Verified

-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 4
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Philip Zeyliger <ph...@cloudera.com>

[Impala-ASF-CR] IMPALA-7199: Add scripts to create code coverage reports

Posted by "Philip Zeyliger (Code Review)" <ge...@cloudera.org>.
Philip Zeyliger has posted comments on this change. ( http://gerrit.cloudera.org:8080/10791 )

Change subject: IMPALA-7199: Add scripts to create code coverage reports
......................................................................


Patch Set 2: Code-Review+2

(2 comments)

http://gerrit.cloudera.org:8080/#/c/10791/2/bin/coverage_helper.sh
File bin/coverage_helper.sh:

http://gerrit.cloudera.org:8080/#/c/10791/2/bin/coverage_helper.sh@44
PS2, Line 44:        shift;
is that semicolon doing anything?


http://gerrit.cloudera.org:8080/#/c/10791/2/bin/coverage_helper.sh@51
PS2, Line 51:   shift;
I don't think that semicolon needs to be tehre?



-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 2
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Philip Zeyliger <ph...@cloudera.com>
Gerrit-Comment-Date: Fri, 06 Jul 2018 21:47:41 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-7199: Add scripts to create code coverage reports

Posted by "Joe McDonnell (Code Review)" <ge...@cloudera.org>.
Hello Philip Zeyliger, 

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/10791

to look at the new patch set (#2).

Change subject: IMPALA-7199: Add scripts to create code coverage reports
......................................................................

IMPALA-7199: Add scripts to create code coverage reports

gcovr is a python library that uses gcov to generate
code coverage reports. This adds gcovr to the python
dependencies and adds bin/impala-gcovr to provide
easy access to gcovr's command line. gcovr 3.4
supports python 2.6+.

This also adds bin/coverage_helper.sh to provide a
simplified interface to generate reports and zero
coverage counters.

Code coverage data is written out when a program
exits, so it is important to avoid hard kills
to shut down the impalads when generating coverage.
This modifies testdata/bin/kill-all.sh to call
start-impala-cluster.py --kill when shutting down
the minicluster to try to avoid doing a hard kill.
It will still do a hard kill if impala is still
running after the softer kill.

Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
---
A bin/coverage_helper.sh
A bin/impala-gcovr
M infra/python/deps/requirements.txt
M testdata/bin/kill-all.sh
4 files changed, 111 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/91/10791/2
-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 2
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Philip Zeyliger <ph...@cloudera.com>

[Impala-ASF-CR] IMPALA-7199: Add scripts to create code coverage reports

Posted by "Joe McDonnell (Code Review)" <ge...@cloudera.org>.
Joe McDonnell has posted comments on this change. ( http://gerrit.cloudera.org:8080/10791 )

Change subject: IMPALA-7199: Add scripts to create code coverage reports
......................................................................


Patch Set 3: Code-Review+2

Carry +2


-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 3
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Philip Zeyliger <ph...@cloudera.com>
Gerrit-Comment-Date: Mon, 16 Jul 2018 21:52:25 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] Add scripts to create code coverage reports

Posted by "Joe McDonnell (Code Review)" <ge...@cloudera.org>.
Joe McDonnell has posted comments on this change. ( http://gerrit.cloudera.org:8080/10791 )

Change subject: Add scripts to create code coverage reports
......................................................................


Patch Set 1:

(3 comments)

Made this into a JIRA IMPALA-7199. There is example output in a tarball there.

http://gerrit.cloudera.org:8080/#/c/10791/1/bin/coverage_helper.sh
File bin/coverage_helper.sh:

http://gerrit.cloudera.org:8080/#/c/10791/1/bin/coverage_helper.sh@1
PS1, Line 1: #!/bin/bash
> I'm increasingly of the opinion that we should just start with python for t
I'll take a look at how that would be.


http://gerrit.cloudera.org:8080/#/c/10791/1/bin/coverage_helper.sh@24
PS1, Line 24: REPORT_DIRECTORY=${IMPALA_HOME}/logs/coverage
> Does something mkdir -p this?
I do this down in the REPORT_ACTION = 1 block.


http://gerrit.cloudera.org:8080/#/c/10791/1/bin/coverage_helper.sh@30
PS1, Line 30:   echo "[-reportdirectory] : Output directory for coverage report files"
> Indicate that this takes an argument?
Done



-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 1
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Philip Zeyliger <ph...@cloudera.com>
Gerrit-Comment-Date: Fri, 22 Jun 2018 22:47:48 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] Add scripts to create code coverage reports

Posted by "Philip Zeyliger (Code Review)" <ge...@cloudera.org>.
Philip Zeyliger has posted comments on this change. ( http://gerrit.cloudera.org:8080/10791 )

Change subject: Add scripts to create code coverage reports
......................................................................


Patch Set 1: Code-Review+1

(3 comments)

Looks fine to me. I'd love to see some demo output at some point.

http://gerrit.cloudera.org:8080/#/c/10791/1/bin/coverage_helper.sh
File bin/coverage_helper.sh:

http://gerrit.cloudera.org:8080/#/c/10791/1/bin/coverage_helper.sh@1
PS1, Line 1: #!/bin/bash
I'm increasingly of the opinion that we should just start with python for this kind of thing. You'll save on lines 26-52 by using more obvious argparse, for example.


http://gerrit.cloudera.org:8080/#/c/10791/1/bin/coverage_helper.sh@24
PS1, Line 24: REPORT_DIRECTORY=${IMPALA_HOME}/logs/coverage
Does something mkdir -p this?


http://gerrit.cloudera.org:8080/#/c/10791/1/bin/coverage_helper.sh@30
PS1, Line 30:   echo "[-reportdirectory] : Output directory for coverage report files"
Indicate that this takes an argument?



-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 1
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Philip Zeyliger <ph...@cloudera.com>
Gerrit-Comment-Date: Fri, 22 Jun 2018 16:48:04 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-7199: Add scripts to create code coverage reports

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/10791 )

Change subject: IMPALA-7199: Add scripts to create code coverage reports
......................................................................


Patch Set 3: Verified+1


-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 3
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Philip Zeyliger <ph...@cloudera.com>
Gerrit-Comment-Date: Tue, 17 Jul 2018 01:12:23 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-7199: Add scripts to create code coverage reports

Posted by "Joe McDonnell (Code Review)" <ge...@cloudera.org>.
Hello Philip Zeyliger, 

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/10791

to look at the new patch set (#3).

Change subject: IMPALA-7199: Add scripts to create code coverage reports
......................................................................

IMPALA-7199: Add scripts to create code coverage reports

gcovr is a python library that uses gcov to generate
code coverage reports. This adds gcovr to the python
dependencies and adds bin/impala-gcovr to provide
easy access to gcovr's command line. gcovr 3.4
supports python 2.6+.

This also adds bin/coverage_helper.sh to provide a
simplified interface to generate reports and zero
coverage counters.

Code coverage data is written out when a program
exits, so it is important to avoid hard kills
to shut down the impalads when generating coverage.
This modifies testdata/bin/kill-all.sh to call
start-impala-cluster.py --kill when shutting down
the minicluster to try to avoid doing a hard kill.
It will still do a hard kill if impala is still
running after the softer kill.

Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
---
A bin/coverage_helper.sh
A bin/impala-gcovr
M infra/python/deps/requirements.txt
M testdata/bin/kill-all.sh
4 files changed, 111 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/91/10791/3
-- 
To view, visit http://gerrit.cloudera.org:8080/10791
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I5b2e0b794c64f9343ec976de7a3f235e54d2badd
Gerrit-Change-Number: 10791
Gerrit-PatchSet: 3
Gerrit-Owner: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Joe McDonnell <jo...@cloudera.com>
Gerrit-Reviewer: Philip Zeyliger <ph...@cloudera.com>