Problem
The Express example currently demonstrates features such as retries and
the circuit breaker, but does not demonstrate SmoothAPI's Request
Deduplication functionality.
Request Deduplication is an important feature and would be useful to show
in a runnable example.
What needs to be done
Add a new /dedup-demo endpoint to the Express example.
The endpoint should:
- Create a SmoothAPI client with request deduplication enabled
- Make multiple identical requests concurrently
- Use
Promise.all() to trigger the requests
- Return the results to the client
The goal is to demonstrate that multiple concurrent identical requests
can be deduplicated.
Acceptance Criteria
Files to look at
examples/express/server.ts
- SmoothAPI request deduplication implementation/documentation
Prerequisites
Basic TypeScript/JavaScript, Express and Promises.
Notes
The goal is to demonstrate the feature clearly rather than build a
complex application.
Problem
The Express example currently demonstrates features such as retries and
the circuit breaker, but does not demonstrate SmoothAPI's Request
Deduplication functionality.
Request Deduplication is an important feature and would be useful to show
in a runnable example.
What needs to be done
Add a new
/dedup-demoendpoint to the Express example.The endpoint should:
Promise.all()to trigger the requestsThe goal is to demonstrate that multiple concurrent identical requests
can be deduplicated.
Acceptance Criteria
/dedup-demoendpoint existsPromise.all()is used appropriatelyFiles to look at
examples/express/server.tsPrerequisites
Basic TypeScript/JavaScript, Express and Promises.
Notes
The goal is to demonstrate the feature clearly rather than build a
complex application.