def send_message(target: required!(:target), payload: required!(:payload), acknowledge: false, at_time: nil)
      paths = @routing_manager.resolve_target(target)

      messages = paths.map do |path|
        Message.new(path: path, payload: payload, acknowledge: acknowledge, at_time: at_time)
      end

      if within_sync?
        Thread.current[:sync_messages].push(*messages)
        return
      end

      messages.each do |message|
        @transport_manager.write(message)
      end
    end
def send_message(target: required!(:target), payload: required!(:payload), acknowledge: false, at_time: nil)
      paths = @routing_manager.resolve_target(target)

      messages = paths.map do |path|
        Message.new(path: path, payload: payload, acknowledge: acknowledge, at_time: at_time)
      end

      if within_sync?
        Thread.current[:sync_messages].push(*messages)
        return
      end

      messages.each do |message|
        @transport_manager.write(message)
      end
    end
Sends a message to their destination(s)
 @param target: [Target] Target of the message
 @param payload: [Protocol::Payload] Message payload
 @param acknowledge: [Boolean] If recipients must acknowledge with a response
 @param at_time: [Integer] Unix epoch in milliseconds to run the payload. Only applicable to certain payload types.