I looked online at the documentation, but didn't see any mention of a REST API for search in Google App Engine's standard environment. The reason I ask is that I would like to migrate off of the standard environment into the flexible environment, but the GAE Search API is not offered there in Python (or any other language) AFAIK. Thus asking if there is a REST API available.
There is at this time no REST API for Google App Engine's Search API, it is only available for Java, Python and Go in the standard environment.
What you can do is separate the part of your application that calls the search API from the rest of your application and deploy it as a separate service that runs on the Standard environment, while the rest of your application is deployed as one or many services in the Flexible environment.
If that's what you want to do, you can get started by reading about Microservices Architecture on Google App Engine and when to use the flexible environment.
Related
When writing a Go App Engine Standard app, it used to be the case that you had to use the App Engine SDK to access the data store. However, these days (since Go 1.11?), it seems to work if you just use the Cloud Datastore Client Library.
Is there a downside of using the Cloud Datastore Client Library on App Engine Standard for accessing the datastore? (apart from a bit of extra configuration to make the dev appserver use the emulator). The advantage is that it enables code reuse for other environments.
App Engine Standard for Go1.11 runs on the new, second generation (beta) runtime which doesn't have the limitations of the 1st generation and is capable of running any framework, library, or binary. On the other hand, App Engine no longer modifies the Go toolchain to include the appengine package and it is strongly recommended to use the Google Cloud client library or third party libraries instead of the App Engine-specific APIs.
For more details about this, I recommend to have a look at the doc here about the differences between both generations and how to handle them.
Newbie to Datastore. I found two tutorials on the GCP site to use Datastore on App Engine. Which one should I use?
There are subtle differences in how the APIs work.
https://cloud.google.com/datastore/docs/datastore-api-tutorial
uses package (import com.google.appengine.api.datastore.Entity;)
vs.
https://cloud.google.com/appengine/docs/standard/java/building-app/cloud-datastore
uses package (import com.google.cloud.datastore.Entity)
Question: Is there a preferred package to use and call the datastore API while on App Engine - com.google.cloud.datastore.Entity vs. com.google.appengine.api.datastore.Entity?
The library with this package com.google.appengine.api.datastore (aka "Datastore API for Java") is intended for use by Java 7 and Java 8 applications which run on AppEngine.
The library with this package com.google.cloud.datastore (aka "Cloud Datastore client library") is intended for use by any Java 8 application regardless of where it is deployed (GKE, GCE, on-premises etc)
From the docs:
Datastore API for Java is a low-level Datastore API built into the App Engine SDK to provide direct access to all Datastore features and is described throughout the App Engine Datastore documentation for Java.
Cloud Datastore client library is a library that can be used by apps in the App Engine standard Java 8 runtime, by applications in the App Engine flexible environment, and by non App Engine applications as well.
So, according to Google, both are valid choices subject to these limitations ...
If you are running Java 7 then you cannot use Cloud Datastore client library
If your application is not deployed to AppEngine then you cannot use Datastore API for Java
These limitations describe the scenarios in which one or other of these libraries cannot be used. Google offers no advice on which one should be used. This is because the two libraries are functionally equivalent so, assuming that the limitations described above do not apply to your usage, the choice is probably moot.
Im creating a Node.js website that probably won't have loads of traffic, and was looking into cheap solutions to host the site. Came across Google cloud services offering free usage for their services with limits. A f1-mirco is more than enough for my needs, but I will happily pay for some usage if it goes over by any chance.
I wanted to setup a linux centOS 7 on GCE (which I already did), and run my application and REST API on it. Now here comes the problem.
I tried to use Google's datastore service, but it sprung an app engine instance and without it datastore won't work.
Is datastore entirely relying on app engine to function?? In the docs, it said if you use any of the client API, it requires app engine. What can I do to not use the client api and query data then? Don't want to use the app engine at the moment or datastore is just not for me then?
Thanks for any help!
Some of the underlying infrastructure of Cloud Datastore and App Engine are still tied together for creation, etc. So while creating an Cloud Datastore database also defines an App Engine instance for the project, it doesn't require you to use it. You don't get charged for App Engine either, unless you decide to deploy an App using it.
You should be totally fine use the Google Cloud Node client library on the f1 micro instance.
I have developed an application using Google App Engine's Standard environment in Golang. Now I want to use Google Endpoint to use the same backhand for developing Android and IOS app. However, it seeps google do not support endpoint in golang standard environment.
Is there a work around for this without actually getting into Flexi environment? I am afraid that if I have to move into Flexi Environment then I had to rewrite lot of code.
https://cloud.google.com/endpoints/docs/quickstarts-app-engine-standard
I'm using GWT to create a simply app that allows teachers to create easily their own lessons.
The App is going to be on Google App Engine but I want to store lessons in user's Google Docs space .
Is it possible?
As far as I know gwt transforms java into javascript but google docs api is java, do i have to upload the java library to de app engine storage?
any place to start? any advice?
Thanks...
You need server side proxy for GWT client.
Your GWT client communicates with the servlet. The servlet is the actual agent using the google docs API.
Please read my explanation at http://h2g2java.blessedgeek.com/2010/05/accessing-google-userservice-from-gwt.html.
It explains how to get a GWT client could communicate with a Java based Google API. It explains that since GWT requires all Java source involved to be available to the GWT compiler, there are cases that you simply cannot get GWT client to do the task directly.
http://h2g2java.blessedgeek.com/2009/08/tablemgr-gae-gwt-gdata-with-rpc.html similarly explains how to combine gae + gwt + google docs, using the proxy approach. The posting is quite old and therefore the web site it points to does not work anymore because I have not updated the gae app with google mandated authentication measures. But it should work on your local machine.
The above subscribes to a webserver flow paradigm.
However, Google APIs are essentially REST APIs, which allows you to access them directly using your javascript or GWT client. So, instead of using the Java docs for Google APIs, you need to read the Google REST API docs.
http://code.google.com/more/, among other whatnots, provides a list of all the Google cloud APIs. To avoid using the webserver-proxy flow paradigm, choose the javascript or REST version of the API docs.
Here is the google docs/data API:
http://code.google.com/apis/gdata/docs/client-libraries.html.
Choose the javascript API:
http://code.google.com/p/gdata-javascript-client/
I advise you to first practice using these APIs by coding in javascript. Then you would get a good grasp of what you need to do in GWT.
You should use the GWT API for authentication prior to accessing the Google REST APIs.
http://code.google.com/p/gwt-oauth2/.
Essentially, you are obtaining an authenticated token which your client could use to access Google's data thro their REST APIs.
FYI, REST APIs are, in plain speak, URLs in a defined specification, where data transmission is by convention mostly in JSON or XML.