Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: firebase/firebase-functions
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v3.5.0
Choose a base ref
...
head repository: firebase/firebase-functions
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v3.6.0
Choose a head ref
  • 7 commits
  • 7 files changed
  • 5 contributors

Commits on Mar 20, 2020

  1. Copy the full SHA
    0921c78 View commit details

Commits on Mar 23, 2020

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    5250110 View commit details

Commits on Mar 25, 2020

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    468455d View commit details

Commits on Mar 31, 2020

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    e1df823 View commit details
  2. Copy the full SHA
    7f4c957 View commit details
  3. Copy the full SHA
    95d4a4a View commit details
  4. 3.6.0

    google-oss-bot committed Mar 31, 2020
    Copy the full SHA
    c9a3a0e View commit details
Showing with 21 additions and 14 deletions.
  1. +2 −11 CHANGELOG.md
  2. +12 −0 docgen/content-sources/toc.yaml
  3. +1 −1 package.json
  4. +2 −0 spec/function-builder.spec.ts
  5. +2 −1 src/cloud-functions.ts
  6. +1 −0 src/function-configuration.ts
  7. +1 −1 src/providers/https.ts
13 changes: 2 additions & 11 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,2 @@
- Adds support for defining max number of instances for a function. Example:

```
functions.runWith({
maxInstances: 10
}).https.onRequest(...);
```

Learn more about max instances in the [Google Cloud documentation.](https://cloud.google.com/functions/docs/max-instances)

- Fixes TypeScript build error when `package-lock.json` is present by updating dependencies (Issue #637).
- Adds support for europe-west3 region (e.g. `functions.region("europe-west3")`).
- Adds support for async HTTP functions (Issue #606).
12 changes: 12 additions & 0 deletions docgen/content-sources/toc.yaml
Original file line number Diff line number Diff line change
@@ -116,3 +116,15 @@ toc:
path: /docs/reference/functions/providers_storage_.objectbuilder.html
- title: 'ObjectMetadata'
path: /docs/reference/functions/providers_storage_.objectmetadata.html

- title: 'functions.testLab'
path: /docs/reference/functions/providers_testlab_.html
section:
- title: 'testLab.clientInfo'
path: /docs/reference/functions/providers_testlab_.clientinfo.html
- title: 'testLab.resultStorage'
path: /docs/reference/functions/providers_testlab_.resultstorage.html
- title: 'testLab.testMatrix'
path: /docs/reference/functions/providers_testlab_.testmatrix.html
- title: 'testLab.testMatrixBuilder'
path: /docs/reference/functions/providers_testlab_.testmatrixbuilder.html
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "firebase-functions",
"version": "3.5.0",
"version": "3.6.0",
"description": "Firebase SDK for Cloud Functions",
"keywords": [
"firebase",
2 changes: 2 additions & 0 deletions spec/function-builder.spec.ts
Original file line number Diff line number Diff line change
@@ -59,6 +59,7 @@ describe('FunctionBuilder', () => {
'us-east4',
'europe-west1',
'europe-west2',
'europe-west3',
'asia-east2',
'asia-northeast1'
)
@@ -71,6 +72,7 @@ describe('FunctionBuilder', () => {
'us-east4',
'europe-west1',
'europe-west2',
'europe-west3',
'asia-east2',
'asia-northeast1',
]);
3 changes: 2 additions & 1 deletion src/cloud-functions.ts
Original file line number Diff line number Diff line change
@@ -104,11 +104,12 @@ export interface EventContext {
* * `providers/cloud.firestore/eventTypes/document.update`
* * `providers/cloud.firestore/eventTypes/document.delete`
* * `google.pubsub.topic.publish`
* * `google.firebase.remoteconfig.update`
* * `google.storage.object.finalize`
* * `google.storage.object.archive`
* * `google.storage.object.delete`
* * `google.storage.object.metadataUpdate`
* * `google.firebase.remoteconfig.update`
* * `google.testing.testMatrix.complete`
*/
eventType: string;

1 change: 1 addition & 0 deletions src/function-configuration.ts
Original file line number Diff line number Diff line change
@@ -7,6 +7,7 @@ export const SUPPORTED_REGIONS = [
'us-east4',
'europe-west1',
'europe-west2',
'europe-west3',
'asia-east2',
'asia-northeast1',
] as const;
2 changes: 1 addition & 1 deletion src/providers/https.ts
Original file line number Diff line number Diff line change
@@ -60,7 +60,7 @@ export function _onRequestWithOptions(
): HttpsFunction {
// lets us add __trigger without altering handler:
const cloudFunction: any = (req: Request, res: express.Response) => {
handler(req, res);
return handler(req, res);
};
cloudFunction.__trigger = _.assign(optionsToTrigger(options), {
httpsTrigger: {},