CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.

| Download

GAP 4.8.9 installation with standard packages -- copy to your CoCalc project to get it

Views: 418346
1
2
6 Client's functionality
3
4
Sending and getting requests to the SCSCP server(s), the client operates
5
with processes. Process is an abstraction which in other words may be also
6
called a remote task. It encapsulates an input/output TCP stream (see
7
IsInputOutputTCPStream (3.1-1)) from the client to the server and the
8
process ID of the CAS running as a server (deduced from the connection
9
initiation message; may be unassigned, if the server CAS did not communicate
10
it).
11
12
There are two ways to create processes. One of them is to specify the
13
hostname and port where the SCSCP server is running; in this case a new
14
input/output TCP stream will be created. Another way is first to establish
15
the connection with the SCSCP server using NewSCSCPconnection (6.1-2) and
16
then keep it alive across multiple remote procedure calls, thus saving time
17
on the DNS lookup and connection initiation. This may give a good speedup in
18
computations with an intensive message exchange. Note that as long as such
19
connection is open, other SCSCP clients will not be able to get through, so
20
if several clients are interchanging with the SCSCP server at the same time,
21
they should not block each other with long-lasting connections.
22
23
24
6.1 SCSCP connections
25
26
6.1-1 IsSCSCPconnection
27
28
IsSCSCPconnection filter
29
30
This is the category of SCSCP connections. Objects in this category are
31
created using the function NewSCSCPconnection (6.1-2).
32
33
6.1-2 NewSCSCPconnection
34
35
NewSCSCPconnection( hostname, port )  function
36
37
For a string hostname and an integer port, creates an object in the category
38
IsSCSCPconnection (6.1-1). This object will encapsulate two objects:
39
tcpstream, which is the input/output TCP stream to hostname:port, and
40
session_id, which is the result of calling StartSCSCPsession (4.1-1) on
41
tcpstream. The connection will be kept alive across multiple remote
42
procedure calls until it will be closed with CloseSCSCPconnection (6.1-3).
43
44
 Example 
45

46
gap> SetInfoLevel( InfoSCSCP, 2 );
47
gap> s:=NewSCSCPconnection("localhost",26133);
48
#I Creating a socket ...
49
#I Connecting to a remote socket via TCP/IP ...
50
#I Got connection initiation message
51
#I <?scscp service_name="GAP" service_version="4.dev" service_id="localhost:2\
52
6133:52918" scscp_versions="1.0 1.1 1.2 1.3" ?>
53
#I Requesting version 1.3 from the server ...
54
#I Server confirmed version 1.3 to the client ...
55
< connection to localhost:26133 session_id=localhost:26133:52918 >
56
gap> CloseSCSCPconnection(s);
57

58

59
60
6.1-3 CloseSCSCPconnection
61
62
CloseSCSCPconnection( s )  function
63
Returns: nothing
64
65
Closes SCSCP connection s, which must be an object in the category
66
IsSCSCPconnection (6.1-1). Internally, it just calls CloseStream (Reference:
67
CloseStream) on the underlying input/output TCP stream of s.
68
69
 Example 
70

71
gap> SetInfoLevel( InfoSCSCP, 0 );
72
gap> s:=NewSCSCPconnection("localhost",26133);
73
< connection to localhost:26133 session_id=localhost:26133:52918 >
74
gap> CloseSCSCPconnection(s);
75

76

77
78
79
6.2 Processes
80
81
6.2-1 IsProcess
82
83
IsProcess filter
84
85
This is the category of processes. Processes in this category are created
86
using the function NewProcess (6.2-2).
87
88
6.2-2 NewProcess
89
90
NewProcess( command, listargs, server, port )  function
91
NewProcess( command, listargs, connection )  function
92
Returns: object in the category IsProcess
93
94
In the first form, command and server are strings, listargs is a list of GAP
95
objects and port is an integer.
96
97
In the second form, an SCSCP connection in the category NewSCSCPconnection
98
(6.1-2) is used instead of server and port.
99
100
Calls the SCSCP procedure with the name command and the list of arguments
101
listargs at the server and port given by server and port or encapsulated in
102
the connection. Returns an object in the category IsProcess for the
103
subsequent waiting the result from its underlying stream.
104
105
It accepts the following options:
106
107
 output:="object" is used to specify that the server must return the
108
actual object evaluated as a result of the procedure call. This is the
109
default action requested by the client if the output option is
110
omitted.
111
112
 output:="cookie" is used to specify that the result of the procedure
