Skip to content

Commit 261e741

Browse files
committed
migration guide grammar
Signed-off-by: Attila Mészáros <[email protected]>
1 parent bdf08c4 commit 261e741

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

docs/content/en/docs/migration/v5-2-migration.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -3,34 +3,34 @@ title: Migrating from v5.1 to v5.2
33
description: Migrating from v5.1 to v5.2
44
---
55

6-
Version 5.2 brings some breaking changes on some components, for those we provide
7-
a migration guide. For all the new features see release notes.
6+
Version 5.2 brings some breaking changes to certain components. This document provides
7+
a migration guide for these changes. For all the new features, see the release notes.
88

99
## Custom ID types across multiple components using ResourceIDMapper and ResourceIDProvider
1010

11-
Working with an id of a resource is needed across various component in the framework.
12-
Until this version the components provided by the framework assumed that you can easily
13-
convert an id of the resource into String representation. So for example
11+
Working with the id of a resource is needed across various components in the framework.
12+
Until this version, the components provided by the framework assumed that you could easily
13+
convert the id of a resource into a String representation. For example,
1414
[BulkDependentResources](https://github.com/operator-framework/java-operator-sdk/blob/main/operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/dependent/BulkDependentResource.java#L46)
15-
worked with a `Map<String,R>` of resources, where id was always type of String.
15+
worked with a `Map<String,R>` of resources, where the id was always of type String.
1616

17-
Mainly because of the need to manage external dependent resources more elegantly
18-
we introduced a cross-cutting concept: [`ResourceIDMapper`](https://github.com/operator-framework/java-operator-sdk/blob/main/operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/ResourceIDMapper.java).
19-
That gets the ID of a resource. This is used then across various components, see:
17+
Mainly because of the need to manage external dependent resources more elegantly,
18+
we introduced a cross-cutting concept: [`ResourceIDMapper`](https://github.com/operator-framework/java-operator-sdk/blob/main/operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/ResourceIDMapper.java),
19+
which gets the ID of a resource. This is used across various components, see:
2020

2121
- [`ExternalResourceCachingEventSource`](https://github.com/operator-framework/java-operator-sdk/blob/main/operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/event/source/ExternalResourceCachingEventSource.java#L66)
2222
- [`ExternalBulkDependentResource`](https://github.com/operator-framework/java-operator-sdk/blob/main/operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/dependent/ExternalBulkDependentResource.java)
2323
- [`AbstractExternalDependentResource`](https://github.com/operator-framework/java-operator-sdk/blob/main/operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/dependent/AbstractExternalDependentResource.java#L39)
24-
and it's subclasses.
24+
and its subclasses.
2525

26-
We also added [`ResourceIDProvider`](https://github.com/operator-framework/java-operator-sdk/blob/main/operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/ResourceIDProvider.java)
27-
that you can implement into you Pojo representing a resource.
26+
We also added [`ResourceIDProvider`](https://github.com/operator-framework/java-operator-sdk/blob/main/operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/ResourceIDProvider.java),
27+
which you can implement in your Pojo representing a resource.
2828

29-
The easiest way to migrate to this new approach is to implement this interface for your (external) resource,
30-
and set the ID type generics for the components above. The default implementation of the `ResourceIDMapper`
31-
works with `ResourceIDProvider` see [related implementation](https://github.com/operator-framework/java-operator-sdk/blob/main/operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/ResourceIDMapper.java#L52).
29+
The easiest way to migrate to this new approach is to implement this interface for your (external) resource
30+
and set the ID type generics for the components above. The default implementation of the `ResourceIDMapper`
31+
works with `ResourceIDProvider` (see [related implementation](https://github.com/operator-framework/java-operator-sdk/blob/main/operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/ResourceIDMapper.java#L52)).
3232

33-
If you cannot implement `ResourceIDProvider` because for example the class that represents the external resource is generated and final,
33+
If you cannot implement `ResourceIDProvider` because, for example, the class that represents the external resource is generated and final,
3434
you can always set a custom `ResourceIDMapper` on the components above.
3535

3636
See also:

0 commit comments

Comments
 (0)