-
Notifications
You must be signed in to change notification settings - Fork 1k
feat(data-connect): Caching for FDC #9439
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
+3,206
−534
Merged
Changes from all commits
Commits
Show all changes
91 commits
Select commit
Hold shift + click to select a range
e0a1861
First pass
maneesht 32facb6
Added caching support
maneesht 0229168
WIP
maneesht bcd9ebe
Done with first pass
maneesht 764d4ee
Fixed test
maneesht e476774
WIP
maneesht b079c53
Renamed files
maneesht 189833b
Final indexeddb pass
maneesht c83b140
Fixed temp
maneesht a5b8fe6
WIP
maneesht 78c71fc
Fix build
maneesht 4058d93
WIP
maneesht 3eae4e3
Fixed bdo parsing
maneesht d86e71f
InMemoryCacheProvider added
maneesht fcd22d5
Second pass
maneesht 7472d5d
Completed first pass of caching
maneesht 9f17eac
Fixed formatting
maneesht 4a8c6fd
Added todo
maneesht a94c607
Added entity id tracking
maneesht beaaa5c
Added todo for later
maneesht 69bc0ec
Completed most todos
maneesht 79a4031
Wrote unit test for caching
maneesht 019b4a7
Added maxAge
maneesht 0b8523b
Removed unnecessary types
maneesht 15faa32
Fixed onComplete issue
maneesht 223a1fa
Got all tests to pass
maneesht e338976
Fixed extensions parsing algorithm
maneesht 7e86e48
Added SSR
maneesht 1c189df
Cleaned up api
maneesht c50f7a8
Addressed gemini comment for register.ts
maneesht baba5c0
Fixed formatting
maneesht e9fbf67
Removed unnecessary file
maneesht 7999c99
Aligned code more towards Swift and other SDKs
maneesht a481ed2
Formatted
maneesht 5d0729a
Completed integration and fixed issue where maxAgeS wasn't being resp…
maneesht 80b83a1
Fixed formatting
maneesht 4737276
Resolved naming feedback
maneesht 76a2e3c
Fixed errors
maneesht bc1e32e
Resolved comments
maneesht 37d3760
Formatting pass
maneesht 93f871e
Wrote more entity node tests
maneesht 7409029
Fixed a todo
maneesht 4505dec
test(ai): Update LiveAPI model names in integration tests (#9420)
hsubox76 82e572c
fix(ai): correct typo 'seperate' to 'separate' in imagen internal typ…
Yash7256 eac8cf0
feat/pipelines to main (#9356)
MarkDuckworth 77bffff
TSDoc tag cleanup (#9442)
MarkDuckworth 6303cc0
fix(ai): update hybrid in-cloud default model to gemini 2.5 flash lit…
hsubox76 5b4ac1a
build(firestore): Strip forgotten export warnings from pipelines api …
hsubox76 8d42bc5
feat(ai): Add support for `AbortSignal` (#8890)
dlarocque b8facd6
feat(ai): Add thinking levels parameter (#9424)
hsubox76 2881a75
feat(rc): Web support for ABT & Rollouts (#9449)
athiramanu 3395c2f
test(e2e): update jest (#9451)
hsubox76 b3efcd6
test(e2e): force jest to use browser (#9455)
hsubox76 7aa76d1
Version Packages (#9453)
google-oss-bot 89d4abd
ci(ai): Only run mock responses check on AI PRs (#9335)
dlarocque 77b0e17
Remove undesired exists() conditions from query-to-pipeline conversio…
wu-hui 93a732c
feat(firestore): add support for regexFind and regexFindAll (#9459)
dlarocque 1efa7f4
test(firestore): Accept `grep` as an argument to `run_tests.ts` (#9452)
dlarocque 681dcbe
test(firestore): silence stack trace output from `run_tests.ts` (#9454)
dlarocque 6739726
feat(ai): implicit caching feature (#9462)
hsubox76 aa6b776
fix(firestore): log a warning when `databaseId` is not found (#9472)
dlarocque 7eca446
feat(ai): Add tag to log requests made to cloud models while in hybri…
hsubox76 aa96b41
feat(ai) Live Service Going Away notifications (#9461)
DellaBitta f314b30
feat(ai): Remove preview tags from code execution and URL context fea…
hsubox76 b59aedf
chore: update browserslist DB version (#9478)
dlarocque a90347f
Version Packages (#9481)
google-oss-bot 5d92674
Merge remote-tracking branch 'origin/main' into mtewani/caching-first…
maneesht f7fb9af
Updated the types
maneesht de6d3d8
Removed generated dataconnect files
maneesht de8d157
Removed unused type
maneesht c54013b
Fixed error
maneesht 762dc2b
Addressed rename for updateEntity
maneesht 1b35781
Removed todos
maneesht 67fbc02
Resolved many comments
maneesht 4023f05
Added more complex example
maneesht c13269e
Fix formatting
maneesht bd04e36
Added more complex example
maneesht 566c0e4
Fixed public api
maneesht 2049a14
Addressed comments
maneesht b143103
Added maxAge support
maneesht eb0997c
Fixed all tests
maneesht d5eba79
Ran yarn docgen
maneesht 09fd37f
Merge remote-tracking branch 'origin/main' into mtewani/caching-first…
maneesht d0f7677
Fix formatting
maneesht 32b3595
Removed commented code
maneesht a40b334
Removed last todo
maneesht 26412b7
Fixed sha256
maneesht 320fefc
Create fast-cherries-fold.md
maneesht 3972466
Formatted
maneesht 36dfc6f
Added firebase minor
maneesht 52fd00b
Removed unnecessary cachesettings extension
maneesht File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| --- | ||
| "@firebase/data-connect": minor | ||
| "@firebase/util": minor | ||
| "firebase": minor | ||
| --- | ||
|
|
||
| Add Memory-Based caching to Queries in Firebase Data Connect. | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 9 additions & 0 deletions
9
e2e/data-connect/dataconnect-generated/js/default-connector/.guides/config.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| { | ||
| "description": "A set of guides for interacting with the generated firebase dataconnect sdk", | ||
| "mcpServers": { | ||
| "firebase": { | ||
| "command": "npx", | ||
| "args": ["-y", "firebase-tools@latest", "experimental:mcp"] | ||
| } | ||
| } | ||
| } |
20 changes: 20 additions & 0 deletions
20
e2e/data-connect/dataconnect-generated/js/default-connector/.guides/setup.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| # Setup | ||
|
|
||
| If the user hasn't already installed the SDK, always run the user's node package manager of choice, and install the package in the directory ../package.json. | ||
| For more information on where the library is located, look at the connector.yaml file. | ||
|
|
||
| ```ts | ||
| import { initializeApp } from 'firebase/app'; | ||
|
|
||
| initializeApp({ | ||
| // fill in your project config here using the values from your Firebase project or from the `firebase_get_sdk_config` tool from the Firebase MCP server. | ||
| }); | ||
| ``` | ||
|
|
||
| Then, you can run the SDK as needed. | ||
| ```ts | ||
| import { ... } from '@firebasegen/default-connector'; | ||
| ``` | ||
|
|
||
|
|
||
|
|
27 changes: 27 additions & 0 deletions
27
e2e/data-connect/dataconnect-generated/js/default-connector/.guides/usage.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| # Basic Usage | ||
|
|
||
| Always prioritize using a supported framework over using the generated SDK | ||
| directly. Supported frameworks simplify the developer experience and help ensure | ||
| best practices are followed. | ||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
| ## Advanced Usage | ||
| If a user is not using a supported framework, they can use the generated SDK directly. | ||
|
|
||
| Here's an example of how to use it with the first 5 operations: | ||
|
|
||
| ```js | ||
| import { createMovie, listMovies } from '@firebasegen/default-connector'; | ||
|
|
||
|
|
||
| // Operation CreateMovie: For variables, look at type CreateMovieVars in ../index.d.ts | ||
| const { data } = await CreateMovie(dataConnect, createMovieVars); | ||
|
|
||
| // Operation ListMovies: | ||
| const { data } = await ListMovies(dataConnect); | ||
maneesht marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
|
|
||
| ``` | ||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.