What’s new with Firestore at Next ‘24
Minh Nguyen
Senior Product Manager, Lead
Doron Meyer
Engineering Manager
Developers love Firestore because of how fast they can build applications and services end to end. As of today, Firestore has more than 500,000 monthly active developers, and Firestore apps power more than 1.3 billion monthly active end users using Firebase Auth. Recently, we’ve made updates to Firestore to improve developer productivity, enable developers to build the next generation AI-enabled applications, express richer queries, and help ensure that Firestore databases meet enterprises’ ever-growing needs.
Using Gemini to build applications with Firestore
We’re excited to share that Gemini Code Assist now incorporates assistive capabilities for developing with Firestore. Using Gemini Code Assist, along with your favorite Integrated Development Environment (IDE), you can use natural language to define your Firestore data models and write queries. For example, you can express queries using natural language statements like “get products from Firestore inventory collection” and translate that into Firestore SDK code in your favorite programming language:
Use natural language to write a Firestore query with Gemini Code Assist
To get started, refer to the Gemini Code Assist documentation to install the plugin for your favorite IDE, including Visual Studio Code, IntelliJ or Cloud Code.
You can also use Gemini to generate solution architectures and provision Firestore resources. Simply use the Gemini in Cloud Run application canvas in private preview, and type in a prompt like “LangChain app with Firestore and Vertex.”
Use natural language using Gemini in Cloud Run application canvas, to generate a solution architecture that includes Firestore
You can learn more about the Gemini in Cloud Run application canvas here.
Build next-gen AI-enabled applications
If you’re trying to build AI-enabled solutions such as a chatbot or recommendations engine, Firestore has you covered. Firestore now has built-in support for vector search using exact nearest neighbors, the ability to automatically generate vector embeddings using popular embedding models via a turn-key extension, and integrations with popular generative AI libraries such as LangChain and LlamaIndex.
Here’s an example of using Firestore’s vector search capabilities:
To get started, refer to the Firestore Vector Search documentation, Firestore Vector Search extension to generate embeddings documentation and documentation for Firestore’s LangChain and LlamaIndex integrations.
Express richer queries
Often applications require the ability to express queries that filter on range conditions across multiple fields. For example, if you run an e-commerce site, an end user might want to filter based on a t-shirt size and price ranges.
With the recent launch of queries using range filters on multiple fields in preview, you can easily and cost-efficiently perform these queries directly in Firestore.
To get started, refer to the multiple range queries documentation.
We’re also introducing Firestore Query Explain in preview to help you troubleshoot your queries. You can run Explain
to retrieve the proposed query plan, or optionally indicate that you’d like to execute the query and analyze the performance, billing and retrieve the actual query results using a special analyze flag:
Here’s the output:
To get started, refer to the Query Explain documentation.
Meeting enterprise needs
One key aspect of enterprise readiness is privacy. Firestore now supports Customer Managed Encryption Keys (CMEK) in preview, which allows you to encrypt data stored at-rest using your own specified encryption key. This is an alternative to Firestore’s default behavior, which generates a Google-managed encryption key to encrypt your data. Your customer-specified key can be stored using the Cloud Key Management service, or you can even use your own external key manager. Get started with the Firestore CMEK documentation.
And to help minimize serving latency and maximize data privacy, you can now deploy Firestore in any available Google Cloud region. You can review a full list of supported Firestore locations and pricing here.
Lastly, you can now retain daily backups using Firestore’s Scheduled Backup feature for up to 98 days, up from seven days. Get started with Firestore Scheduled Backup and Restore today.
Next steps
To learn more about Firestore and the new features launching at Next ‘24, check out the following resources:
-
Getting Started on Firestore: server client library or web & mobile client library
-
Firestore Vector Search extension to automatically generate embeddings documentation
-
Firestore Gen AI Library Integrations: LangChain and LlamaIndex