xref: /spdk/deprecation.md (revision c6c1234de9e0015e670dd0b51bf6ce39ee0e07bd)
1# Deprecation
2
3## ABI and API Deprecation
4
5This document details the policy for maintaining stability of SPDK ABI and API.
6
7Major ABI version can change at most once for each SPDK release.
8ABI versions are managed separately for each library and follow [Semantic Versioning](https://semver.org/).
9
10API and ABI deprecation notices shall be posted in the next section.
11Each entry must describe what will be removed and can suggest the future use or alternative.
12Specific future SPDK release for the removal must be provided.
13ABI cannot be removed without providing deprecation notice for at least single SPDK release.
14
15Deprecated code paths must be registered with `SPDK_LOG_DEPRECATION_REGISTER()` and logged with
16`SPDK_LOG_DEPRECATED()`. The tag used with these macros will appear in the SPDK
17log at the warn level when `SPDK_LOG_DEPRECATED()` is called, subject to rate limits.
18The tags can be matched with the level 4 headers below.
19
20## Deprecation Notices
21
22### nvme
23
24#### `spdk_nvme_ctrlr_opts.psk`
25
26Passing NVMe/TLS pre-shared keys via `spdk_nvme_ctrlr_opts.psk` is deprecated and this field will be
27removed in the v24.09 release.  Instead, a key obtained from the keyring library should be passed
28in `spdk_nvme_ctrlr_opts.tls_psk`.
29
30### init
31
32#### `spdk_subsystem_init_from_json_config`
33
34The function is deprecated and will be removed in 24.09 release. Please use
35`spdk_subsystem_load_config` instead.
36
37### nvmf
38
39#### `decode_rpc_listen_address`
40
41`transport` field in `listen_addresses` decoders is deprecated. `trtype` field should be used
42instead. `transport` field will be removed in 24.09 release.
43
44#### `spdk_nvmf_request_exec_fabrics`
45
46This function is deprecated and will be removed in the 24.09 release.  Instead, users should use
47`spdk_nvmf_request_exec()`, which now allows all transports (both fabrics and non-fabrics) to
48execute fabrics commands.
49
50#### `nvmf_subsystem_add_host`
51
52The ability to specifying path to a PSK file via the `psk` parameter in `nvmf_subsystem_add_host` is
53deprecated and will be removed in the v24.09 release.  Instead, the name of a key attached to the
54keyring should be used.
55
56### gpt
57
58#### `old_gpt_guid`
59
60Deprecated the SPDK partition type GUID `7c5222bd-8f5d-4087-9c00-bf9843c7b58c`. Partitions of this
61type have bdevs created that are one block less than the actual size of the partition. Existing
62partitions using the deprecated GUID can continue to use that GUID; support for the deprecated GUID
63will remain in SPDK indefinitely, and will continue to exhibit the off-by-one bug so that on-disk
64metadata layouts based on the incorrect size are not affected.
65
66See GitHub issue [2801](https://github.com/spdk/spdk/issues/2801) for additional details on the bug.
67
68New SPDK partition types should use GUID `6527994e-2c5a-4eec-9613-8f5944074e8b` which will create
69a bdev of the correct size.
70
71### rpc
72
73#### `spdk_rpc_listen` `spdk_rpc_accept` `spdk_rpc_close`
74
75These functions are deprecated and will be removed in 24.09 release. Please use
76`spdk_rpc_server_listen`, `spdk_rpc_server_accept` and `spdk_rpc_server_close` instead.
77