docs(shmem): document that sender and receiver must use the same kind of type

- shmem uses one metadata format for a single message and another for
  a multipart message; Receive(Parts) of a single send, or
  Receive(MessagePtr) of a multipart send, gives wrong metadata or a
  crash
- Add a sender/receiver table to the messages page of the
  documentation and a note to Channel::Receive()
- Update the source line links into Channel.h
- Keep PartsTransfer.SingleSendMultipartReceive disabled: a fix
  changes the shmem wire format

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Claude
2026-11-04 21:13:26 +00:00
committed by Dennis Klein
parent 102cdaf40e
commit 25f44828d7
10 changed files with 47 additions and 28 deletions

View File

@@ -318,6 +318,10 @@ class Channel
/// TransferCode::timeout if timed out,
/// TransferCode::error if there was an error,
/// TransferCode::interrupted if interrupted (e.g. by requested state change)
/// @note Receive with the same kind of type that the sender used: a MessagePtr for a
/// MessagePtr, a Parts/vector<MessagePtr> for a Parts/vector<MessagePtr>. The zeromq
/// transport also accepts a mix. The shmem transport uses a different metadata format for
/// each kind: a mix gives a message with wrong metadata or a crash.
template<typename M, typename... Timeout>
std::enable_if_t<is_transferrable<M>::value, int64_t>
Receive(M& m, Timeout&&... rcvTimeoutMs)