1ct_rpc(3) Erlang Module Definition ct_rpc(3)
2
3
4
6 ct_rpc - Common Test specific layer on Erlang/OTP rpc.
7
9 Common Test specific layer on Erlang/OTP rpc.
10
12 app_node(App, Candidates) -> NodeName
13
14 Types:
15
16 App = atom()
17 Candidates = [NodeName]
18 NodeName = atom()
19
20 From a set of candidate nodes determines which of them is run‐
21 ning the application App. If none of the candidate nodes is run‐
22 ning App, the function makes the test case calling this function
23 to fail. This function is the same as calling app_node(App, Can‐
24 didates, true).
25
26 app_node(App, Candidates, FailOnBadRPC) -> NodeName
27
28 Types:
29
30 App = atom()
31 Candidates = [NodeName]
32 NodeName = atom()
33 FailOnBadRPC = true | false
34
35 Same as ct_rpc:app_node/2, except that argument FailOnBadRPC
36 determines if the search for a candidate node is to stop if
37 badrpc is received at some point.
38
39 app_node(App, Candidates, FailOnBadRPC, Cookie) -> NodeName
40
41 Types:
42
43 App = atom()
44 Candidates = [NodeName]
45 NodeName = atom()
46 FailOnBadRPC = true | false
47 Cookie = atom()
48
49 Same as ct_rpc:app_node/2, except that argument FailOnBadRPC
50 determines if the search for a candidate node is to stop if
51 badrpc is received at some point.
52
53 The cookie on the client node is set to Cookie for this rpc
54 operation (used to match the server node cookie).
55
56 call(Node, Module, Function, Args) -> term() | {badrpc, Reason}
57
58 Same as call(Node, Module, Function, Args, infinity).
59
60 call(Node, Module, Function, Args, TimeOut) -> term() | {badrpc, Rea‐
61 son}
62
63 Types:
64
65 Node = NodeName | {Fun, FunArgs}
66 Fun = function()
67 FunArgs = term()
68 NodeName = atom()
69 Module = atom()
70 Function = atom()
71 Args = [term()]
72 Reason = timeout | term()
73
74 Evaluates apply(Module, Function, Args) on the node Node.
75 Returns either whatever Function returns, or {badrpc, Reason} if
76 the remote procedure call fails. If Node is {Fun, FunArgs},
77 applying Fun to FunArgs is to return a node name.
78
79 call(Node, Module, Function, Args, TimeOut, Cookie) -> term() |
80 {badrpc, Reason}
81
82 Types:
83
84 Node = NodeName | {Fun, FunArgs}
85 Fun = function()
86 FunArgs = term()
87 NodeName = atom()
88 Module = atom()
89 Function = atom()
90 Args = [term()]
91 Reason = timeout | term()
92 Cookie = atom()
93
94 Evaluates apply(Module, Function, Args) on the node Node.
95 Returns either whatever Function returns, or {badrpc, Reason} if
96 the remote procedure call fails. If Node is {Fun, FunArgs},
97 applying Fun to FunArgs is to return a node name.
98
99 The cookie on the client node is set to Cookie for this rpc
100 operation (used to match the server node cookie).
101
102 cast(Node, Module, Function, Args) -> ok
103
104 Types:
105
106 Node = NodeName | {Fun, FunArgs}
107 Fun = function()
108 FunArgs = term()
109 NodeName = atom()
110 Module = atom()
111 Function = atom()
112 Args = [term()]
113 Reason = timeout | term()
114
115 Evaluates apply(Module, Function, Args) on the node Node. No
116 response is delivered and the process that makes the call is not
117 suspended until the evaluation is completed as in the case of
118 call/3,4. If Node is {Fun, FunArgs}, applying Fun to FunArgs is
119 to return a node name.
120
121 cast(Node, Module, Function, Args, Cookie) -> ok
122
123 Types:
124
125 Node = NodeName | {Fun, FunArgs}
126 Fun = function()
127 FunArgs = term()
128 NodeName = atom()
129 Module = atom()
130 Function = atom()
131 Args = [term()]
132 Reason = timeout | term()
133 Cookie = atom()
134
135 Evaluates apply(Module, Function, Args) on the node Node. No
136 response is delivered and the process that makes the call is not
137 suspended until the evaluation is completed as in the case of
138 call/3,4. If Node is {Fun, FunArgs}, applying Fun to FunArgs is
139 to return a node name.
140
141 The cookie on the client node is set to Cookie for this rpc
142 operation (used to match the server node cookie).
143
144
145
146Ericsson AB common_test 1.15.4.2 ct_rpc(3)