Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add remaining Comm bindings and examples
[simgrid.git] / examples / python / comm-failure / comm-failure.tesh
1 #!/usr/bin/env tesh
2
3 $ ${pythoncmd:=python3} ${PYTHON_TOOL_OPTIONS:=} ${bindir:=.}/comm-failure.py "--log=root.fmt:[%10.6r]%e(%i:%a@%h)%e%m%n"
4 >[  0.000000] (4:LinkKiller@Host2) sleeping 10 seconds...
5 >[  0.000000] (2:Receiver-1@Host2) Receiver posting a receive (mailbox2)...
6 >[  0.000000] (3:Receiver-2@Host3) Receiver posting a receive (mailbox3)...
7 >[  0.000000] (1:Sender@Host1) Initiating asynchronous send to mailbox2
8 >[  0.000000] (1:Sender@Host1) Initiating asynchronous send to mailbox3
9 >[  0.000000] (1:Sender@Host1) Calling wait_any..
10 >[ 10.000000] (4:LinkKiller@Host2) turning off link link_to_2
11 >[ 10.000000] (4:LinkKiller@Host2) link killed. exiting
12 >[ 10.000000] (2:Receiver-1@Host2) Receiver has experience a network failure exception (mailbox2)
13 >[ 10.000000] (1:Sender@Host1) Sender has experienced a network failure exception, so it knows that something went wrong
14 >[ 10.000000] (1:Sender@Host1) Now it needs to figure out which of the two comms failed by looking at their state
15 >[ 10.000000] (1:Sender@Host1) Comm to mailbox2 has state: FAILED
16 >[ 10.000000] (1:Sender@Host1) Comm to mailbox3 has state: STARTED
17 >[ 10.000000] (1:Sender@Host1) Waiting on a FAILED comm raises an exception
18 >[ 10.000000] (1:Sender@Host1) Wait for remaining comm, just to be nice
19 >[ 16.494845] (3:Receiver-2@Host3) Receiver has received successfully (mailbox3)!