This page provides general troubleshooting information and provides links to other pages for additional information.
Errors when deploying the Cloud Endpoints configuration
If you got an error message from the gcloud endpoints services deploy
command, see
Troubleshooting Endpoints configuration deployment
for information on troubleshooting the error.
Errors when deploying your API backend
The deployment of your API and the Extensible Service Proxy (ESP) to a Google Cloud backend is platform dependent. See the following troubleshooting guides for more information:
Response errors
When you send a request to your API and receive an error response, see Troubleshooting response errors for information on troubleshooting the error.
Checking required services
Checking required services
At a minimum, Endpoints and ESP require the following Google services to be enabled:Name | Title |
---|---|
servicemanagement.googleapis.com |
Service Management API |
servicecontrol.googleapis.com |
Service Control API |
In most cases, the gcloud endpoints services deploy
command enables these
required services. However, the gcloud
command completes successfully but
doesn't enable the required services in the following circumstances:
If you used a third-party application such as Terraform, and you don't include these services.
You deployed the Endpoints configuration to an existing Google Cloud project in which these services were explicitly disabled.
Use the following command to confirm that the required services are enabled:
gcloud services list
If you do not see the required services listed, enable them:
gcloud services enable servicemanagement.googleapis.com
gcloud services enable servicecontrol.googleapis.com
Also enable your Endpoints service:
gcloud services enable ENDPOINTS_SERVICE_NAME
To determine the ENDPOINTS_SERVICE_NAME you can either:
After deploying the Endpoints configuration, go to the Endpoints page in the Cloud console. The list of possible ENDPOINTS_SERVICE_NAME are shown under the Service name column.
For OpenAPI, the ENDPOINTS_SERVICE_NAME is what you specified in the
host
field of your OpenAPI spec. For gRPC, the ENDPOINTS_SERVICE_NAME is what you specified in thename
field of your gRPC Endpoints configuration.
For more information about the gcloud
commands, see
gcloud
services.
Checking required permissions
The instance running Extensible Service Proxy requires permissions to call Service Management and ServiceControl.
For ESP deployed on Cloud Run, see Building a new ESPv2 image in Cloud Run tutorial for details.
For ESP deployed on Compute Engine, see Checking required permissions in Compute Engine tutorial for details.
For ESP deployed on GKE, see Checking required permissions in GKE tutorial for details.
Checking debug information
Running the Google Cloud CLI with debug verbosity helps with debugging.
gcloud --verbosity=debug COMMAND
This command makes the Google Cloud CLI print a verbose log of the error. Depending on the command being run, the output can include request and response information from the server.
Enabling a service
You can check whether a service is enabled using gcloud
.
gcloud services list
To display configuration for a particular service, use the following command:
gcloud endpoints services describe SERVICE_NAME
Proxy OAuth fails yet requests pass
Make sure there is an authentication
section that has your OAuth definition in
your gRPC API configuration file. An example configuration file is
available in the
Bookstore sample on GitHub.