Skip to content

Commit

Permalink
change: Upgrade Firestore and Storage Dependencies (#1760)
Browse files Browse the repository at this point in the history
- Upgraded Firestore and Storage dependencies to their latest versions. As a result the following updates were also needed.
- Upgrade TypeScript to 4.x [breaking change!]
- Update the target settings in tsconfig. Since we drop support for Node.js 12, adopted the optimal settings for Node.js 14.
- Dropped support for Node.js 12 and updated the CIs to run on Node.js 14. Will also add Node.js 16 in a future PR.
  • Loading branch information
lahirumaramba committed Jun 14, 2022
1 parent ba2bb67 commit 5de2864
Show file tree
Hide file tree
Showing 16 changed files with 204 additions and 144 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:

strategy:
matrix:
node-version: [12.x, 14.x]
node-version: [14.x]

steps:
- uses: actions/checkout@v1
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v1
with:
node-version: 12.x
node-version: 14.x

- name: Install and build
run: |
Expand Down Expand Up @@ -116,7 +116,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v1
with:
node-version: 12.x
node-version: 14.x

- name: Publish preflight check
id: preflight
Expand Down
6 changes: 3 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,9 @@ information on using pull requests.

### Prerequisites

1. Node.js 10.13.0 or higher.
2. NPM 5 or higher (NPM 6 recommended).
3. Google Cloud SDK ([`gcloud`](https://cloud.google.com/sdk/downloads) utility)
1. Node.js 14 or higher.
2. `npm` 6 or higher.
3. Google Cloud SDK ([`gcloud`](https://cloud.google.com/sdk/downloads) utility).

### Initial Setup

Expand Down
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ requests, code review feedback, and also pull requests.

## Supported Environments

We support Node.js 12 and higher. However, Node.js 12 support is deprecated. We strongly encourage
you to use Node.js 14 or higher as we will drop support for Node.js 12 in the next major version.
We support Node.js 14 and higher.

Please also note that the Admin SDK should only
be used in server-side/back-end environments controlled by the app developer.
Expand Down
8 changes: 8 additions & 0 deletions etc/firebase-admin.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,14 @@ export namespace firestore {
import WhereFilterOp = _firestore.WhereFilterOp;
import WriteBatch = _firestore.WriteBatch;
import WriteResult = _firestore.WriteResult;
import PartialWithFieldValue = _firestore.PartialWithFieldValue;
import WithFieldValue = _firestore.WithFieldValue;
import Primitive = _firestore.Primitive;
import NestedUpdateFields = _firestore.NestedUpdateFields;
import ChildUpdateFields = _firestore.ChildUpdateFields;
import AddPrefixToKeys = _firestore.AddPrefixToKeys;
import UnionToIntersection = _firestore.UnionToIntersection;
import ReadOnlyTransactionOptions = _firestore.ReadOnlyTransactionOptions;
import setLogFunction = _firestore.setLogFunction;
}

Expand Down
24 changes: 24 additions & 0 deletions etc/firebase-admin.firestore.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@

/// <reference types="node" />

import { AddPrefixToKeys } from '@google-cloud/firestore';
import { Agent } from 'http';
import { BulkWriter } from '@google-cloud/firestore';
import { BulkWriterOptions } from '@google-cloud/firestore';
import { BundleBuilder } from '@google-cloud/firestore';
import { ChildUpdateFields } from '@google-cloud/firestore';
import { CollectionGroup } from '@google-cloud/firestore';
import { CollectionReference } from '@google-cloud/firestore';
import { DocumentChange } from '@google-cloud/firestore';
Expand All @@ -23,30 +25,40 @@ import { Firestore } from '@google-cloud/firestore';
import { FirestoreDataConverter } from '@google-cloud/firestore';
import { GeoPoint } from '@google-cloud/firestore';
import { GrpcStatus } from '@google-cloud/firestore';
import { NestedUpdateFields } from '@google-cloud/firestore';
import { OrderByDirection } from '@google-cloud/firestore';
import { PartialWithFieldValue } from '@google-cloud/firestore';
import { Precondition } from '@google-cloud/firestore';
import { Primitive } from '@google-cloud/firestore';
import { Query } from '@google-cloud/firestore';
import { QueryDocumentSnapshot } from '@google-cloud/firestore';
import { QueryPartition } from '@google-cloud/firestore';
import { QuerySnapshot } from '@google-cloud/firestore';
import { ReadOnlyTransactionOptions } from '@google-cloud/firestore';
import { ReadOptions } from '@google-cloud/firestore';
import { setLogFunction } from '@google-cloud/firestore';
import { SetOptions } from '@google-cloud/firestore';
import { Settings } from '@google-cloud/firestore';
import { Timestamp } from '@google-cloud/firestore';
import { Transaction } from '@google-cloud/firestore';
import { UnionToIntersection } from '@google-cloud/firestore';
import { UpdateData } from '@google-cloud/firestore';
import { v1 } from '@google-cloud/firestore';
import { WhereFilterOp } from '@google-cloud/firestore';
import { WithFieldValue } from '@google-cloud/firestore';
import { WriteBatch } from '@google-cloud/firestore';
import { WriteResult } from '@google-cloud/firestore';

export { AddPrefixToKeys }

export { BulkWriter }

export { BulkWriterOptions }

export { BundleBuilder }

export { ChildUpdateFields }

export { CollectionGroup }

export { CollectionReference }
Expand Down Expand Up @@ -78,10 +90,16 @@ export function getFirestore(app?: App): Firestore;

export { GrpcStatus }

export { NestedUpdateFields }

export { OrderByDirection }

export { PartialWithFieldValue }

export { Precondition }

export { Primitive }

export { Query }

export { QueryDocumentSnapshot }
Expand All @@ -90,6 +108,8 @@ export { QueryPartition }

export { QuerySnapshot }

export { ReadOnlyTransactionOptions }

export { ReadOptions }

export { setLogFunction }
Expand All @@ -102,12 +122,16 @@ export { Timestamp }

export { Transaction }

export { UnionToIntersection }

export { UpdateData }

export { v1 }

export { WhereFilterOp }

export { WithFieldValue }

export { WriteBatch }

export { WriteResult }
Expand Down

0 comments on commit 5de2864

Please sign in to comment.