You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Faast.js makes regular functions callable as serverless functions on AWS Lambda and Google Cloud. It handles the details of uploading your code, creating cloud infrastructure, and cleaning up. Scale up your functions to a thousand cores in seconds :rocket:
5
+
Faast.js makes regular functions callable as serverless functions on AWS Lambda. It handles the details of uploading your code, creating cloud infrastructure, and cleaning up. Scale up your functions to a thousand cores in seconds :rocket:
6
6
7
7
Faast.js is a pure library with no service dependencies, operational overhead, or unnecessary complexity.
8
8
@@ -71,7 +71,7 @@ $0.00420858
71
71
-**Cost-effective.** Understand and optimize your workload costs in real time. Pay only for compute time actually used.
72
72
-**Ephemeral.** No clusters or services to manage. Faast.js creates the infrastructure it uses on the fly and cleans up when it's done.
73
73
-**Productive.** First class support for TypeScript and JavaScript. Type safety, documentation, and extensive testing are part of our DNA.
74
-
-**Multi-cloud:** Built-in support for AWS Lambda and Google Cloud Functions, as well as local processing mode when you don't have network access. Switch with one line of code.
74
+
-**Local.** Built-in support for AWS Lambda and local processing mode when you don't have network access. Switch with one line of code.
Copy file name to clipboardExpand all lines: docs/01-introduction.md
+4-13Lines changed: 4 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -20,8 +20,6 @@ Using the local provider allows you to test faast.js on your local machine. Ther
20
20
21
21
AWS is recommended for optimal faast.js performance. See [AWS setup instructions](./04-aws.md#setup).
22
22
23
-
Google Cloud is also supported. See [Google Cloud setup instructions](./05-google-cloud.md#setup).
24
-
25
23
## Usage
26
24
27
25
Cloud functions can be written as ordinary TypeScript or JavaScript modules:
@@ -109,7 +107,6 @@ Try out different providers:
109
107
110
108
```typescript
111
109
awaitfaast("aws", funcs);
112
-
awaitfaast("google", funcs);
113
110
awaitfaast("local", funcs);
114
111
```
115
112
@@ -147,15 +144,15 @@ await faast("aws", funcs, {
147
144
});
148
145
```
149
146
150
-
Read more about [package dependencies on AWS](./04-aws.md#package-dependencies) and [package dependencies on Google Cloud](./05-google-cloud.md#package-dependencies).
147
+
Read more about [package dependencies on AWS](./04-aws.md#package-dependencies).
151
148
152
-
Check out even more options in [CommonOptions](./api/faastjs.commonoptions.md) and cloud-specific options in [AwsOptions](./api/faastjs.awsoptions.md), [GoogleOptions](./api/faastjs.googleoptions.md), and [LocalOptions](./api/faastjs.localoptions.md).
149
+
Check out even more options in [CommonOptions](./api/faastjs.commonoptions.md) and cloud-specific options in [AwsOptions](./api/faastjs.awsoptions.md) and [LocalOptions](./api/faastjs.localoptions.md).
153
150
154
151
## Terminology
155
152
156
-
**Provider**: A Functions as a Service (FaaS) provider, such as AWS Lambda or Google Cloud Functions. Faast.js also has a "local" provider which uses child processes to simulate a FaaS service without cloud usage.
153
+
**Provider**: A Functions as a Service (FaaS) provider, such as AWS Lambda. Faast.js also has a "local" provider which uses child processes to simulate a FaaS service without cloud usage.
157
154
158
-
**faast.js module**, also known as **faast module**: A wrapper around an ordinary JavaScript/TypeScript module that transforms exported ordinary functions into cloud functions. A faast.js module corresponds to a single AWS Lambda or Google Cloud Function that multiplexes requests to all of the functions exported by the module.
155
+
**faast.js module**, also known as **faast module**: A wrapper around an ordinary JavaScript/TypeScript module that transforms exported ordinary functions into cloud functions. A faast.js module corresponds to a single AWS Lambda that multiplexes requests to all of the functions exported by the module.
159
156
160
157
**Remote function**: A function within a faast.js module instantiated on a provider.
Copy file name to clipboardExpand all lines: docs/02-development-workflow.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ There's a natural way to use faast.js to maximize developer productivity:
14
14
15
15
3. Use the `"local"` provider to test your function as a faast.js module. In this mode your invocations execute in local processes. Debug any issues using standard debugging tools you know and love. Make sure your functions are idempotent by invoking them multiple times concurrently with the same arguments.
16
16
17
-
4. Switch from `"local"` to `"aws"`or `"google"`but limit [concurrency](./api/faastjs.commonoptions.concurrency.md) to a low amount, between 1-10. Use [logUrl](./api/faastjs.faastmodule.logurl.md) to review cloud logs of your code executing. The [DEBUG](#debug-environment-variable) environment variable can be useful to see verbose output as well.
17
+
4. Switch from `"local"` to `"aws"` but limit [concurrency](./api/faastjs.commonoptions.concurrency.md) to a low amount, between 1-10. Use [logUrl](./api/faastjs.faastmodule.logurl.md) to review cloud logs of your code executing. The [DEBUG](#debug-environment-variable) environment variable can be useful to see verbose output as well.
18
18
19
19
5. Next, run a sample of your workload through [cost analyzer](./api/faastjs.costanalyzer.md) to find a good cost-performance tradeoff for the choice of memory size. A good default choice for CPU or S3-bandwidth bound workloads is between 1728MV-2048MB on AWS.
Copy file name to clipboardExpand all lines: docs/03-cost-estimates.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -83,7 +83,7 @@ Cost estimates are estimates. They do not capture all costs, and you should not
83
83
84
84
- The estimates do not take into account free tiers.
85
85
86
-
- The estimates assume worst-case tier pricing. If your cloud usage is extensive you may qualify for lower priced tiers (however AWS Lambda and Google Cloud Functions currently do not have tiered pricing, and usually account for most of the cost of faast.js workloads).
86
+
- The estimates assume worst-case tier pricing. If your cloud usage is extensive you may qualify for lower priced tiers (however AWS Lambda currently do not have tiered pricing, and usually account for most of the cost of faast.js workloads).
87
87
88
88
- Ongoing storage costs such as S3 storage are not counted because they are ongoing and not ephemeral.
Copy file name to clipboardExpand all lines: docs/07-throttling-scaling.md
-2Lines changed: 0 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,8 +12,6 @@ Running programs at scale introduce new issues. This topic covers some of these
12
12
13
13
AWS Lambda has documented [limits](https://docs.aws.amazon.com/lambda/latest/dg/limits.html). In particular, the default concurrency limit for lambda invocations is 1000 per account. This limit can be increased by request.
14
14
15
-
Google Cloud Functions has several [quotas](https://cloud.google.com/functions/quotas).
16
-
17
15
## Tail latency
18
16
19
17
When running hundreds or thousands of requests, it is not uncommon that a small number of requests hit a bottleneck, such as network congestion or storage system lags. If even 0.1% of requests takes a very long time, then a job with 1000 concurrent invocations can be held up even if almost all of the work is finished.
Copy file name to clipboardExpand all lines: docs/09-limitations.md
-4Lines changed: 0 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -43,10 +43,6 @@ Arguments and return values are sent through each provider's API or through a cl
43
43
44
44
Limits for AWS Lambda are published [here](https://docs.aws.amazon.com/lambda/latest/dg/limits.html). These limits manifest differently for [https vs queue mode](./04-aws.md#queue-vs-https-mode).
45
45
46
-
### Google Limits
47
-
48
-
Limits for Google Cloud Functions are published [here](https://cloud.google.com/functions/quotas). As of March 2019 the limits are for arguments and return values is 10MB.
49
-
50
46
### Local limits
51
47
52
48
In local mode, faast.js uses node's [`process.send()`](https://nodejs.org/api/process.html#process_process_send_message_sendhandle_options_callback) to send messages to worker processes. The IPC limits are OS-specific.
0 commit comments