Skip to content

Add "copy_as" method to datamessage

Method takes a topic as argument

  1. Do a deepcopy
  2. Copy the old message-id to .data as "from_msgid" encoding with uuid2b64
  3. Generate new messageid
  4. Set topic
  5. Return the new message

This will help with services that augment the original message with additional .data keys to be more DRY.