Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Improved performance and stability of access to internal framework tables#417

Merged
jgebal merged 8 commits intoutPLSQL:developfrom
jgebal:feature/table_access_iprovements
Jul 28, 2017
Merged

Improved performance and stability of access to internal framework tables#417
jgebal merged 8 commits intoutPLSQL:developfrom
jgebal:feature/table_access_iprovements

Conversation

@jgebal
Copy link
Copy Markdown
Member

@jgebal jgebal commented Jul 22, 2017

When running coverage with several reporters the coverage reported by each of those was a but different.
This should be now resolved as the tmp table is populated only once per coverage run.

jgebal added 3 commits July 21, 2017 23:53
Moved temp tables cleanup into ut_utils (authid definer), so that we can use truncate rather then delete.
Refactored ut_coverage and ut_coverage_helper.
Changed the RunAll script to use packaged version of mystats.
@jgebal jgebal added this to the v3.1.0 milestone Jul 22, 2017
@jgebal jgebal requested review from Pazus and viniciusam July 22, 2017 00:43
@coveralls
Copy link
Copy Markdown

coveralls commented Jul 22, 2017

Coverage Status

Coverage increased (+0.5%) to 92.039% when pulling af5ae33 on jgebal:feature/table_access_iprovements into 55fe15f on utPLSQL:develop.

1 similar comment
@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage increased (+0.5%) to 92.039% when pulling af5ae33 on jgebal:feature/table_access_iprovements into 55fe15f on utPLSQL:develop.

g_coverage_id integer;
g_develop_mode boolean;
g_coverage_id integer;
g_develop_mode boolean := false;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

how about making it not null?

procedure coverage_stop is
l_return_code binary_integer;
begin
if not g_develop_mode then
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Is it correct to check for develop here? We are stoping coverage regardless of the mode, aren't we?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

No, not really.
We need to override coverage_stop in out unit tests (for now), so that when we test the framework, our "develop-mode" coverage will not stop, if we test execution for one of coverage reporters.

We will be able to remove the develop mode, once we move to testing ut3 with another ut3 installation.

It needs to stay like this for now, otherwise we will not get a true picture of coverage for out own code.

l_return_code binary_integer;
begin
l_return_code := dbms_profiler.stop_profiler();
g_develop_mode := false;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think we should call coverage_stop from here not to duplicate code

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

We can't, as described in previous comment.
The start_develop/stop_develop override and block start/stop of coverage gathering.

Comment thread source/core/coverage/ut_coverage.pkb Outdated
procedure coverage_start is
begin
ut_coverage_helper.coverage_start('utPLSQL Code coverage run '||ut_utils.to_string(systimestamp));
if not ut_coverage_helper.is_started() then
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

we schec the state here and perform the same check in tha package itself.
Maybe we can remove the chack from here and leave it only in ut_coverage_helper?

@coveralls
Copy link
Copy Markdown

coveralls commented Jul 22, 2017

Coverage Status

Coverage increased (+0.5%) to 92.113% when pulling 2185cec on jgebal:feature/table_access_iprovements into 55fe15f on utPLSQL:develop.

Copy link
Copy Markdown
Member

@Pazus Pazus left a comment

Choose a reason for hiding this comment

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

Left several comments in code

@jgebal jgebal changed the title Feature/table access iprovements Improved performance and stability of access to internal framework tables Jul 24, 2017
jgebal added 2 commits July 24, 2017 23:49
Changed order of processing in if statement to make sure query in `is_tmp_table_populated` is executed when running unit tests.
# Conflicts:
#	source/core/ut_utils.pkb
#	source/core/ut_utils.pks
@coveralls
Copy link
Copy Markdown

coveralls commented Jul 24, 2017

Coverage Status

Coverage increased (+0.8%) to 92.132% when pulling d609b36 on jgebal:feature/table_access_iprovements into 564a328 on utPLSQL:develop.

@coveralls
Copy link
Copy Markdown

coveralls commented Jul 27, 2017

Coverage Status

Coverage increased (+0.8%) to 92.132% when pulling 646b0b8 on jgebal:feature/table_access_iprovements into 33a6f45 on utPLSQL:develop.

…cess_iprovements

# Conflicts:
#	tests/lib/mystats/mystats_pkg.sql
@coveralls
Copy link
Copy Markdown

coveralls commented Jul 28, 2017

Coverage Status

Coverage increased (+0.8%) to 92.132% when pulling a8d4ac7 on jgebal:feature/table_access_iprovements into f5cc486 on utPLSQL:develop.

@jgebal jgebal merged commit 6a527c6 into utPLSQL:develop Jul 28, 2017
@jgebal jgebal deleted the feature/table_access_iprovements branch July 28, 2017 00:56
@Pazus Pazus modified the milestones: v3.0.3, v3.1.0 Aug 5, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants