[FLIP-321] Update the docs to add migration periods for deprecated APIs.#23865
[FLIP-321] Update the docs to add migration periods for deprecated APIs.#23865becketqin merged 4 commits intoapache:masterfrom
Conversation
|
@mbalassi Do you have time to take a look at the doc update? Thanks! |
JingGe
left a comment
There was a problem hiding this comment.
Thanks @becketqin for driving this! I just left a tiny comment and look forward to your thoughts.
| {{< label Example >}} | ||
| Assuming a release sequence of 1.18, 1.19, 1.20, 2.0, 2.1, ..., 3.0, | ||
| - if a `Public` API is deprecated in 1.18, it will not be removed until 2.0. | ||
| - if a `Public` API is deprecated in 1.20, the source code will be kept in 2.0 because the migration period is 2 minor releases. This means the source code will be removed in 3.0 at the earliest. |
There was a problem hiding this comment.
Although the source compatibility described in API compatibility guarantees implicitly said that a Public API can only be removed after one major release, it would be easier for us to follow the deprecation rule described in this section(i.e. don't make readers think), if we could explicitly point out that, in this case, for the Public API deprecated in 1.20 and carried over to 2.0, even after 2 minor releases, i.e. 2.0 and 2.1, it still can not be removed in 2.2 and can only be removed in 3.0 at the earliest. WDYT?
|
@becketqin: We might want to edit the previous section too. I think it is a bit misleading when we state there that a If I understand correctly, this is only true for the active version of the API. Contrary to the table in the docs - because of the proposed deprecation period - the source compatibility will be kept. Also when we state this:
This is only true because of the deprecation period we define later (here we refer to the API with the deprecation period in mind) |
|
Thanks for the quick turnaround, @becketqin. I agree with @pvary that we should adjust the table just above the newly added content. For example the |
|
I've had an in-depth look on the compatibility guarantee matrix together with the deprecation policy and here are my findings:
|
|
@pvary @mbalassi @gaborgsomogyi @JingGe Thanks a lot for the reviews. From what I understand, FLIP-321 does not change the API stability guarantee, it only specifies a migration period. For example, In terms of the source / binary compatibility, the main reason we do not provide binary compatibility in minor releases for any API stability level is because we treat the protocol / format behind the public API as internal. For example, state format might change although the state backend API remains the same. An RPC protocol may change although the APIs in the user library remain the same. In these cases, users don't have to change their code, but they may have to recompile the code or rerun the job, due to the missing binary compatibility. It is not ideal, but it is what we currently do. I agree the compatibility table looks confusing, although the contents seem accurate. I am wondering if some more concrete examples can help here. |
|
Thanks for the explanation!
If I understand correctly then couple of terms/compatibility levels are aggregated in the table. Since we're having
With fresh mind I've re-read/evaluated the whole again and seems like I've thought that In general I've the conclusion that existing documentation is valid but users are going to spend quite some time to understand each tiny pieces. |
gaborgsomogyi
left a comment
There was a problem hiding this comment.
LGTM in general but adding a note to the mentioned red cross would be good.
|
I would suggest to change the previous paragraph, like the following (remove the API compatibility related parts from there): The top part could remain the same, just the title changed to Then we should create 2 sub-paragraphs. The 2nd one could be |
| According to [FLIP-321](https://cwiki.apache.org/confluence/display/FLINK/FLIP-321%3A+Introduce+an+API+deprecation+process), | ||
| starting from release 1.18, each deprecated API will have a guaranteed migration period depending on the API stability level: | ||
|
|
||
| | Annotation | Guaranteed Migration Period | |
There was a problem hiding this comment.
Maybe one more column, like:
| Annotation | Guaranteed Migration Period | Could be removed after the migration period |
|:----------------:|:---------------------------------------------:|:-------------------------------------------:|
| `Public` | 2 minor releases | Next major version |
| `PublicEvolving` | 1 minor release | Next minor version |
| `Experimental` | 1 patch release for the affected minor release| Next patch version |
|
@pvary Sorry for the late response. I read the section a few times and found that the compatibility guarantee statement itself is actually concise and accurate. However, the the example section is a little biased and probably should be articulated a bit more. I updated the patch with a few more examples. Hopefully this makes the documents clear enough. |
|
@becketqin: Thanks for the example changes! They really help to make sense of the previous table. |
What is the purpose of the change
This PR update the ops doc to add the migration periods for deprecated APIs, which are specified in FLIP-321.
Brief change log
See the title.
Verifying this change
Build the docs and check the website locally at the following address:
http://localhost:1313/docs/ops/upgrading/#deprecated-api-migration-period
Does this pull request potentially affect one of the following parts:
@Public(Evolving): (no)Documentation