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

Prevent issue where micronaut-data-tx was required on the classpath #72

Merged
merged 7 commits into from
Mar 3, 2023

Conversation

sdelamo
Copy link
Contributor

@sdelamo sdelamo commented Mar 1, 2023

In #68 it was discovered that we assumed micronaut-data-tx was on the classpath, and if this was not the case, the application would fail with a ClassNotFoundException

This change introduces resolvers which fetch the HikariDataSource if one exists (unwrapping from a DelegatingDataSource if one exists) without requiring them both on the classpath.

@timyates timyates changed the base branch from master to 1.2.x March 1, 2023 12:01
@timyates timyates self-assigned this Mar 1, 2023
@timyates timyates added the type: bug Something isn't working label Mar 1, 2023
@timyates timyates added this to the 1.2.0 milestone Mar 1, 2023
@timyates timyates linked an issue Mar 1, 2023 that may be closed by this pull request
@timyates timyates changed the title DataSourceResolver Prevent issue where micronaut-data-tx was required on the classpath Mar 1, 2023
@timyates timyates marked this pull request as ready for review March 1, 2023 14:34
@timyates
Copy link
Contributor

timyates commented Mar 1, 2023

@sdelamo Ready for review I think

@timyates
Copy link
Contributor

timyates commented Mar 1, 2023

IntelliJ says we have 81% coverage overall... I suspect Sonar isn't taking the test-suites into account 🤔

Copy link
Contributor Author

@sdelamo sdelamo left a comment

Choose a reason for hiding this comment

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

I am not sure about this @timyates what do you think about #73 ?

* Simplify composite

* Extract common code to method

---------

Co-authored-by: Tim Yates <[email protected]>
@sonarqubecloud
Copy link

sonarqubecloud bot commented Mar 3, 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

70.5% 70.5% Coverage
0.0% 0.0% Duplication

@timyates timyates merged commit 4758b1f into 1.2.x Mar 3, 2023
@timyates timyates deleted the jooq branch March 3, 2023 13:37
@sdelamo
Copy link
Contributor Author

sdelamo commented Mar 6, 2023

@timyates This PR should have been merged with squash and merge.

@timyates
Copy link
Contributor

timyates commented Mar 6, 2023

🙀 Sorry about that :-(

timyates added a commit that referenced this pull request Mar 7, 2023
We fixed #68 in #72 for micronaut-crac 1.2.0

This backports that fix to 1.1.2 so we can include it in Micronaut 3.8.7
sdelamo pushed a commit that referenced this pull request Mar 7, 2023
We fixed #68 in #72 for micronaut-crac 1.2.0

This backports that fix to 1.1.2 so we can include it in Micronaut 3.8.7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something isn't working
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

StartupCracRegistration failing when used with hikari + jooq
2 participants