Pardon our mess! We are busy building up docs for our beta users.
A service is defined by a YAML/JSON configuration file in the located at
.ffleet/config.yml within your project source.
The configuration file is required to specify the configuration of your service and the execution role permissions of your functions. Defining these behaviors in the configuration file allows your service configuration to live with your code and be versioned along with your service code.
A configuration file is required to deploy your service. Deployment will fail if a config file can't be located, or is not valid YAML/JSON.
A minimal service configuration is shown below. This configuration defines a simple service that consists of one Node.js function and a corresponding cron job that calls the function every minute.
version: 1 role: arn:aws:iam::123456789012:role/role-name runtime: node8 functions: my-function: handler: my_file.my_function_export cron: test: function: my-function rate: 1m
The configuration version is required must be
This is the lambda execution role that your configured functions will use during execution. Refer to the AWS guide for more information on creating an execution role.
The runtime configuration specifies which runtime platform your functions require. Possible values are:
Timeout refers to the maximum number of seconds the function may execute before it is stopped and reported as a failure. The default value is 10, allowing for 10 seconds.
You may specify the amount of RAM that is provided to your function, between 128(MB) and 1536(MB) in multiples of 64(MB). The amount of Memory you allocate to your function also correlates with the amount of CPU time (power) that is allocated to the function. A 256MB function will have roughly twice the processing power of a 128MB function.
The functions map defines the functions available within your service. A function must be declared here in order to be referenced elsewhere in your config file.
Cron functions can be used to schedule your function execution at a specific time, or on a certain interval period (e.g. every hour, very 7 days).
Publisher/Subscriber patterns allow you to pass messages between functions, or fan-out one function execution to many. This is backed by the AWS SNS platform, but conveniently handled by Functional Fleet.