apassant
apassant

Reputation: 167

GAE Modules and Google Endpoints

I'm migrating a GAE application to modules, and have issues with the routing for my api module, based on Google Endpoints.

Basically, all my API queries are routed to the default module, while other routing works well

My folder structure is

- /gae
-- dispatch.yaml
-- www/
---- www.yaml
---- [www module files]
-- foo/
---- foo.yaml
---- [foo module files]
-- api/api.yaml
---- api.yaml
---- [foo module files]

dispatch.yaml

application: testapp

dispatch:
  - url: "testapp.appspot.com/"
    module: default
  - url: "*/_ah/spi/*"
    module: api
  - url: "*/_ah/api/*"
    module: api
  - url: "*/foo/*"
    module: foomodule        

I'm deploying with

cd gae
appcfg.py update www/www.yaml upload/upload.yaml api/api.yaml
appcfg.py update_dispatch .

I can see 3 instances (one per module) being deployed.

But then:

From the logs I also see that:

Is there anything that I'm doing wrong? Any special routing needed for Google Endpoints when they're used as modules?

Upvotes: 1

Views: 574

Answers (1)

Kristian Damian
Kristian Damian

Reputation: 1356

As i see the API is the default module, in the docs say "the default module must be uploaded first" also you need put the parameter "module: default" in the yaml file or not included at all Try

appcfg.py update  api/api.yaml www/www.yaml upload/upload.yaml #api first
appcfg.py update_dispatch

Upvotes: 1

Related Questions