113
call should be stored on the server, and the server should return a
114
remote object (see 6.5 ) pointing to that result (that is, a cookie);
115
116
 output:="nothing" is used to specify that the server is supposed to
117
reply with a procedure_completed message carrying no object just to
118
signal that the call was completed successfully (for the
119
compatibility, this will be evaluated to a "procedure completed"
120
string on the client's side);
121
122
 cd:="cdname" is used to specify that the OpenMath symbol corresponding
123
to the first argument command should be looked up in the particular
124
content dictionary cdname. Otherwise, it will be looked for in the
125
default content dictionary (scscp_transient_1 for the GAP SCSCP
126
server);
127
128
 debuglevel:=N is used to obtain additional information attributes
129
together with the result. The GAP SCSCP server does the following: if
130
N=1, it will report about the CPU time in milliseconds required to
131
compute the result; if N=2 it will additionally report about the
132
amount of memory used by GAP in bytes will be returned (using the
133
output of MemoryUsageByGAPinKbytes (9.3-4) converted to bytes); if N=3
134
it will additionally report the amount of memory in bytes used by the
135
resulting object and its subobjects (using the output of MemoryUsage
136
(Reference: MemoryUsage)).
137
138
See CompleteProcess (6.2-3) and EvaluateBySCSCP (6.3-1) for examples.
139
140
6.2-3 CompleteProcess
141
142
CompleteProcess( process )  function
143
Returns: record with components object and attributes
144
145
The function waits, if necessary, until the underlying stream of the process
146
will contain some data, then reads the appropriate OpenMath object from this
147
stream and closes it.
148
149
It has the option output which may have two values:
150
151
 output:="cookie" has the same meaning as for the NewProcess (6.2-2)
152
153
 output:="tree" is used to specify that the result obtained from the
154
server should be returned as an XML parsed tree without its
155
evaluation.
156
157
In the following example we demonstrate combination of the two previous
158
functions to send request and get result, calling the procedure
159
WS_Factorial, installed in the previous chapter:
160
161
 Example 
162

163
gap> s := NewProcess( "WS_Factorial", [10], "localhost", 26133 ); 
164
< process at localhost:26133 pid=52918 >
165
gap> x := CompleteProcess(s);
166
rec( attributes := [ [ "call_id", "localhost:26133:52918:TPNiMjCT" ] ],
167
 object := 3628800 )
168

169

170
171
See more examples in the description of the function EvaluateBySCSCP
172
(6.3-1), which combines the two previous functions by sending request and
173
getting result in one call.
174
175
6.2-4 TerminateProcess
176
177
TerminateProcess( process )  function
178
179
The function is supposed to send an out-of-band interrupt signal to the
180
server. Current implementation works only when the server is running as
181
localhost by sending a SIGINT to the server using its PID contained in the
182
process. It will do nothing if the server is running remotely, as the SCSCP
183
specification allows the server to ignore interrupt messages. Remote
184
interrupts will be introduced in one of the next versions of the package.
185
186
187
6.3 All-in-one tool: sending request and getting result
188
189
6.3-1 EvaluateBySCSCP
190
191
EvaluateBySCSCP( command, listargs, server, port )  function
192
EvaluateBySCSCP( command, listargs, connection )  function
193
Returns: record with components object and attributes
194
195
In the first form, command and server are strings, listargs is a list of GAP
196
objects and port is an integer.
197
198
In the second form, an SCSCP connection in the category NewSCSCPconnection
199
(6.1-2) is used instead of server and port.
200
201
Calls the SCSCP procedure with the name command and the list of arguments
202
listargs at the server and port given by server and port or encapsulated in
203
the connection.
204
205
Since EvaluateBySCSCP combines NewProcess (6.2-2) and CompleteProcess
206
(6.2-3), it accepts all options which may be used by that functions (
207
output, cd and debuglevel ) with the same meanings.
208
209
 Example 
210

211
gap> EvaluateBySCSCP( "WS_Factorial",[10],"localhost",26133);
212
#I Creating a socket ...
213
#I Connecting to a remote socket via TCP/IP ...
214
#I Got connection initiation message
215
#I Requesting version 1.3 from the server ...
216
#I Server confirmed version 1.3 to the client ...
217
#I Request sent ...
218
#I Waiting for reply ...
219
rec( attributes := [ [ "call_id", "localhost:26133:2442:6hMEN40d" ] ], 
220
 object := 3628800 )
221
gap> SetInfoLevel(InfoSCSCP,0);
222
gap> EvaluateBySCSCP( "WS_Factorial",[10],"localhost",26133 : output:="cookie" ); 
223
rec( attributes := [ [ "call_id", "localhost:26133:2442:jNQG6rml" ] ], 
224
 object := < remote object scscp://localhost:26133/TEMPVarSCSCP5KZIeiKD > )
225
gap> EvaluateBySCSCP( "WS_Factorial",[10],"localhost",26133 : output:="nothing" );
226
rec( attributes := [ [ "call_id", "localhost:26133:2442:9QHQrCjv" ] ], 
227
 object := "procedure completed" )
228

229

230
231
Now we demonstrate the procedure GroupIdentificationService, also given in
232
the previous chapter:
233
234
 Example 
235

236
gap> G:=SymmetricGroup(4);
237
Sym( [ 1 .. 4 ] )
238
gap> gens:=GeneratorsOfGroup(G);
239
[ (1,2,3,4), (1,2) ]
240
gap> EvaluateBySCSCP( "GroupIdentificationService", [ gens ],
241
>  "localhost", 26133 : debuglevel:=3 ); 
242
rec( attributes := [ [ "call_id", "localhost:26133:2442:xOilXtnw" ], 
243
 [ "info_runtime", 4 ], [ "info_memory", 2596114432 ], 
244
 [ "info_message", "Memory usage for the result is 48 bytes" ] ], 
245
 object := [ 24, 12 ] )
246

247

248
249
Service provider may suggest to the client to use a counterpart function
250
251
 Example 
252

253
gap> IdGroupWS := function( G )
254
>  local H, result;
255
>  if not IsPermGroup(G) then
256
>  H:= Image( IsomorphismPermGroup( G ) );
257
>  else
258
>  H := G;
259
>  fi; 
260
>  result := EvaluateBySCSCP ( "GroupIdentificationService", 
261
>  [ GeneratorsOfGroup(H) ], "localhost", 26133 );
262
>  return result.object;
263
> end;;
264

265

266
267
which works exactly like IdGroup (Reference: IdGroup):
268
269
 Example 
270

271
gap> G:=DihedralGroup(64);
272
<pc group of size 64 with 6 generators>
273
gap> IdGroupWS(G);
274
[ 64, 52 ]
275

276

277
278
279
6.4 Switching between Binary and XML OpenMath Encodings
280
281
6.4-1 SwitchSCSCPmodeToBinary
282
283
SwitchSCSCPmodeToBinary( )  function
284
SwitchSCSCPmodeToXML( )  function
285
Returns: nothing
286
287
The OpenMath package supports both binary and XML encodings for OpenMath. To
288
switch between them, use SwitchSCSCPmodeToBinary and SwitchSCSCPmodeToXML.
289
When the package is loaded, the mode is initially set to XML. On the
290
clients's side, you can change the mode back and forth as many times as you
291
wish during the same SCSCP session. The server will autodetect the mode and
292
will response in the same format, so one does not need to set the mode on
293
the server's side.
294
295
For example, let us create a vector over GF(3):
296
297
 Example 
298

299
gap> x := [ Z(3)^0, Z(3), 0*Z(3) ];
300
[ Z(3)^0, Z(3), 0*Z(3) ]
301

302

303
304
The XML OpenMath encoding of such objects is quite bulky:
305
306
 Example 
307

308
gap> OMString( x );
309
"<OMOBJ xmlns=\"http://www.openmath.org/OpenMath\" version=\"2.0\"> <OMA> <OMS\
310
 cd=\"list1\" name=\"list\"/> <OMA> <OMS cd=\"arith1\" name=\"power\"/> <OMA> \
311
<OMS cd=\"finfield1\" name=\"primitive_element\"/> <OMI>3</OMI> </OMA> <OMI>0<\
312
/OMI> </OMA> <OMA> <OMS cd=\"arith1\" name=\"power\"/> <OMA> <OMS cd=\"finfiel\
313
d1\" name=\"primitive_element\"/> <OMI>3</OMI> </OMA> <OMI>1</OMI> </OMA> <OMA\
314
> <OMS cd=\"arith1\" name=\"times\"/> <OMA> <OMS cd=\"finfield1\" name=\"primi\
315
tive_element\"/> <OMI>3</OMI> </OMA> <OMI>0</OMI> </OMA> </OMA> </OMOBJ>"
316
gap> Length( OMString(x) );
317
507
318

319

320
321
We call the SCSCP procedure Identity just to test how this object may be
322
sent back and forth. The total length of the procedure call message is 969
323
symbols:
324
325
 Example 
326

327
gap> SetInfoLevel(InfoSCSCP,3);
328
gap> EvaluateBySCSCP("Identity",[x],"localhost",26133);
329
#I Creating a socket ...
330
#I Connecting to a remote socket via TCP/IP ...
331
#I Got connection initiation message
332
#I <?scscp service_name="GAP" service_version="4.dev" service_id="localhost:2\
333
6133:42448" scscp_versions="1.0 1.1 1.2 1.3" ?>
334
#I Requesting version 1.3 from the server ...
335
#I Server confirmed version 1.3 to the client ...
336
#I Composing procedure_call message: 
337
<?scscp start ?>
338
<OMOBJ xmlns="http://www.openmath.org/OpenMath" version="2.0">
339
 <OMATTR>
340
 <OMATP>
341
 <OMS cd="scscp1" name="call_id"/>
342
 <OMSTR>localhost:26133:42448:IOs9ZkBU</OMSTR>
343
 <OMS cd="scscp1" name="option_return_object"/>
344
 <OMSTR></OMSTR>
345
 </OMATP>
346
 <OMA>
347
 <OMS cd="scscp1" name="procedure_call"/>
348
 <OMA>
349
 <OMS cd="scscp_transient_1" name="Identity"/>
350
 <OMA>
351
 <OMS cd="list1" name="list"/>
352
 <OMA>
353
 <OMS cd="arith1" name="power"/>
354
 <OMA>
355
 <OMS cd="finfield1" name="primitive_element"/>
356
 <OMI>3</OMI>
357
 </OMA>
358
 <OMI>0</OMI>
359
 </OMA>
360
 <OMA>
361
 <OMS cd="arith1" name="power"/>
362
 <OMA>
363
 <OMS cd="finfield1" name="primitive_element"/>
364
 <OMI>3</OMI>
365
 </OMA>
366
 <OMI>1</OMI>
367
 </OMA>
368
 <OMA>
369
 <OMS cd="arith1" name="times"/>
370
 <OMA>
371
 <OMS cd="finfield1" name="primitive_element"/>
372
 <OMI>3</OMI>
373
 </OMA>
374
 <OMI>0</OMI>
375
 </OMA>
376
 </OMA>
377
 </OMA>
378
 </OMA>
379
 </OMATTR>
380
</OMOBJ>
381
<?scscp end ?>
382
#I Total length 969 characters 
383
...
384
rec( attributes := [ [ "call_id", "localhost:26133:42448:IOs9ZkBU" ] ], 
385
 object := [ Z(3)^0, Z(3), 0*Z(3) ] )
386
 
387

388
389
Now we switch to binary mode:
390
391
 Example 
392

393
gap> SwitchSCSCPmodeToBinary();
394
gap> EvaluateBySCSCP("Identity",[x],"localhost",26133);
395
#I Creating a socket ...
396
#I Connecting to a remote socket via TCP/IP ...
397
#I Got connection initiation message
398
#I <?scscp service_name="GAP" service_version="4.dev" service_id="localhost:2\
399
6133:42448" scscp_versions="1.0 1.1 1.2 1.3" ?>
400
#I Requesting version 1.3 from the server ...
401
#I Server confirmed version 1.3 to the client ...
402
#I Composing procedure_call message: 
403
3C3F7363736370207374617274203F3E0A18121408060773637363703163616C6C5F6964061E6C\
404
6F63616C686F73743A32363133333A34323434383A3256675A5562755A0806147363736370316F\
405
7074696F6E5F72657475726E5F6F626A6563740600151008060E73637363703170726F63656475\
406
72655F63616C6C1008110873637363705F7472616E7369656E745F314964656E74697479100805\
407
046C697374316C69737410080605617269746831706F7765721008091166696E6669656C643170\
408
72696D69746976655F656C656D656E7401031101001110080605617269746831706F7765721008\
409
091166696E6669656C64317072696D69746976655F656C656D656E740103110101111008060561\
410
726974683174696D65731008091166696E6669656C64317072696D69746976655F656C656D656E\
411
7401031101001111111113193C3F736373637020656E64203F3E0A
412
#I Total length 339 bytes 
413
#I Request sent ...
414
#I Waiting for reply ...
415
#I <?scscp start ?>
416
#I Got back: object [ Z(3)^0, Z(3), 0*Z(3) ] with attributes 
417
[ [ "call_id", "localhost:26133:42448:2VgZUbuZ" ] ]
418
rec( attributes := [ [ "call_id", "localhost:26133:42448:2VgZUbuZ" ] ], 
419
 object := [ Z(3)^0, Z(3), 0*Z(3) ] )
420
gap> SetInfoLevel(InfoSCSCP,3);
421

422

423
424
As we can see, the size of the message is almost three times shorter, and
425
this is not the limit. Switching to binary OpenMath encoding in combination
426
with pickling and unpickling from IO package (see in the last Chapter) and
427
special methods for pickling compressed vectors implemented in the Cvec
428
available in GAP 4.5 allow to dramatically reduce the overhead for vectors
429
and matrices over finite fields, making a roundtrip up to a thousand times
430
faster.
431
432
433
6.5 Remote objects
434
435
The SCSCP package introduces new kind of objects - remote objects. They
436
provide an opportunity to manipulate with objects on remote services without
437
their actual transmitting over the network. Remote objects store the
438
information that allows to access the original object: the server name and
439
the port number through which the object can be accessed, and the variable
440
name under which it is stored in the remote system. Two remote objects are
441
equal if and only if all these three parameters coincide.
442
443
There are two types of remote object which differ by their lifetime:
444
445
 temporary remote objects which exist only within a single session;
446
447
 persistent remote objects which stay alive across multiple sessions.
448
449
First we show the example of the temporary remote object in a session. The
450
procedure PointImages returns the set of images of a point i under the
451
generators of the group G. First we create the symmetric group S_3 on the
452
client and store it remotely on the server (call 1), then we compute set of
453
images for i=1,2 (calls 2,3) and finally demonstrate that we may retrieve
454
the group from the server (call 4):
455
456
 Example 
457

458
gap> stream:=InputOutputTCPStream( "localhost", 26133 );
459
< input/output TCP stream to localhost:26133 >
460
gap> StartSCSCPsession(stream);
461
"localhost:26133:6184"
462
gap> OMPutProcedureCall( stream, "store_session", 
463
>  rec( object := [ SymmetricGroup(3) ], 
464
>  attributes := [ [ "call_id", "1" ], 
465
>  ["option_return_cookie"] ] ) );
466
true
467
gap> SCSCPwait( stream );
468
gap> G:=OMGetObjectWithAttributes( stream ).object;
469
< remote object scscp://localhost:26133/TEMPVarSCSCPo3Bc8J75 >
470
gap> OMPutProcedureCall( stream, "PointImages", 
471
>  rec( object := [ G, 1 ], 
472
>  attributes := [ [ "call_id", "2" ] ] ) );
473
true
474
gap> SCSCPwait( stream );
475
gap> OMGetObjectWithAttributes( stream );
476
rec( attributes := [ [ "call_id", "2" ] ], object := [ 2 ] )
477
gap> OMPutProcedureCall( stream, "PointImages", 
478
>  rec( object := [ G, 2 ], 
479
>  attributes := [ [ "call_id", "3" ] ] ) );
480
true
481
gap> SCSCPwait( stream );
482
gap> OMGetObjectWithAttributes( stream );
483
rec( attributes := [ [ "call_id", "3" ] ], object := [ 1, 3 ] )
484
gap> OMPutProcedureCall( stream, "retrieve", 
485
>  rec( object := [ G ], 
486
>  attributes := [ [ "call_id", "4" ] ] ) );
487
true
488
gap> SCSCPwait( stream );
489
gap> OMGetObjectWithAttributes( stream );
490
rec( attributes := [ [ "call_id", "4" ] ], 
491
 object := Group([ (1,2,3), (1,2) ]) )
492
gap> CloseStream(stream);
493

494

495
496
After the stream is closed, it is no longer possible to retrieve the group G
497
again or use it as an argument.
498
499
Thus, the usage of remote objects existing during a session reduces the
500
network traffic, since we pass only references instead of actual OpenMath
501
representation of an object. Also, the remote object on the server may
502
accumulate certain information in its properties and attributes, which may
503
not be included in it default OpenMath representation.
504
505
Now we show remote objects which remain alive after the session is closed.
506
Such remote objects may be accessed later, for example, by:
507
508
 subsequent procedure calls from the same instance of GAP or another
509
system;
510
511
 other instances of GAP or another systems (if the identifier of an
512
object is known)
513
514
 another SCSCP servers which obtained a reference to such object as an
515
argument of a procedure call.
516
517
6.5-1 StoreAsRemoteObjectPersistently
518
519
StoreAsRemoteObjectPersistently( obj, server, port )  function
520
StoreAsRemoteObject( obj, server, port )  function
521
Returns: remote object
522
523
Returns the remote object corresponding to the object created at server:port
524
from the OpenMath representation of the first argument obj. The second form
525
is just a synonym.
526
527
 Example 
528

529
gap> s:=StoreAsRemoteObject( SymmetricGroup(3), "localhost", 26133 );
530
< remote object scscp://localhost:26133/TEMPVarSCSCPLvIUUtL3 >
531

532

533
534
Internally, the remote object carries all the information which is required
535
to get access to the original object: its identifier, server and port:
536
537
 Example 
538

539
gap> s![1]; 
540
"TEMPVarSCSCPLvIUUtL3"
541
gap> s![2];
542
"localhost"
543
gap> s![3];
544
26133
545

546

547
548
When the remote object is printed in the OpenMath format, we use symbols @
549
and : to combine these parameters in the OpenMath reference:
550
551
 Example 
552

553
gap> OMPrint(s);
554
<OMOBJ>
555
 <OMR href="scscp://localhost:26133/TEMPVarSCSCPLvIUUtL3" />
556
</OMOBJ>
557

558

559
560
This allows substitution of remote object as arguments into procedure calls
561
in the same manner like we do this with usual objects:
562
563
 Example 
564

565
gap> EvaluateBySCSCP("WS_IdGroup",[s],"localhost",26133); 
566
rec( attributes := [ [ "call_id", "localhost:26133:52918:Viq6EWBP" ] ],
567
Line 183 : 
568
 object := [ 6, 1 ] )
569

570

571
572
6.5-2 IsRemoteObject
573
574
IsRemoteObject filter
575
576
This is the category of remote objects.
577
578
6.5-3 RemoteObjectsFamily
579
580
RemoteObjectsFamily family
581
582
This is the family of remote objects.
583
584
6.5-4 RetrieveRemoteObject
585
586
RetrieveRemoteObject( remoteobject )  function
587
Returns: object
588
589
This function retrieves the remote object from the remote service in the
590
OpenMath format and constructs it locally. Note, however, that for a complex
591
mathematical object its default OpenMath representation may not contain all
592
information about it which was accumulated during its lifetime on the SCSCP
593
server.
594
595
 Example 
596

597
gap> RetrieveRemoteObject(s);
598
Group([ (1,2,3), (1,2) ])
599

600

601
602
6.5-5 UnbindRemoteObject
603
604
UnbindRemoteObject( remoteobject )  function
605
Returns: true or false
606
607
Removes any value currently bound to the global variable determined by
608
remoteobject at the SCSCP server, and returns true or false dependently on
609
whether this action was successful or not.
610
611
 Example 
612

613
gap> UnbindRemoteObject(s);
614
true
615

616

617
618
Finally, we show an example when first we create a group on the service
619
running on port 26133, and then identify it on the service running on port
620
26134:
621
622
 Example 
623

624
gap> s:=StoreAsRemoteObject( SymmetricGroup(3), "localhost", 26133 );
625
< remote object scscp://localhost:26133/TEMPVarSCSCPNqc8Bkan >
626
gap> EvaluateBySCSCP( "WS_IdGroup", [ s ], "localhost", 26134 );
627
rec( object := [ 6, 1 ], attributes := [ [ "call_id", "localhost:26134:7414" ] ] )
628

629

630
631
Instead of transmitting the group to the client and then sending it as an
632
argument to the second service, the latter service directly retrieves the
633
group from the first service:
634
635
 Example 
636

637
gap> EvaluateBySCSCP("WS_IdGroup",[s],"localhost",26133 : output:="cookie" );
638
rec( attributes := [ [ "call_id", "localhost:26133:52918:mRU6w471" ] ], 
639
 object := < remote object scscp://localhost:26133/TEMPVarSCSCPS9SVe9PZ > )
640

641

642
643
644