switch to wyin-sdk-feed
stop using wyin-be-feed REST API in favor of wyin-sdk-feed
Motivation
- Improve app response times
- Reduce costs related to infrastructure
- Reduce costs related to network traffic
Overview
wyin-fe-webapp frontend depends on a service that is feeding it with data
(historical events) from external source
s.
This can be done as client-server
architecture. server
part from the
beginning was handled by wyin-be-feed microservice. This approach has both
pros and cons, where pros are:
-
P1
) clear separation between presentation layer and data layer -
P2
) interface enforcement -
P3
) easier to define responsibilities -
P4
) easier to define requirements
and cons are:
-
C1
) increased costs related to infrastructure -
C2
) increased costs related to network traffic -
C3
) additional network boundary -
C4
) possible rate limiting fromexternal source
s causing Denial of Service
wyin-sdk-feed
Solution proposed byFor WYIN usecases server
layer can be replaced with SDK
middleware that
will handle communication with external source
s on client side and at the
same time preserve the separation between presentation layer and data layer.
By doing this P1
, P2
are kept, C3
, C4
are no longer present and C1
,
C2
stay on minimal level. Additional benefit is code reusability - the very
same SDK
can be used on client
side or used as handler logic for REST API.