Interface Effect - Why "The provider has visibility on all sub-transactions triggered by `Claim`\ing an effect."?
- jvelasco.intellecteuOP
Hi,
Probably I’m missing something but I don’t understand why “The provider has visibility on all sub-transactions triggered by
Claim\ing an effect.”module Daml.Finance.Interface.Lifecycle.Effectchoice SetProviders : ContractId Effect -- ^ Set the provider of the effect. The provider has visibility on all sub-transactions -- triggered by `Claim`\ing an effect. with newProviders : Parties -- ^ The new provider. controller (view this).providers, newProviders do setProviders this argI see that when claimer exercises
ClaimEffectpasses theEffect.Icid as a parameter. In the default implementation ofDaml.Finance.Interface.Lifecycle.Rule.Claim.Claimthe effect cid is used for getting its view and calculating (Calculatechoice) the instrument quantities to settle which are just quantities (no info about holdings or owners). As far as I understand, sub-transaction privacy applies here forGetViewandCalculateexercises onEffect.I. So I would say that the provider of the Effect won’t
have “visibility on all sub-transactions triggered byClaim\ing an effect”.I’ve modified a bit the test
runIntermediatedLifecyclingNonAtomicon moduleDaml.Finance.Instrument.Generic.Test.Intermediated.BondCouponin order to check all this.- In
EffectSettlementService.ClaimAndSettlechoice instead of creating a new effect with new providers I keep the same Effect (provider = issuer) for the lifecycling/settlement of csd/investor. - After running the lifecycling/settlement of csd/investor using the original Effect (provider = issuer), I see that sensitive information like holdings, instructions and batch is not revealed to the issuer (Effect’s provider)
Am I missing something or the statement in
SetProvidersdocumentation is not correct?Thanks
Jose - In
- Matteo_Limberto 1
Thank you for spotting this. The documentation is indeed not correct, I will open a PR to fix it.
Matteo