| GOLF(2gg) | Development | GOLF(2gg) |
NAME¶
run-remote - (distributed-computing)
PURPOSE¶
Call a remote service in a single statement.
SYNTAX¶
run-remote <service> \
( local <app name> ) | ( location <location> ) \
url-path <service URL> |
( \
app-path <app path> \
request-path <request path> \
[ url-params <url params> ] \
) \
[ request-body content <content> \
[ content-length <content length> ] \
[ content-type <content type> ] ] \
[ method <request method> ] \
[ environment <name>=<value> [ , ... ] ] \
[ timeout <timeout> ]\
[ status <status> ] \
[ started <started> ] \
[ finished-okay <finished okay> ]\
[ data <data> ] \
[ error <error> ] \
[ status <status> ] \
[ status-text <status text> ] \
[ exit-status <service status> ]
`
DESCRIPTION¶
run-remote is a combination of new-remote, call-remote and read-remote in one. Clauses for each of those can be specified in any order. Only a single <service> can be used. If a call to <service> succeeds, its results are read. Use either:
See details for each clause in new-remote (for "local" through "timeout" clauses), call-remote (for "status" through "finished-okay" clauses) and read-remote (for "data" through "exit-status" clauses).
EXAMPLES¶
begin-handler /serv public
run-remote nf local "hash-server-yey" \
url-path "/hash-server-yey/server/op=add/key=sb_XYZ/data=sdb_123" \
finished-okay sfok \
data rdata error edata \
status st exit-status rstatus
if-true sfok not-equal 1 or st not-equal GG_OKAY
@Call did not succeed
else-if
@Result is <<print-out rdata> and (any) error is <<print-out edata>>
end-if end-handler
SEE ALSO¶
Distributed computing
call-remote new-remote read-remote run-remote See all documentation
| $VERSION | $DATE |