This document lists all deprecated functionality in Erlang/OTP. For more information regarding the strategy regarding deprecations see the documentation of Support, Compatibility, Deprecations, and Removal.
Functions Deprecated in OTP 25
- crypto:crypto_dyn_iv_init/3 (see the documentation for details)
- crypto:crypto_dyn_iv_update/3 (see the documentation for details)
- ct_slave:_/_ (use ?CT_PEER(), or the 'peer' module instead)
- erts_alloc_config:_/_ (this module will be removed in OTP 26.0. See the documentation for details)
- httpd_util:decode_hex/1 (use uri_string:unquote function instead)
- httpd_util:encode_hex/1 (use uri_string:quote function instead)
- slave:_/_ (use the 'peer' module instead)
Erlang Distribution Without Large Node Container Support
Communication over the Erlang distribution without support for large node container data types (version 4) is as of OTP 24 deprecated and is scheduled for removal in OTP 26. That is, as of OTP 26, support for large node container data types will become mandatory.
Old Link Protocol
The old link protocol used when communicating over the Erlang distribution is as of OTP 24 deprecated and support for it is scheduled for removal in OTP 26. As of OTP 26, the new link protocol will become mandatory. That is, Erlang nodes will then refuse to connect to nodes not implementing the new link protocol. If you implement the Erlang distribution yourself, you are, however, encouraged to implement the new link protocol as soon as possible since the old protocol can cause links to enter an inconsistent state.
The ?NO_APP macro in the edoc include file edoc_doclet.hrl has been deprecated.
Functions Deprecated in OTP 24
- code:is_module_native/1 (HiPE has been removed)
- disk_log:accessible_logs/0 (use disk_log:all/0 instead)
- disk_log:lclose/1 (use disk_log:close/1 instead)
- disk_log:lclose/2 (use disk_log:close/1 instead)
- erlang:phash/2 (use erlang:phash2/2 instead)
- ftp:start_service/1 (use ftp:open/2 instead)
- ftp:stop_service/1 (use ftp:close/1 instead)
- httpd_util:flatlength/1 (use erlang:iolist_size/1 instead)
- httpd_util:hexlist_to_integer/1 (use erlang:list_to_integer/2 with base 16 instead)
- httpd_util:integer_to_hexlist/1 (use erlang:integer_to_list/2 with base 16 instead)
- httpd_util:strip/1 (use string:trim/1 instead)
- httpd_util:suffix/1 (use filename:extension/1 and string:trim/2 instead)
- zlib:adler32/2 (use erlang:adler32/1 instead)
- zlib:adler32/3 (use erlang:adler32/2 instead)
- zlib:adler32_combine/4 (use erlang:adler_combine/3 instead)
- zlib:crc32/1 (use erlang:crc32/1 on the uncompressed data instead)
- zlib:crc32/2 (use erlang:crc32/1 instead)
- zlib:crc32/3 (use erlang:crc32/2 instead)
- zlib:crc32_combine/4 (use erlang:crc32_combine/3 instead)
- zlib:getBufSize/1 (this function will be removed in a future release)
- zlib:inflateChunk/1 (use safeInflate/2 instead)
- zlib:inflateChunk/2 (use safeInflate/2 instead)
- zlib:setBufSize/2 (this function will be removed in a future release)
Crypto Old API
For replacement functions see the New API.
Since OTP 21 the recommended module to handle URIs is uri_string. The module http_uri does not provide a implementation that satisfies the RFC.
The public key algorithm 'ssh-rsa is regarded as insecure due to its usage of SHA1, and is therefore deprecated. It will not be available by default from OTP-24.
The public key algorithm 'ssh-dss is regarded as insecure due to its usage of SHA1 and its short key length, and is therefore deprecated. It is not available by default from OTP-23.
Distributed Disk Logs
As of OTP 23, the registry functionality part of erl_interface has been deprecated and it has also been removed in OTP 24.
Functions Deprecated in OTP 23
- http_uri:decode/1 (use uri_string:unquote function instead)
- http_uri:encode/1 (use uri_string:quote function instead)
- httpd:parse_query/1 (use uri_string:dissect_query/1 instead)
Legacy parts of erl_interface
The old legacy erl_interface library (functions with prefix erl_) is deprecated as of OTP 22. These parts of erl_interface has been informally deprecated for a very long time. You typically want to replace the usage of the erl_interface library with the use of the ei library which also is part of the erl_interface application. The old legacy erl_interface library has also been removed in OTP 23.
The format of "System Events" as defined in the man page for sys has been clarified and cleaned up. Due to this, code that relied on the internal badly documented previous (before this change) format of OTP's "System Events", needs to be changed.
In the wake of this the function sys:get_debug/3 that returns data with undocumented and internal format (and therefore is practically useless) has been deprecated, and a new function sys:get_log/1 has been added, that hopefully does what the deprecated function was intended for.
Functions Deprecated in OTP 22
- net:broadcast/3 (use rpc:eval_everywhere/3 instead)
- net:call/4 (use rpc:call/4 instead)
- net:cast/4 (use rpc:cast/4 instead)
- net:ping/1 (use net_adm:ping/1 instead)
- net:sleep/1 (use 'receive after T -> ok end' instead)
- sys:get_debug/3 (incorrectly documented and only for internal use. Can often be replaced with sys:get_log/1)
Functions Deprecated in OTP 20
- crypto:rand_uniform/2 (use rand:uniform/1 instead)
- gen_fsm:_/_ (use the 'gen_statem' module instead)
For security reasons SSL-3.0 is no longer supported by default, but can be configured.
Functions Deprecated in OTP 19
- code:rehash/0 (the code path cache feature has been removed)
- queue:lait/1 (use queue:liat/1 instead)
- random:_/_ (use the 'rand' module instead)
New time functionality and a new time API was introduced. For more information see the Time and Time Correction chapter in the ERTS User's guide and specifically the Dos and Donts section on how to replace usage of erlang:now/0.
API functions in the module httpd_conf was deprecated in favor of standard modules such as lists, string, filelib, and erlang.
Functions Deprecated in OTP 18
- erlang:now/0 (see the "Time and Time Correction in Erlang" chapter of the ERTS User's Guide for more information)
Functions Deprecated in OTP 16
- wxCalendarCtrl:enableYearChange/1 (not available in wxWidgets-2.9 and later)
- wxCalendarCtrl:enableYearChange/2 (not available in wxWidgets-2.9 and later)
inets - httpd Apache config files
A new config file format was introduced.
Functions Deprecated in OTP 12
- auth:cookie/0 (use erlang:get_cookie/0 instead)
- auth:cookie/1 (use erlang:set_cookie/2 instead)
- auth:is_auth/1 (use net_adm:ping/1 instead)
- auth:node_cookie/_ (use erlang:set_cookie/2 and net_adm:ping/1 instead)
- calendar:local_time_to_universal_time/1 (use calendar:local_time_to_universal_time_dst/1 instead)