Skip to content

Conversation

@dfordivam
Copy link
Contributor

Fixes #3555

I implemented the deduplication slightly different than initially discussed.
Here I a new shared mixin trait with the DB sql API.
More APIs could be implemented in this for the TransferInputStore, though I did not do that as part of this PR, to keep the changes minimal.

Pull Request Checklist

Cluster Testing

  • If a cluster test is required, comment /cluster_test on this PR to request it, and ping someone with access to the DA-internal system to approve it.
  • If a hard-migration test is required (from the latest release), comment /hdm_test on this PR to request it, and ping someone with access to the DA-internal system to approve it.

PR Guidelines

  • Include any change that might be observable by our partners or affect their deployment in the release notes.
  • Specify fixed issues with Fixes #n, and mention issues worked on using #n
  • Include a screenshot for frontend-related PRs - see README or use your favorite screenshot tool

Merge Guidelines

  • Make the git commit message look sensible when squash-merging on GitHub (most likely: just copy your PR description).

Signed-off-by: Divam <dfordivam@gmail.com>
- Add MintingDelegationCollectRewardsTrigger
- Bump version of DbExternalPartyWalletStore
- Bump version of DbUserWalletStore

Squashed commits from the PR reviewed in #3470

Signed-off-by: Divam <dfordivam@gmail.com>
Squashed commits from PR reviewed in #3598

Signed-off-by: Divam <dfordivam@gmail.com>
Signed-off-by: Divam <dfordivam@gmail.com>
Extracted duplicated listSortedRewardCoupons method from DbUserWalletStore and
DbExternalPartyWalletStore into a new shared mixin trait.

Signed-off-by: Divam <dfordivam@gmail.com>
Signed-off-by: Divam <dfordivam@gmail.com>
@dfordivam dfordivam requested a review from meiersi-da January 22, 2026 06:11
Copy link
Contributor

@meiersi-da meiersi-da left a comment

Choose a reason for hiding this comment

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

Thanks a lot. Looks good to me.

@OriolMunoz-da : could you do the final approval on this refactoring given that you are one of the core maintainers of this piece of code, and have more Scala experience than I have?

Copy link
Contributor

@OriolMunoz-da OriolMunoz-da left a comment

Choose a reason for hiding this comment

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

lgtm, very minor comments about the comments/docs

issuingRoundsMap: Map[Round, IssuingMiningRound],
roundToIssuance: IssuingMiningRound => Option[BigDecimal],
limit: Limit,
ccValue: SQLActionBuilder = sql"rti.issuance",
Copy link
Contributor

Choose a reason for hiding this comment

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

is this value different anywhere? It's the same on this PR - fine to keep if it's a change necessary for a later PR

Copy link
Contributor Author

@dfordivam dfordivam Jan 23, 2026

Choose a reason for hiding this comment

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

It's same, and I am not sure if it would differ in future. Nevertheless I kept the code identical to the existing UserWallet store's to minimize diffs.

dfordivam added a commit that referenced this pull request Jan 23, 2026
Extracted duplicated listSortedRewardCoupons method from DbUserWalletStore and
DbExternalPartyWalletStore into a new shared mixin trait.

PR reviewed in #3646

Signed-off-by: Divam <dfordivam@gmail.com>
@dfordivam dfordivam force-pushed the dfordivam/feature-cip-73-minting-delegation branch from 98c805c to f919249 Compare January 23, 2026 04:43
@dfordivam
Copy link
Contributor Author

Closing this as commits have been squashed and put on the feature branch dfordivam/feature-cip-73-minting-delegation

@dfordivam dfordivam closed this Jan 23, 2026
dfordivam added a commit that referenced this pull request Jan 23, 2026
Extracted duplicated listSortedRewardCoupons method from DbUserWalletStore and
DbExternalPartyWalletStore into a new shared mixin trait.

PR reviewed in #3646

Signed-off-by: Divam <dfordivam@gmail.com>
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.

4 participants