Skip to content

Commit ca9a92e

Browse files
authored
Merge pull request #24 from platform-mesh/scenarioUpdwate
docs: scenario update
2 parents 5e23e4d + 1170e22 commit ca9a92e

File tree

1 file changed

+50
-41
lines changed

1 file changed

+50
-41
lines changed

scenarios/provider-to-consumer.md

Lines changed: 50 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,28 @@
11
---
2+
23
outline: deep
34
---
45
# Provider to Consumer (P2C)
56

7+
This section describes high-level scenarios of how the **Platform Mesh** enables secure, declarative, and flexible **Provider to Consumer** (P2C) interactions across clusters, organizations, and teams. It builds on concepts such as the [**Account Model**](../overview/account-model.md), [**Control Planes**](../overview/control-planes.md), and [**Managed Service Provider Pattern**](../overview/design-decision.md) to unify service exchange.
8+
69
## Kube to Kube
710

811
### Problem Description
912

10-
In a provider to consumer setting a Provider wants to transfer technical
11-
information in a secure way to a Consumer for a Service.
13+
In a direct **provider to consumer** setting, a provider wants to transfer technical information in a secure way to a consumer for a given service.
1214

13-
The Provider wants to expose as little information as needed while
14-
giving the Consumer the ability to automatically consume instances of
15-
the Service and retrieve the required information to interact with the
16-
Service.
15+
* The **Provider** must expose as little internal detail as possible.
16+
* The **Consumer** should be able to automatically discover and consume instances of the service.
17+
* Both parties must rely on a secure, declarative, contract-driven interaction.
1718

1819
### Solution
1920

20-
The Provider can offer a kube-bind backend, allowing the Consumer to
21-
authenticate with OIDC and to bind the CRD of the Service into their
22-
Cluster - or any KRM API.
21+
The provider can offer a **kube-bind backend**, allowing the consumer to:
22+
23+
* Authenticate with OIDC.
24+
* Bind the service’s CRD (or any KRM API) into their own cluster.
25+
* Automatically receive service instances and secrets.
2326

2427
```mermaid
2528
flowchart TD
@@ -43,21 +46,19 @@ subgraph Consumer
4346
end
4447
```
4548

49+
---
50+
4651
## Kube to KCP to Kube
4752

4853
### Problem Description
4954

50-
The problem is specified on the example of an Internal Developer
51-
Platform (IDP). Teams can be Providers and Consumer of Services.
55+
Within an **Internal Developer Platform (IDP)** setup, multiple teams act both as providers and consumers.
5256

53-
The Database Team (DB) offers a Postgres Service.
54-
The Observability Team (Obs) wants to use the Postgres Service as the
55-
database for their Elastic service.
56-
The Webshop Team (WS) wants to use the Postgres Services as the database
57-
for the Webshops they maintain for their customers and the Elastic
58-
Service for logging and metrics.
57+
* **Database Team (DB)** offers a Postgres service.
58+
* **Observability Team (Obs)** wants to consume Postgres for their Elastic service.
59+
* **Webshop Team (WS)** wants to consume both Postgres and Elastic services for their applications.
5960

60-
This diagram shows the premise of the problem:
61+
This creates a mesh of dependencies where teams provide and consume services through shared contracts.
6162

6263
```mermaid
6364
flowchart LR
@@ -96,25 +97,16 @@ subgraph WSCompute[Workshop Compute Cluster]
9697
end
9798
```
9899

99-
Not pictures is the teams using e.g. GitOps to manage the components of
100-
their services, which are running in the respective clusters.
100+
Teams use GitOps and declarative manifests to manage components in their respective clusters.
101101

102102
### Tools Solution
103103

104-
This solution focuses on using commonly available tools to manage and
105-
apply the manifests.
106-
107-
The Obersvability Team uses KRO (Kubernetes Resource Orchestrator) to
108-
instantiate their Elastic Service, including the Postgres Instance from
109-
the Database Team.
104+
The **Observability Team** leverages **KRO (Kubernetes Resource Orchestrator)** to:
110105

111-
Since KRO works only on one Cluster they are using kube-bind to pull the
112-
CRD of the Postgres Services from the APIBinding they created in their
113-
workspace to their compute cluster.
114-
115-
The postgres instance for an elastic service is created as part of the
116-
KRO Resource Graph Definition, which is mirrored back to KCP by
117-
kube-bind.
106+
* Instantiate Elastic services.
107+
* Pull Postgres CRDs from their APIBinding using **kube-bind**.
108+
* Define resource graphs that create Postgres instances using the pulled CRDs.
109+
* The ordered Postgres instances are mirrored back to KCP by **kube-bind**.
118110

119111
```mermaid
120112
flowchart TD
@@ -159,13 +151,11 @@ end
159151

160152
### Operator Solution
161153

162-
The Webshop team uses their own operator to manage their Webshop, which
163-
they wrote using multicluster-runtime, allowing them to interact with
164-
many clusters at once.
154+
The **Webshop Team** uses its own **operator** built with [**multicluster-runtime**](https://github.com/kubernetes-sigs/multicluster-runtime/):
165155

166-
The Webshop team maintains definitions of the Webshop instances in their
167-
KCP Workspace and are deploying resources based on these definitions
168-
where they are needed.
156+
* Webshop definitions live in their KCP workspace.
157+
* Operator deploys workloads across clusters.
158+
* Operator consumes Postgres and Elastic bindings.
169159

170160
```mermaid
171161
flowchart LR
@@ -206,5 +196,24 @@ WebshopOperator --> WebshopInstanceElastic
206196
WebshopOperator --> Webshop
207197
```
208198

209-
The operator also provides the information from the database and elastic
210-
service to the webshop instance.
199+
The operator ensures database and observability service data flows securely into webshop workloads.
200+
201+
---
202+
203+
## How This Fits Into Platform Mesh
204+
205+
The above flows illustrate how **Provider to Consumer** interactions are standardized in the Platform Mesh:
206+
207+
* **Providers** expose declarative APIs using [**APIExports**](../overview/control-planes.md).
208+
* **Consumers** bind to those APIs using **APIBindings**, gaining seamless access through the [**Account Model**](../overview/account-model.md).
209+
* [**Control planes**](../overview/control-planes.md) reconcile declarative manifests into real-world capabilities.
210+
* **Operators and orchestration tools** (kube-bind, KRO, multicluster-runtime) implement automation across boundaries.
211+
212+
This creates a secure, flexible, and decoupled ecosystem where services can be:
213+
214+
* Exposed minimally.
215+
* Discovered and consumed declaratively.
216+
* Composed across organizational or cluster boundaries.
217+
* Governed through the [**Account Model**](../overview/account-model.md) and [**Managed Service Provider pattern**](../overview/design-decision.md).
218+
219+
Ultimately, Platform Mesh provides the **P2C fabric** for multi-team, multi-cluster, and multi-organization service interactions.

0 commit comments

Comments
 (0)