...
Textstyles | ||
---|---|---|
| ||
DRAFT SPEC | Services not yet live |
The Charity Engine Smart Proxy Post Processing (SP3) interface allows web data that is collected via Smart Proxy scripts to be processed by any application or execution environment available or supported by the Charity Engine network. This processing takes place on the same node that collects the data.
...
To submit data for local processing on the proxy node, include reference the autoloaded "charityengine" module in a Node.js module in a smart proxy script, and call the desired processing function . (See *see Section 2 below for definitions of specific functions).
...
Any image that can be pulled from Docker Hub can be used for post-processing by calling the docker()
function (*subject to specs of instance types used):
Code Block | ||
---|---|---|
| ||
charityengine.docker(image, commandline, inputfile) PARAMETERS image // Name of the Docker image to run [string] [required] commandline // Command to execute within the container [string] [required] inputfile // Names of local files to use as input [array of string] |
Execution Environments
The default execution environment is Node.js, per Section 1 above, "General Usage". For running source code or scripts in other interpreted languages, functions are available for named execution environments.
...
just download the execution environment of your choice from Docker Hub, following the instructions in Section 2.1 above. For example,
(TODO: provide Python example using Docker)
Code Block | ||
---|---|---|
| ||
charityengine.python(commandline, inputfile) PARAMETERS commandline // Command line for the application [string] [required] inputfile // Names of local files to use as input [array of string] |
...