App Engine Flashcards
What are some of the handy built in features GAE provides?
- Turn-key support for many languages
- Built-in scaling system
- Easy deployment of apps via GIT
What command do you need to run to create a new project on GAE?
gcloud app create –project=
What command do you need to run to install Python on GAE?
gcloud components install app-engine-python
What are the files needed to make an app on GAE?
- app.yaml
- requirements.txt
- main.py
What is for app.yaml file for?
General configuration file for the application
What is for requirements.txt file for?
Specifies modules/libraries to install in the environment
What is for main.py file for?
The backend application code
What command do you need to deploy your app on GAE?
gcloud app deploy
What command do you need to open your app on a new browser?
gcloud app browse
What happens to instances when your app is idle?
They get spun down
What are the ways we can implement a DB as part of our app?
- Use a file-based DB (SQLite)
- Use Datastore
- Use Google Cloud Storage
What are the cons of using a file-based DB such as SQLite
Not persistent
Every new instance starts back a 0
Why might you use a file-based DB such as SQLite
If youre working with static non changing content
What is Google Datastore?
A NoSQL Database
Deals with keys & values instead of tables & rows
What are the steps to use google datastore?
- Import it
from google.cloud import datastore - Create new Client object
datastore_client = datastore.Client()
3. Add module to requirements.txt google-cloud-datastore==2.1.6