Skip to content

Conversation

@gionn
Copy link
Member

@gionn gionn commented May 6, 2025

@gionn gionn self-assigned this May 6, 2025
@gionn gionn changed the title Fix jdbc driver class not propagated to repo/sync roles OPSEXP-3233 Fix jdbc driver class not propagated to repo/sync roles May 7, 2025
@jalvarezferr
Copy link

Shouldn't group_vars of repository and syncservice set the driver class value based on the values of acs_play_repo_db_driver and acs_play_sync_db_driver respectively?

repository.yml:

acs_play_repository_jdbc_driver_class: "{{ acs_play_repo_db_driver | default(default_jdbc_pg_driver_class) }}"

syncservice.yml:

acs_play_sync_jdbc_driver_class: "{{ acs_play_sync_db_driver | default(default_jdbc_pg_driver_class) }}"

Without that, unless we explicitly set acs_play_repository_jdbc_driver_class and acs_play_sync_jdbc_driver_class in extra vars, the role will receive the group_vars values which will be aqain the default (for PostgreSQL). In our previous solution this did not happen as repository_jdbc_driver_class was not propagated and we fixed it in the defaults of the role.

The change made to the deployment document, indicating to set acs_play_repository_jdbc_driver_class directly, does not comply with the naming convention of all other external variables. With the change I mention the external variable would remain as it was.

@gionn gionn force-pushed the fix-1171-custom-jdbc branch 5 times, most recently from 1c19ba2 to 6ae7c9c Compare May 8, 2025 15:37
@gionn gionn force-pushed the fix-1171-custom-jdbc branch from 6ae7c9c to 6bf3207 Compare May 8, 2025 15:39
@gionn gionn requested a review from pmacius May 8, 2025 15:41
@gionn
Copy link
Member Author

gionn commented May 8, 2025

what was really confusing me is that both:

  • acs_play_repository_jdbc_driver_class
  • acs_play_sync_jdbc_driver_class

are defined as group_vars for their respective groups but never really used.

So I decided to simply get rid of them and make sure the previous acs_play_repo_db_driver and acs_play_sync_db_driver are properly propagated to their respective role arguments.

@gionn gionn requested a review from alxgomz May 8, 2025 15:48
@gionn gionn force-pushed the fix-1171-custom-jdbc branch from c1cb207 to 391fa0e Compare May 13, 2025 08:39
@gionn gionn added the ec2-test Triggers ec2 integrations tests label May 13, 2025
@gionn gionn marked this pull request as ready for review May 13, 2025 08:57
@gionn gionn removed the ec2-test Triggers ec2 integrations tests label May 13, 2025
@gionn gionn requested a review from alxgomz May 13, 2025 09:55
@gionn gionn merged commit 6bd8270 into master May 13, 2025
125 of 127 checks passed
@gionn gionn deleted the fix-1171-custom-jdbc branch May 13, 2025 14:19
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.

Fails with Custom databases other than PostgreSQL

5 participants