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

Reduce repository access #2447

Merged
merged 8 commits into from
Feb 27, 2024
Merged

Reduce repository access #2447

merged 8 commits into from
Feb 27, 2024

Conversation

joerghoh
Copy link
Collaborator

Q                       A
Fixed Issues?
Patch: Bug Fix?
Minor: New Feature?
Major: Breaking Change?
Tests Added + Pass? Yes
Documentation Provided Yes (code comments and or markdown)
Any Dependency Changes? No
License Apache License, Version 2.0

Improve SlingModels to calculate values more lazily to avoid costly repository access for values, which might not be used at all.

@codecov
Copy link

codecov bot commented Feb 11, 2023

Codecov Report

Attention: Patch coverage is 82.50000% with 7 lines in your changes are missing coverage. Please review.

Project coverage is 87.21%. Comparing base (f28f5fd) to head (adde00b).

Files Patch % Lines
...m/core/components/internal/models/v1/PageImpl.java 82.75% 2 Missing and 3 partials ⚠️
...obe/cq/wcm/core/components/internal/LazyValue.java 75.00% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main    #2447      +/-   ##
============================================
- Coverage     87.28%   87.21%   -0.08%     
- Complexity     2659     2665       +6     
============================================
  Files           232      233       +1     
  Lines          7110     7123      +13     
  Branches       1084     1085       +1     
============================================
+ Hits           6206     6212       +6     
- Misses          359      362       +3     
- Partials        545      549       +4     

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

@joerghoh joerghoh requested review from jckautzmann, bpauli and vladbailescu and removed request for bpauli February 18, 2023 18:02
~ See the License for the specific language governing permissions and
~ limitations under the License.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
package com.adobe.cq.wcm.core.components.internal;
Copy link
Contributor

Choose a reason for hiding this comment

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

can this be moved outside of internal so that it can also be used in our proxy classes?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good point, although this would be an extension of the public API, and so I would like to have it at least discussed here. Will raise that point when this PR has been merged.

@sonarcloud
Copy link

sonarcloud bot commented Feb 25, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

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
No Duplication information No Duplication information

@Buuhuu Buuhuu added this to the 2.23.0 milestone Apr 21, 2023
@vladbailescu vladbailescu modified the milestones: 2.23.0, 2.24.0 Jun 2, 2023
@LSantha LSantha modified the milestones: 2.24.0, 2.24.1 Feb 14, 2024
@LSantha LSantha modified the milestones: 2.24.1, 2.24.2 Feb 21, 2024
Copy link

sonarcloud bot commented Feb 27, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

@LSantha
Copy link
Contributor

LSantha commented Feb 27, 2024

@joerghoh, LGTM, thank you.

@LSantha LSantha merged commit b90b3fa into main Feb 27, 2024
14 checks passed
@LSantha LSantha deleted the improvement/reduce-repo-access branch February 27, 2024 19:49
@vladbailescu vladbailescu modified the milestones: 2.24.4, 2.24.6 Mar 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants