SAP / SAP/cloud-sdk-js

useCache will return a wrong destination with strategy alwaysProvider in multiple tenant case

Open
#5,985 11 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
TypeScript
Stars
218
Forks
74
Avg merge
1d 2h
Merged PRs (30d)
60

Description

Describe the Bug

useCache will return a wrong destination with strategy alwaysProvider in multiple tenant case

Steps to Reproduce

Please check the attached reproduce steps.

how to reproduce this issue.pdf

Expected Behavior

in multiple tenant case, the system should return the correct destination for different tenants, otherwise the system will get the data from a wrong destination.

Screenshots

No response

Used Versions
  • Node version via node -v: v22.16.0
  • NPM version via `npm -v: 10.9.2
  • SAP Cloud SDK version: 4.0.1
  • For CAP users, CAP version: 9
Code Examples

No response

Log File

No response

Affected Development Phase

Production

Impact

Impaired

Timeline

No response

Additional Context

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the attached reproduction steps and locate the useCache implementation and the alwaysProvider strategy in the TypeScript SDK. Reproduce the behavior with multiple tenants and trace how each tenant's destination is selected. Done means the correct destination is returned for every tenant and a regression test covers the case.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js, typescript
Domain
backend, cloud
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.