Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make some of the Java classes proper utilities #687

Conversation

vil02
Copy link
Contributor

@vil02 vil02 commented Oct 13, 2023

Purpose

Fixes: ballerina-platform/ballerina-library#4921.

Examples

Checklist

  • Linked to an issue
  • Updated the specification
  • Updated the changelog
  • Added tests
  • Checked native-image compatibility

vil02 added 2 commits October 13, 2023 16:48
Made the design cleaner by marking Java classes as `final`
and explicitly declaring their default constructors as `private`.
This change makes the code coverage reports more accurate.
Closes #4921.
@codecov
Copy link

codecov bot commented Oct 16, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (aea22ae) 80.58% compared to head (763c92f) 80.66%.

Additional details and impacted files
@@             Coverage Diff              @@
##             master     #687      +/-   ##
============================================
+ Coverage     80.58%   80.66%   +0.08%     
  Complexity      109      109              
============================================
  Files            45       45              
  Lines          3965     3961       -4     
  Branches        751      751              
============================================
  Hits           3195     3195              
+ Misses          516      512       -4     
  Partials        254      254              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sonarqubecloud
Copy link

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
6.7% 6.7% Duplication

idea Catch issues before they fail your Quality Gate with our IDE extension sonarlint SonarLint

@vil02
Copy link
Contributor Author

vil02 commented Oct 18, 2023

@niveathika I have updated this branch. Could you please approve the workflows again?

@niveathika
Copy link
Contributor

@vil02 since these classes are used in other DB connector, these changes must be migrated to ballerina distribution and verified before this can be merged.

@vil02
Copy link
Contributor Author

vil02 commented Oct 18, 2023

@vil02 since these classes are used in other DB connector, these changes must be migrated to ballerina distribution and verified before this can be merged.

@niveathika is there some action I need to take regarding that?

Copy link

github-actions bot commented Nov 2, 2023

This PR has been open for more than 15 days with no activity. This will be closed in 3 days unless the stale label is removed or commented.

@github-actions github-actions bot added the Stale label Nov 2, 2023
@vil02
Copy link
Contributor Author

vil02 commented Nov 2, 2023

@niveathika @daneshk could you please remove the stale label?

@github-actions github-actions bot removed the Stale label Nov 3, 2023
Copy link

This PR has been open for more than 15 days with no activity. This will be closed in 3 days unless the stale label is removed or commented.

@github-actions github-actions bot added the Stale label Nov 19, 2023
@vil02
Copy link
Contributor Author

vil02 commented Nov 19, 2023

@niveathika @daneshk could you please remove the stale label?

Please don't close.

@github-actions github-actions bot removed the Stale label Nov 20, 2023
Copy link

github-actions bot commented Dec 5, 2023

This PR has been open for more than 15 days with no activity. This will be closed in 3 days unless the stale label is removed or commented.

@github-actions github-actions bot added the Stale label Dec 5, 2023
@vil02
Copy link
Contributor Author

vil02 commented Dec 5, 2023

@niveathika @daneshk could you please remove the stale label?

Please don't close.

Also now.

@github-actions github-actions bot removed the Stale label Dec 6, 2023
Copy link

This PR has been open for more than 15 days with no activity. This will be closed in 3 days unless the stale label is removed or commented.

@github-actions github-actions bot added the Stale label Dec 21, 2023
Copy link

Closed PR due to inactivity for more than 18 days.

@github-actions github-actions bot closed this Dec 25, 2023
@vil02
Copy link
Contributor Author

vil02 commented Dec 26, 2023

😞

@niveathika is it possible to re-open this PR?

@ThisaruGuruge ThisaruGuruge reopened this Jan 17, 2024
Copy link

Quality Gate Failed Quality Gate failed

Failed conditions

5.5% Duplication on New Code (required ≤ 3%)

See analysis details on SonarCloud

@ThisaruGuruge
Copy link
Member

😞

@niveathika is it possible to re-open this PR?

We are really very sorry for the late reply. I have reopened this.

Copy link

github-actions bot commented Feb 1, 2024

This PR has been open for more than 15 days with no activity. This will be closed in 3 days unless the stale label is removed or commented.

@github-actions github-actions bot added the Stale label Feb 1, 2024
@vil02
Copy link
Contributor Author

vil02 commented Feb 1, 2024

@niveathika @daneshk could you please remove the stale label?

Please don't close.

Also now.

Also now.

@github-actions github-actions bot removed the Stale label Feb 2, 2024
@ThisaruGuruge
Copy link
Member

Also now.

Hi @vil02, it seems like the SonarCloud analysis has failed for your PR. Can you please check?

@vil02
Copy link
Contributor Author

vil02 commented Feb 6, 2024

Hi @vil02, it seems like the SonarCloud analysis has failed for your PR. Can you please check?

The complain from SonarCloud seems to a false positive. It complains that I have introduced a duplicated code. Sure... I have introduced private default constructors and other classes, like QueryProcessor, already have it. But it does not work like this.

In my opinion, this complain could be ignored. @ThisaruGuruge: what is you opinion?

@daneshk
Copy link
Member

daneshk commented Feb 8, 2024

Hi @vil02, it seems like the SonarCloud analysis has failed for your PR. Can you please check?

The complain from SonarCloud seems to a false positive. It complains that I have introduced a duplicated code. Sure... I have introduced private default constructors and other classes, like QueryProcessor, already have it. But it does not work like this.

In my opinion, this complain could be ignored. @ThisaruGuruge: what is you opinion?

Thanks for the contribution @vil02. SonarCloud complains about QueryProcessor which is not related to your fix. Let me check the usage of these classes in other db connectors and get back

Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@daneshk daneshk merged commit 7da2c15 into ballerina-platform:master Feb 22, 2024
8 checks passed
@vil02 vil02 deleted the 4921_make_some_java_classes_proper_utilities branch February 22, 2024 22:31
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.

Make some of the Java classes in module-sql proper utility classes
4 participants