summaryrefslogtreecommitdiff
path: root/erts/doc/src/erl_ext_dist.xml
diff options
context:
space:
mode:
Diffstat (limited to 'erts/doc/src/erl_ext_dist.xml')
-rw-r--r--erts/doc/src/erl_ext_dist.xml69
1 files changed, 55 insertions, 14 deletions
diff --git a/erts/doc/src/erl_ext_dist.xml b/erts/doc/src/erl_ext_dist.xml
index b4b245187d..712c30afc0 100644
--- a/erts/doc/src/erl_ext_dist.xml
+++ b/erts/doc/src/erl_ext_dist.xml
@@ -5,7 +5,7 @@
<header>
<copyright>
<year>2007</year>
- <year>2021</year>
+ <year>2023</year>
<holder>Ericsson AB, All Rights Reserved</holder>
</copyright>
<legalnotice>
@@ -655,6 +655,7 @@
encoded using <c>NEW_PORT_EXT</c>, even external ports received as <seeguide
marker="#PORT_EXT"><c>PORT_EXT</c></seeguide> from older nodes.
</p>
+
</section>
<section>
@@ -683,8 +684,10 @@
works just like in <seeguide marker="#NEW_PID_EXT"><c>NEW_PID_EXT</c></seeguide>.
Port operations are not allowed across node boundaries.
</p>
- <p><c>V4_PORT_EXT</c> was introduced in OTP 24, but only to be decoded
- and echoed back. Not encoded for local ports.
+ <p>In OTP 26 distribution flag
+ <seeguide marker="erl_dist_protocol#DFLAG_V4_NC"><c>DFLAG_V4_NC</c></seeguide>
+ as well as <c>V4_PORT_EXT</c> became mandatory accepting full
+ 64-bit ports to be decoded and echoed back.
</p>
</section>
@@ -742,14 +745,10 @@
<seeguide marker="#utf8_atoms">encoded as an atom</seeguide>.</p>
</item>
<tag><c>ID</c></tag>
- <item><p>A 32-bit big endian unsigned integer. If distribution flag
- <seeguide marker="erl_dist_protocol#DFLAG_V4_NC"><c>DFLAG_V4_NC</c></seeguide>
- is not set, only 15 bits may be used and the rest must be 0.</p>
+ <item><p>A 32-bit big endian unsigned integer.</p>
</item>
<tag><c>Serial</c></tag>
- <item><p>A 32-bit big endian unsigned integer. If distribution flag
- <seeguide marker="erl_dist_protocol#DFLAG_V4_NC"><c>DFLAG_V4_NC</c></seeguide>
- is not set, only 13 bits may be used and the rest must be 0.</p>
+ <item><p>A 32-bit big endian unsigned integer.</p>
</item>
<tag><c>Creation</c></tag>
<item><p>A 32-bit big endian unsigned integer. All identifiers
@@ -768,9 +767,10 @@
even external pids received as
<seeguide marker="#PID_EXT"><c>PID_EXT</c></seeguide> from older nodes.
</p>
- <p>In OTP 24 distribution flag
+ <p>In OTP 26 distribution flag
<seeguide marker="erl_dist_protocol#DFLAG_V4_NC"><c>DFLAG_V4_NC</c></seeguide>
- was introduced, accepting full 64-bit pids to be decoded and echoed back.
+ became mandatory accepting full 64-bit pids to be decoded
+ and echoed back.
</p>
</section>
@@ -1080,9 +1080,7 @@
<seeguide marker="#utf8_atoms">encoded as an atom</seeguide>.</p>
</item>
<tag><c>Len</c></tag>
- <item><p>A 16-bit big endian unsigned integer not larger than 5 when the
- <seeguide marker="erl_dist_protocol#DFLAG_V4_NC"><c>DFLAG_V4_NC</c></seeguide>
- has been set; otherwise not larger than 3.</p>
+ <item><p>A 16-bit big endian unsigned integer not larger than 5.</p>
</item>
<tag><c>ID</c></tag>
<item><p>A sequence of <c>Len</c> big-endian unsigned integers
@@ -1104,6 +1102,9 @@
<seeguide marker="#NEW_REFERENCE_EXT"><c>NEW_REFERENCE_EXT</c></seeguide>
from older nodes.
</p>
+ <p>In OTP 26 distribution flag
+ <seeguide marker="erl_dist_protocol#DFLAG_V4_NC"><c>DFLAG_V4_NC</c></seeguide>
+ became mandatory. References now can contain up to 5 <c>ID</c> words.</p>
</section>
<section>
@@ -1420,6 +1421,46 @@
</note>
</section>
+ <section>
+ <marker id="LOCAL_EXT"/>
+ <title>LOCAL_EXT</title>
+ <table align="left">
+ <row>
+ <cell align="center">1</cell>
+ <cell align="center">...</cell>
+ </row>
+ <row>
+ <cell align="center"><c>121</c></cell>
+ <cell align="center">...</cell>
+ </row>
+ <tcaption>LOCAL_EXT</tcaption></table>
+ <p>
+ Marks that this is encoded on an alternative local external term
+ format intended to only be decoded by a specific local decoder.
+ The bytes following from here on may contain any unspecified type
+ of encoding of terms. It is the responsibility of the user to only
+ attempt to decode terms on the local external term format which has
+ been produced by a matching encoder.
+ </p>
+ <p>
+ This tag is used by the Erlang runtime system upon encoding the local
+ external term format when the
+ <seeerl marker="erts:erlang#term_to_binary_local"><c>local</c></seeerl>
+ option is passed to
+ <seemfa marker="erts:erlang#term_to_binary/2"><c>term_to_binary/2</c></seemfa>,
+ but can be used by other encoders as well providing similar
+ functionality. The Erlang runtime system adds a hash immediately
+ following the <c>LOCAL_EXT</c> tag which is verified on decoding in
+ order to verify that encoder and decoder match which might be a good
+ practice. This will very likely catch mistakes made by users, but
+ is not guaranteed to, and is not intended to, prevent decoding of an
+ intentionally forged encoding on the local external term format.
+ </p>
+ <p>
+ <c>LOCAL_EXT</c> was introduced in OTP @OTP-18477@.
+ </p>
+ </section>
+
</chapter>