@@ -157,10 +157,11 @@ import Control.Distributed.Process.Internal.Types
157 , RegisterReply(..)
157 , RegisterReply(..)
158 , WhereIsReply(..)
158 , WhereIsReply(..)
159 , payloadToMessage
159 , payloadToMessage
160 , createUnencodedMessage
161 , createUnencodedMessage
161 , runLocalProcess
162 , runLocalProcess
162 , firstNonReservedProcessId
163 , firstNonReservedProcessId
163− , ImplicitReconnect(WithImplicitReconnect)
164+ , ImplicitReconnect(WithImplicitReconnect,NoImplicitReconnect)
165import Control.Distributed.Process.Management.Internal.Agent
166import Control.Distributed.Process.Management.Internal.Agent
166 ( mxAgentController
167 ( mxAgentController
@@ -188,6 +189,7 @@ import Control.Distributed.Process.Serializable (Serializable)
188import Control.Distributed.Process.Internal.Messaging
189import Control.Distributed.Process.Internal.Messaging
189 ( sendBinary
190 ( sendBinary
190 , sendMessage
191 , sendMessage
191 , closeImplicitReconnections
193 , closeImplicitReconnections
192 , impliesDeathOf
194 , impliesDeathOf
@@ -692,8 +694,8 @@ nodeController = do
692 ncEffectRegister from label atnode pid force
694 ncEffectRegister from label atnode pid force
693 NCMsg (ProcessIdentifier from) (WhereIs label) ->
695 NCMsg (ProcessIdentifier from) (WhereIs label) ->
694 ncEffectWhereIs from label
696 ncEffectWhereIs from label
695− NCMsg _ (NamedSend label msg') ->
697+ NCMsg (ProcessIdentifier from) (NamedSend label msg') ->
696− ncEffectNamedSend label msg'
698+ ncEffectNamedSend from label msg'
697 NCMsg _ (UnreliableSend lpid msg') ->
699 NCMsg _ (UnreliableSend lpid msg') ->
698 ncEffectLocalSend node (ProcessId (localNodeId node) lpid) msg'
700 ncEffectLocalSend node (ProcessId (localNodeId node) lpid) msg'
699 NCMsg _ (LocalSend to msg') ->
701 NCMsg _ (LocalSend to msg') ->
@@ -912,11 +914,17 @@ ncEffectWhereIs from label = do
912 (WhereIsReply label mPid)
914 (WhereIsReply label mPid)
914-- [Unified: Table 14]
916-- [Unified: Table 14]
915−ncEffectNamedSend :: String -> Message -> NC ()
917+ncEffectNamedSend :: ProcessId -> String -> Message -> NC ()
916−ncEffectNamedSend label msg = do
918+ncEffectNamedSend from label msg = do
917 mPid <- gets (^. registeredHereFor label)
919 mPid <- gets (^. registeredHereFor label)
918 -- If mPid is Nothing, we just ignore the named send (as per Table 14)
921 -- If mPid is Nothing, we just ignore the named send (as per Table 14)
919− forM_ mPid $ \pid -> postMessage pid msg
922+ forM_ mPid $ \pid ->
923+ liftIO $ sendPayload node
924+ (ProcessIdentifier from)
925+ (ProcessIdentifier pid)
927+ (messageToPayload msg)
921-- [Issue #DP-20]
929-- [Issue #DP-20]
922ncEffectLocalSend :: LocalNode -> ProcessId -> Message -> NC ()
930ncEffectLocalSend :: LocalNode -> ProcessId -> Message -> NC ()