FINERACT-1576 GCP Cloud SQL Support#2285
FINERACT-1576 GCP Cloud SQL Support#2285IOhacker wants to merge 1 commit intoapache:developfrom IOhacker:FINERACT-1576
Conversation
|
Even though the changes will work I have some concerns about introducing them this way. This is probably the first step where we want to add support for a native cloud database and since IAM authentication is used, the database URL will be different than in regular cases. That way, we can very well decouple specifics to certain environments to separate classes without polluting existing classes with a lot of if statements. cc @vidakovic |
|
Arnold, I agree about avoiding the use of IF in favor of using a resolver.
Let me fix it.
Regards
Victor
El jue, 21 abr 2022 a las 3:27, Arnold Gálovics ***@***.***>)
escribió:
… Even though the changes will work I have some concerns about introducing
them this way.
This is probably the first step where we want to add support for a native
cloud database and since IAM authentication is used, the database URL will
be different than in regular cases.
Architecturally speaking, I'd envision a number of resolvers chained
together. Each resolver can decide in which environment it's running in and
create the appropriate datasource with all the configurations necessary.
For example we could have the currently supported regular datasource in a
DefaultDataSourceResolver or something. And then there's a
GcpDataSourceResolver. All these resolvers are in priority order, namely
the DefaultDataSourceResolver is the last one to be invoked.
The first resolver "taking" the invocation and creating the appropriate
datasource will stop the chain from continuing.
That way, we can very well decouple specifics to certain environments to
separate classes without polluting existing classes with a lot of if
statements.
What do you think?
cc @vidakovic <https://github.com/vidakovic>
—
Reply to this email directly, view it on GitHub
<#2285 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALD2ZAXKKN3KTXJIIZHANNDVGEGOXANCNFSM5TTKQWHA>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
|
This pull request seems to be stale. Are you still planning to work on it? We will automatically close it in 30 days. |
|
Closing as it's obsolete. Please reopen if you're planning to work on it. |
Description
GCP Cloud SQL Support has advantage for using a fully managed SQL environment, Cloud SQL on GCP supports MySQL & Postgresql. The Cloud SQL Connector for Java is a library that provides IAM-based authorization and encryption when connecting to a Cloud SQL instance. It can not provide a network path to a Cloud SQL instance if one is not already present. It is Apache licensed too. https://github.com/GoogleCloudPlatform/cloud-sql-jdbc-socket-factory
Checklist
Please make sure these boxes are checked before submitting your pull request - thanks!
Write the commit message as per https://github.com/apache/fineract/#pull-requests
Acknowledge that we will not review PRs that are not passing the build ("green") - it is your responsibility to get a proposed PR to pass the build, not primarily the project's maintainers.
Create/update unit or integration tests for verifying the changes made.
Follow coding conventions at https://cwiki.apache.org/confluence/display/FINERACT/Coding+Conventions.
Add required Swagger annotation and update API documentation at fineract-provider/src/main/resources/static/api-docs/apiLive.htm with details of any API changes
Submission is not a "code dump". (Large changes can be made "in repository" via a branch. Ask on the developer mailing list for guidance, if required.)
FYI our guidelines for code reviews are at https://cwiki.apache.org/confluence/display/FINERACT/Code+Review+Guide.