-
Notifications
You must be signed in to change notification settings - Fork 15
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
Implement patch notification for failure scenarios (following v1.1 update) #2556
Comments
@mdebarros and I talked about this yesterday. There isn't enough information in the different For this reason, we decided that the central-ledger should emit a new notification message for this case, and the ml-api-adapter, if it's API version is |
@elnyry-sam-k @mdebarros I've written out 4 test cases above for the feature - can you please check that these are correct and add any that you think I've missed? |
hi Lewis, thanks for noting these - it helps the discussion..
Cases 1 & 3 fall under the same category - invalid values being sent for required fields; from FSPIOP v1.1 onwards, 'ABORTED' is an invalid value if used as a transferState in a fulfil request (the Payee FSP should use an error callback, a PUT on As you pointed out option-2 should be currently existing functionality. The last one option-4 is an interesting one. Right now yes, we're not sending a PATCH but we do |
There cannot be a synchronous response here (following schema validation) because ABORTED is a valid state for a transfer in general and it can be used in a PUT callback when it is sent in response to a |
@lewisdaly - In addition to the four scenarios you added, I'd suggest a scenario-5 where an invalid value is used for the |
That's annoying. I still don't understand why that case should result in a |
the last part is still correct Lewis, yes. As part of this story - we're looking at the patch only for transfers that use |
I'm having trouble locating the existing e2e test that demonstrates the payee FSP sending a |
I'm having trouble writing E2E tests for this - see #2624 |
hi @lewisdaly , will discuss this with Vijay today |
Story: mojaloop/project#2528 View change-log: https://github.com/mojaloop/helm/blob/release/v13.1.0/.changelog/release-v13.1.0.md **NOTE: This PR merge is for a candidate release.** 1. If you want to see the changes/features are to be included, consult the [v13.1.0 Release Report](https://github.com/mojaloop/project/issues#workspaces/mojaloop-ref-arch-59edee71d1407922110cf083/reports/release?release=Z2lkOi8vcmFwdG9yL1JlbGVhc2UvNjYzODQ). 2. Final release is blocked by the following missing feature: mojaloop/project#2556
I'm not able to continue working on this ticket. I got up to the point where I was writing the above TTK tests, and ran into issues setting up custom rules to help simulate the different scenarios. We later determined that this was an issue only on firefox, so this is no longer blocked. Once we have the updated TTK E2E tests, then we can be confident that this is working as expected, and finish up those open PRs. |
@lewisdaly, would you be so kind to give me write permissions to your forked repos so I can continue the work on this? I.e. resolving merge conflicts, etc. I would like to finalise these PRs ASAP! |
… scenarios (following v1.1 update) (#321) * feat(unit): adding test cases for RESERVED_ABORTED * feat(flow): add handling for notification/reserved-aborted to TopicMap * chore: remove consoles * chore: remove unused test * fix(vulns): run npm audit, ignore unfixable medium vulns for 1 month * chore: updated dependencies - updated dependencies - removed "@mojaloop/sdk-standard-components" from `ncurc.json` file - fixed lint issues Co-authored-by: Lewis Daly <lewis@vesselstech.com>
Hey it looks like you've just recreated my branches elsewhere? So you don't need me to do this? |
Yeah....decided to go with that approach. Sorry about that. Needed to get these PRs sorted, and it sounded like you were not going to be available for awhile due to travel :D/ |
Nah all good - thanks for sorting it out :) |
Added the following test-case scenarios for patch notifications: - p2p_money_transfer_patch_notifications - payee receives PATCH Notification with COMMITTED after sending callback with RESERVED - mojaloop/project#2676 - p2p_money_transfer_patch_notifications - payee receives PATCH Notification with ABORTED status after sending invalid fulfilment - mojaloop/project#2556
… scenarios (#874) PR re-based from #872 from @lewisdaly. feat(mojaloop/project/issue2556): Implement patch notification for failure scenarios (following v1.1 update) - mojaloop/project#2556 chore: updated dependencies - updated dependencies - fixed audit issues - fixed lint issues fix([#2697](mojaloop/project#2697)): Central-Ledger Fulfil Handler does not correctly invalidate requests with an incorrect/non-existent FSP-ID in the FSPIOP-Destination header - mojaloop/project#2697 - fixed/added unit tests - improved test coverage
… scenarios (#492) PR re-based from #489 from @lewisdaly. feat([mojaloop/project/issue](mojaloop/project#2556): Implement patch notification for failure scenarios (following v1.1 update) - mojaloop/project#2556 - fixed unit tests chore: updated dependencies - updated dependencies - fixed audit issues - fixed lint issues fix([#2697](mojaloop/project#2697)): Central-Ledger Fulfil Handler does not correctly invalidate requests with an incorrect/non-existent FSP-ID in the FSPIOP-Destination header - mojaloop/project#2697 - fixed/added unit tests - improved test coverage
…ios (#200) Added callback rules: - ttkpayeefsp PATCH Notifications Success Test-case - mojaloop/project#2676 - ttkpayeefsp PATCH Notifications Failure due to invalid fulfiment Test-case - mojaloop/project#2556 - ttkpayeefsp PUT Notifications Failure Test-case due to invalid FSPIOP-Destination Test-case - mojaloop/project#2697 - ttkpayeefsp PATCH Notifications Failure Test-case due to invalid FSPIOP-Destination Test-case - mojaloop/project#2697 ~Blocked by mojaloop/project#2696
Added the following feature test-case scenarios for patch notifications: - p2p_money_transfer_patch_notifications - payee receives PATCH Notification with COMMITTED after sending callback with RESERVED - mojaloop/project#2676 - p2p_money_transfer_patch_notifications - payee receives PATCH Notification with ABORTED status after sending invalid fulfilment - mojaloop/project#2556 Added the following bug-fix test-case scenarios for patch notifications: - p2p_money_transfer_patch_notifications - payee sends PUT callback with COMMITTED with invalid FSPIOP-Destination Header - mojaloop/project#2676 - p2p_money_transfer_patch_notifications - payee sends PUT callback with RESERVED with invalid FSPIOP-Destination Header - mojaloop/project#2676
- ml-api-adapter upgraded to v12.3.0 - central-ledger upgraded to v13.15.4 - ml-testing-toolkit backend upgraded to v14.0.4 These upgrades address the following issues: - Implement patch notification for failure scenarios (following v1.1 update) #2556 - mojaloop/project#2556 - Central-Ledger Fulfil Handler does not correctly invalidate requests with an incorrect/non-existent FSP-ID in the FSPIOP-Destination header #2697 - mojaloop/project#2697 - TTK GP Tests for patch notifications - positive scenarios #2676 - mojaloop/project#2676
- ml-api-adapter upgraded to v12.3.0 - central-ledger upgraded to v13.15.4 - ml-testing-toolkit backend upgraded to v14.0.4 These upgrades address the following issues (inc. updated changelog): - Implement patch notification for failure scenarios (following v1.1 update) #2556 - mojaloop/project#2556 - Central-Ledger Fulfil Handler does not correctly invalidate requests with an incorrect/non-existent FSP-ID in the FSPIOP-Destination header #2697 - mojaloop/project#2697 - TTK GP Tests for patch notifications - positive scenarios #2676 - mojaloop/project#2676
Goal:
As a
Payee FSPI want to
be able to receive a notification upon finalization of a transfer even in failure cases (success supported now)so that
I can use the notification to mitigate risk on payments to end-usersAcceptance Criteria:
Complexity: High
Uncertainty: Low
Tasks:
ABORTED
)ABORTED
; not just when a transfer is COMMITTED):PUT /transfers/{ID}
is sent from Payee FSP -> Switch with a status ofABORTED
(invalid value), there is noPATCH /transfers/{ID}
sent to the Payee FSP (this is an error condition covered in 1.2)PUT /transfers/{ID}
is sent from Payee FSP -> Switch with a status ofRESERVED
, and the transfer completes successfully, aPATCH /transfers/{ID}
is sent to the Payee FSP with a status of COMMITTED (this is the existing case)PUT /transfers/{ID}
is sent from Payee FSP -> Switch with a status of RESERVED, and the transfer has a fulfilment that doesn't match the condition, the switch aborts the transfer and aPATCH /transfers/{ID}
is sent to the Payee FSP with a status ofABORTED
(new functionality)PUT /transfers/{ID}
, and the transfer times out, noPATCH /transfers/{ID}
is sent to the Payee FSPDone
Pull Requests:
RESERVED_ABORTED
central-services-shared#317feat(mojaloop/project#2553): patch notification for Payee central-services-shared#318--> feat(mojaloop/project#2556): implement patch notification for failure scenarios (following v1.1 update) central-services-shared#321feat: add RESERVED_ABORTED to notification handler ml-api-adapter#489--> feat(mojaloop/project#2556): implement patch notification for failure scenarios ml-api-adapter#492feat(mojaloop/project#2553): send extra notification back to payee when a transfer is aborted central-ledger#872--> feat(mojaloop/project#2556): implement patch notification for failure scenarios central-ledger#874Follow-up:
Dependencies:
Accountability:
The text was updated successfully, but these errors were encountered: