Endpoint Redirection


Service API Patterns, Protocols, Coupling Types, Metrics > Fundamental Service API Patterns > Endpoint Redirection

 

Endpoint Redirection

How can consumers of a specific service endpoint adapt when the service endpoint changes or is removed?

Service endpoint identifiers in REST services include information that can change over time. It may not be possible to replace all references to an out-of-date endpoint, which can lead to the service consumer being unable to further interact with the service endpoint.

The Endpoint Redirection pattern can be applied to automatically redirect service consumers that attempt to access out-of-date service endpoints to the current service endpoints. Redirection is a natural part of Web architecture that can be leveraged to allow for the evolution of Web-based resources without compromising the consumer programs designed to access those resources.

The simple but effective feature of redirection is a technique that can be applied to service composition design. The assumption is that even when a service endpoint becomes stale, a placeholder service remains active in the old resource location so that out-of-date consumers can be informed about the new endpoint when they attempt to interact with the old one.

 

 

 

 

 

 

 

 

The service consumer accesses a stale service endpoint API (1) and is informed that this API is no longer valid (2). The service consumer is subsequently redirected to the updated service endpoint API (3).

Module 12: Fundamental Service API Design & Management

This pattern is covered in Module 12: Fundamental Service API Design & Management..

For more information regarding service API design & management courses and accreditation, visit the Service API Specialist program page.