Skip to content

Commit 939b5c4

Browse files
scothisnebhale
authored andcommitted
review feedback
Signed-off-by: Scott Andrews <[email protected]>
1 parent 4bedb0b commit 939b5c4

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

README.md

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,8 @@ Participation in the Kubernetes community is governed by the [Kubernetes Code of
6767
- [Restricted JSONPath](#restricted-jsonpath)
6868
- [Resource Type Schema](#resource-type-schema-2)
6969
- [Example Resource](#example-resource-3)
70-
- [PodSpec-able (Default) Example Resource](#podspec-able-default-example-resource)
71-
- [Reconciler Implementation](#reconciler-implementation-1)
70+
- [PodSpecable (Default) Example Resource](#podspecable-default-example-resource)
71+
- [Runtime Behavior](#runtime-behavior)
7272
- [Role-Based Access Control (RBAC)](#role-based-access-control-rbac)
7373
- [Example Resource](#example-resource-4)
7474

@@ -508,13 +508,13 @@ metadata:
508508
...
509509
spec:
510510
versions: # []MappingTemplate
511-
- version: # string
512-
containers: # []MappingContainer, optional
513-
- path: # string (JSONPath)
514-
name: # string (Restricted JSONPath), optional
515-
env: # string (Restricted JSONPath), optional
516-
volumeMounts: # string (Restricted JSONPath), optional
517-
volumes: # string (Restricted JSONPath), optional
511+
- version: # string
512+
containers: # []MappingContainer, optional
513+
- path: # string (JSONPath)
514+
name: # string (Restricted JSONPath), optional
515+
env: # string (Restricted JSONPath), optional
516+
volumeMounts: # string (Restricted JSONPath), optional
517+
volumes: # string (Restricted JSONPath), optional
518518
```
519519

520520
## Example Resource
@@ -529,7 +529,7 @@ spec:
529529
- version: "*"
530530
containers:
531531
- path: .spec.jobTemplate.spec.template.spec.containers[*]
532-
g name: .name
532+
name: .name
533533
env: .env # this is the default value
534534
volumeMounts: .volumeMounts # this is the default value
535535
- path: .spec.jobTemplate.spec.template.spec.initContainers[*]
@@ -539,7 +539,7 @@ g name: .name
539539
volumes: .spec.jobTemplate.spec.template.spec.volumes
540540
```
541541

542-
## PodSpec-able (Default) Example Resource
542+
## PodSpecable (Default) Example Resource
543543

544544
```yaml
545545
apiVersion: servicebinding.io/v1alpha3
@@ -563,13 +563,13 @@ spec:
563563

564564
Note: This example is equivalent to not specifying a mapping or specifying an empty mapping.
565565

566-
## Reconciler Implementation
566+
## Runtime Behavior
567567

568-
A reconciler implementation **MUST** support mapping to PodSpec-able resources without defining a `ClusterWorkloadResourceMapping` for those types.
568+
When a `ClusterWorkloadResourceMapping` is defined in the cluster matching a workload resource it **MUST** be used to map the binding that type. If no mapping is available for the type, the implementation **MUST** treat the workload resource as a PodSpecable type.
569569

570-
If a `ServiceBinding` specifies `.spec.workload.containers` and a `MappingContainer` specifies a `name` expression, the resolved name **MUST** limit which containers in the workload are bound.
570+
If a `ServiceBinding` specifies `.spec.workload.containers` and a `MappingContainer` specifies a `name` expression, the resolved name **MUST** limit which containers in the workload are bound. If either key is not defined, the container **SHOULD** be bound.
571571

572-
A reconciler **MUST** create empty values at locations referenced by [Restricted JSONPaths](#restricted-jsonpath) that do not exist on the workload resource. Values referenced by JSONPaths in both the `MappingTemplate` and `MappingContainer`s **MUST** be mutated by a `ServiceBinding` reconciler as if they were defined directly by a PodTemplateSpec. A reconciler **MUST** preserve fields on the workload resource that fall outside the specific fragments and types defined by the mapping.
572+
An implementation **MUST** create empty values at locations referenced by [Restricted JSONPaths](#restricted-jsonpath) that do not exist on the workload resource. Values referenced by JSONPaths in both the `MappingTemplate` and `MappingContainer`s **MUST** be mutated by a `ServiceBinding` reconciler as if they were defined directly by a PodTemplateSpec. A reconciler **MUST** preserve fields on the workload resource that fall outside the specific fragments and types defined by the mapping.
573573

574574
# Role-Based Access Control (RBAC)
575575

0 commit comments

Comments
 (0)