Google Cloud Functions is the second most popular serverless execution platform.
Similar to AWS Lambda it is stateless, namely you need to access external
resources to read or write your applications state. In this post, we will
introduce Redis as a database for your Google Cloud functions.This tutorial shows how to build a serverless API with Redis on Google Cloud
Functions. The API will simply count the page views and show it in JSON format.See the demo: https://us-central1-functions-317005.cloudfunctions.net/helloGETSee the code:
https://github.com/upstash/examples/tree/master/examples/using-google-cloud-functions
Create a Redis database from Upstash console. Select the GCP US-Central-1 as
the region. Free tier should be enough. It is pretty straight forward but if
you need help, check getting started guide. In the
database details page, click the Connect button. You will need the endpoint and
password in the next step.