Skip to content

Conversation

@mkurapov
Copy link
Contributor

@mkurapov mkurapov commented Sep 26, 2025

Changes proposed in this pull request

  • Fetch cardDetails during outgoing payment funded and cancelled events, so it gets stored in the webhook data to send
  • Add CARD_WEBHOOK_SERVICE_URL to cloud nine backend docker compose file
  • Handle card service payment request data properly in POS service

Context

Related to #3654 | RAF-1168

Checklist

  • Related issues linked using fixes #number
  • Tests added/updated
  • Make sure that all checks pass
  • Bruno collection updated (if necessary)
  • Documentation issue created with user-docs label (if necessary)
  • OpenAPI specs updated (if necessary)

@mkurapov mkurapov requested a review from sanducb September 26, 2025 11:01
@github-actions github-actions bot added pkg: backend Changes in the backend package. type: source Changes business logic type: tests Testing related labels Sep 26, 2025
@github-actions
Copy link

github-actions bot commented Sep 26, 2025

🚀 Performance Test Results

Test Configuration:

  • VUs: 4
  • Duration: 1m0s

Test Metrics:

  • Requests/s: 43.69
  • Iterations/s: 14.59
  • Failed Requests: 0.00% (0 of 2626)
📜 Logs

> [email protected] run-tests:testenv /home/runner/work/rafiki/rafiki/test/performance
> ./scripts/run-tests.sh -e test "-k" "-q" "--vus" "4" "--duration" "1m"

Cloud Nine GraphQL API is up: http://localhost:3101/graphql
Cloud Nine Wallet Address is up: http://localhost:3100/
Happy Life Bank Address is up: http://localhost:4100/
cloud-nine-wallet-test-backend already set
cloud-nine-wallet-test-auth already set
happy-life-bank-test-backend already set
happy-life-bank-test-auth already set
     data_received..................: 948 kB 16 kB/s
     data_sent......................: 2.0 MB 34 kB/s
     http_req_blocked...............: avg=7.11µs   min=1.91µs   med=5.29µs   max=1.14ms   p(90)=6.39µs   p(95)=6.85µs  
     http_req_connecting............: avg=899ns    min=0s       med=0s       max=1.07ms   p(90)=0s       p(95)=0s      
     http_req_duration..............: avg=90.9ms   min=8.42ms   med=74.85ms  max=731.22ms p(90)=153.9ms  p(95)=180.36ms
       { expected_response:true }...: avg=90.9ms   min=8.42ms   med=74.85ms  max=731.22ms p(90)=153.9ms  p(95)=180.36ms
     http_req_failed................: 0.00%  ✓ 0         ✗ 2626
     http_req_receiving.............: avg=90.2µs   min=28.96µs  med=76.85µs  max=1.78ms   p(90)=115.5µs  p(95)=152.6µs 
     http_req_sending...............: avg=36.24µs  min=8.6µs    med=28.52µs  max=2.05ms   p(90)=42.14µs  p(95)=56.5µs  
     http_req_tls_handshaking.......: avg=0s       min=0s       med=0s       max=0s       p(90)=0s       p(95)=0s      
     http_req_waiting...............: avg=90.77ms  min=8.27ms   med=74.76ms  max=731.14ms p(90)=153.81ms p(95)=180.22ms
     http_reqs......................: 2626   43.688356/s
     iteration_duration.............: avg=273.86ms min=163.63ms med=259.92ms max=1.37s    p(90)=338.75ms p(95)=367.25ms
     iterations.....................: 877    14.590513/s
     vus............................: 4      min=4       max=4 
     vus_max........................: 4      min=4       max=4 

export interface AppServices {
logger: Promise<Logger>
config: Promise<IAppConfig>
paymentRoutes: Promise<PaymentRoutes>
Copy link
Contributor Author

Choose a reason for hiding this comment

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

so we can properly step into the functions

@mkurapov mkurapov changed the title Mk/raf 1168 fix: updates to make e2e payment flow work Sep 26, 2025
@mkurapov mkurapov merged commit b4db0e2 into bs/raf-1168 Sep 26, 2025
52 of 77 checks passed
@mkurapov mkurapov deleted the mk/raf-1168 branch September 26, 2025 11:55
sanducb added a commit that referenced this pull request Sep 26, 2025
* feat(card-service): handle payment cancelled & funded events

* feat(card-service): fix tests

* fix: updates to make e2e payment flow work (#3668)

* chore(localenv): add CARD_WEBHOOK_SERVICE_URL to cloud nine wallet backend

* feat(backend): fetch cardDetails during outgoing payment funded and cancelled

* chore(pos): correctly handle response from card service

* test(pos): update card service client test

* chore(card-service): add paymentRoutes to AppServices

* chore(backend): fix withGraphFetched query

* test(pos): remove unused test

* fix(card-service): update payment result type

* chore(card-service): format

---------

Co-authored-by: Max Kurapov <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pkg: backend Changes in the backend package. type: source Changes business logic type: tests Testing related

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants