Yuli
Yuli

Reputation: 151

How can I run GAE projects separately under one application?

I'm new to web application and Google app engine. I don't understand the relationship between projects and the application. I know that there is one unique application ID, but under the application, there can be a lot of projects.

Now I want to run those projects individually under one application using different folders in URL, like this: http://udacity-cs253.appspot.com/unit2/rot13. It's using different URLs for projects but I don't know how to do that.

I read google's help pages but they didn't help. So can anyone help me with this?

Thank you~

Upvotes: 1

Views: 220

Answers (2)

Dan Holevoet
Dan Holevoet

Reputation: 9183

An application consists of all of the code deployed to App Engine under a single application ID (appid). For a single appid you have shared:

  • datastore contents
  • cron jobs
  • task queues
  • logs
  • project administrators and permissions
  • billing settings and quotas

If you'd like to arrange the code within a single application into logical projects, and are comfortable with sharing the above amongst the projects contained in the same appid, you can feel free to do so.

However, if you'd like to segregate the projects (for instance, if you don't want developers of project A to be able to configure project B), you should create individual appids for each project and manage them separately.

As far as routing of requests to individual projects, aschmid00's answer provides a useful suggestion on how to do this.

Upvotes: 3

aschmid00
aschmid00

Reputation: 7158

lets suppose your app is written in python. you do that in your app.yaml file

if you have 2 applications (unit1 and unit2) in your app folder both do have a main.py and in there you define your WSGI application

in your app.yaml you do like this:

- url: /unit1/.*
  script: unit1.main.application

- url: /unit2/.*
  script: unit2.main.application

all requests with path /unit1/.* will be served by unit1, the /unit2/.* by unit2. the datastore will be shared

Upvotes: 2

Related Questions