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

refactor(router): remove id dependency from merchant connector account, dispute and mandate #5330

Conversation

Narayanbhat166
Copy link
Member

@Narayanbhat166 Narayanbhat166 commented Jul 16, 2024

Type of Change

  • Refactoring

Description

This PR changes the primary key of merchant_connector_account table from id to merchant_connector_id. This is the key that is generated by hyperswitch. So it is guranteed to be unique.

This PR also changes the primary key for dispute and mandate table from id to dispute_id and mandate_id respectively

Additional Changes

  • This PR modifies the database schema

Motivation and Context

Remove the dependency of id from the application

How did you test it?

  • Create an MCA and update any field in it. Ensure that the field is updated.
  • The other tables are not affected.

Checklist

  • I formatted the code cargo +nightly fmt --all
  • I addressed lints thrown by cargo clippy
  • I reviewed the submitted code

@Narayanbhat166 Narayanbhat166 added M-database-changes Metadata: This PR involves database schema changes C-refactor Category: Refactor labels Jul 16, 2024
@Narayanbhat166 Narayanbhat166 added this to the July 2024 Release milestone Jul 16, 2024
@Narayanbhat166 Narayanbhat166 self-assigned this Jul 16, 2024
@Narayanbhat166 Narayanbhat166 requested review from a team as code owners July 16, 2024 05:24
@Narayanbhat166 Narayanbhat166 changed the base branch from main to create-justfile-for-running-v2-migrations July 16, 2024 05:57
@sai-harsha-vardhan sai-harsha-vardhan changed the title refactor(merchant_connector_account): remove id dependency from merchant connector account refactor(merchant_connector_account): remove id dependency from merchant connector account, dispute and mandate Jul 16, 2024
@sai-harsha-vardhan sai-harsha-vardhan changed the title refactor(merchant_connector_account): remove id dependency from merchant connector account, dispute and mandate refactor(router): remove id dependency from merchant connector account, dispute and mandate Jul 16, 2024
@Narayanbhat166 Narayanbhat166 removed request for a team July 16, 2024 06:11
Base automatically changed from create-justfile-for-running-v2-migrations to main July 16, 2024 12:21
@Gnanasundari24 Gnanasundari24 added this pull request to the merge queue Jul 18, 2024
Merged via the queue into main with commit 6d74527 Jul 18, 2024
17 checks passed
@Gnanasundari24 Gnanasundari24 deleted the 5977-refactor-remove-id-dependency-from-merchant_connector_account branch July 18, 2024 09:55
pixincreate added a commit that referenced this pull request Jul 19, 2024
* 'main' of github.com:juspay/hyperswitch: (26 commits)
  refactor(core): change primary keys in user, user_roles and roles tables (#5374)
  chore(version): 2024.07.19.1
  refactor(connector): make the `original_authorized_amount` optional for MITs with `connector_mandate_details` (#5311)
  feat(connector): Plaid connector Integration (#3952)
  feat: encryption service integration to support batch encryption and decryption (#5164)
  refactor(core): change primary key of refund table (#5367)
  chore(version): 2024.07.19.0
  chore(postman): update Postman collection files
  Docs: Updating Error codes for documentation purposes (#5314)
  fix(core): [payouts] failure of payout retrieve when token is expired (#5362)
  build: remove unused dependencies (#5343)
  refactor(blocklist): change primary key of blocklist table (#5356)
  chore: Increasing log coverage for payment method list (#5042)
  refactor(routing): Remove backwards compatibility for the routing crate (#3015)
  refactor(merchant_account): change primary key for merchant account (#5327)
  refactor(router): remove id dependency from merchant connector account, dispute and mandate (#5330)
  feat(connector): [Itau Bank] Template for payment flows (#5304)
  chore(version): 2024.07.18.0
  refactor(router): Remove the locker call in the psync flow (#5348)
  feat(router): Add support for passing the domain dynamically in the session call (#5347)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-refactor Category: Refactor M-database-changes Metadata: This PR involves database schema changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants