google-app-engine

Guide to use Restlet Swagger extension for GAE

你。 提交于 2020-01-17 04:23:08
问题 I tried to do a similar approach: public Restlet createInboundRoot() { Router apiRouter = createApiRouter(); attachSwaggerSpecificationRestlet(apiRouter, "/api-docs"); return apiRouter; } When /api-docs is access Restlet throws Error 404, what could be messing. The idea is that the apiRouter we have is fully working at this state, when we acess resource like /stuff etc. What could be missing in this code? Or is there any specific notes to take into consideration when using Restlet Swagger

Google App Engine and Human API python lib

断了今生、忘了曾经 提交于 2020-01-17 04:12:33
问题 I am trying to use the Human Api Python client with GAE. I created a appengine_config.py and followed all instructions as described in Third-party Libraries in Python 2.7 documentation for GAE My appengine_config.py looks like: """This file is loaded when starting a new application instance.""" from google.appengine.ext import vendor # Add any libraries installed in the "lib" folder. vendor.add('lib') My requirements.txt looks like so: HumanAPI ... and installs correctly: Downloading

Cant Run Google appengine python app on eclipse although launcher works fine

╄→尐↘猪︶ㄣ 提交于 2020-01-17 02:19:09
问题 I'm following this tutorial: http://www.mkyong.com/google-app-engine/google-app-engine-python-hello-world-example-using-eclipse/ I created a project and tried to run it locally. It didn't work but when I ran it on the Google appengine launcher it worked just fine. I noticed that eclipse doesn't create .project and .pydevproject files in the project here is the console contents: WARNING 2012-11-28 07:48:10,265 rdbms_mysqldb.py:74] The rdbms API is not available because the MySQLdb library

App Engine Java - Extract thumbnail from mp4 video

孤者浪人 提交于 2020-01-16 19:43:11
问题 I have some video stored on Google Cloud Storage in mp4, i need the extract a thumbnail from them. I looked to a number of solutions, and looks like they don't work with App Engine. for example: http://www.xuggle.com/xuggler/ Do you have library that i could use to do this on Google App Engine in Java? 回答1: I finally went with Google Compute Engine and ffmpeg, implementation is in progress... 回答2: This question looks related to Is there a Java API for mp4 files? Xuggler says their project is

Socket API will be enabled once billing is enabled

て烟熏妆下的殇ゞ 提交于 2020-01-16 19:13:39
问题 Can anyone let me know why I am getting this message in my login screen. "The socket API will be enabled for this application once billing has been enabled in the admin console". I am building a GWT app and using Parse.com's REST API. I cannot make out why I am getting this error. 回答1: To use sockets in GAE, you need to enable billing. You have two options: Find where you use sockets and don't use them Enable billing. You need a credit card, but the default daily limit is $0.00. You will

Why properties referenced in an equality (EQUAL) or membership (IN) filter cannot be projected?

a 夏天 提交于 2020-01-16 18:52:09
问题 https://developers.google.com/appengine/docs/java/datastore/projectionqueries Why a projected query such as this : SELECT A FROM kind WHERE A = 1 not supported ? 回答1: Because it makes no sense. You are asking SELECT A FROM kind WHERE A = 1 so, give me A where A = 1 . Well, you already know that A = 1 . It makes no sense for DB to allow that. The IN query is internally just a series of equals queries merged together, so the same logic applies to it. 回答2: The reasoning behind this could be that

NoClassDefFoundError: com/google/api/client/extensions/appengine/http/UrlFetchTransport?

坚强是说给别人听的谎言 提交于 2020-01-16 18:40:33
问题 I have a web service on google app engine and I am trying to read a file from the google cloud store from the web service. This is the code I am using: public static byte[] readFile2(String bucket, String filepath) throws IOException { GcsService gcsService = GcsServiceFactory.createGcsService(RetryParams.getDefaultInstance()); GcsFilename fileName = new GcsFilename(bucket, filepath); logger.warning(fileName.toString() + "<br>"); logger.warning(String.format("/gs/%s/%s", fileName

Putting models in a callback function from ctypes library

自作多情 提交于 2020-01-16 18:34:28
问题 I am trying to setup an application based on the Google App Engine using the Managed VM feature. I am using a shared library written in C++ using ctypes cdll.LoadLibrary('./mylib.so') which registers a callback function CB_FUNC_TYPE = CFUNCTYPE(None, eSubscriptionType) cbFuncType = CB_FUNC_TYPE(scrptCallbackHandler) in which i want to save data to the ndb datastore def scrptCallbackHandler(arg): model = Model(name=str(arg.data)) model.put() I am registering a callback function in which i want

ndb.OR makes query costs more

自古美人都是妖i 提交于 2020-01-16 17:58:25
问题 Using AppEngine appstats I profiled my queries, and noticed that although the docs say a query costs one read, queries using ndb.OR (or .IN which expands to OR), cost n reads (n equals the number of OR clauses). eg: votes = (Vote.query(ndb.OR(Vote.object == keys[0], Vote.object == keys[1])) .filter(Vote.user_id == user_id) .fetch(keys_only=True)) This query costs 2 reads (it matches 0 entities). If I replace the ndb.OR with Vote.object.IN, the number of reads equals the length of array I pass

Can't import the ctypes python library in Google App Engine

[亡魂溺海] 提交于 2020-01-16 14:06:14
问题 I can't import ctypes on the production GAE server, which is causing our code to break. Seemingly, urllib and urllib2 also rely on this library, but somehow it's possible to import them on production through the console (e.g. navigate to www.myapp.com/console). Is this a feature or a bug? Thanks! Python 2.5.2 (r252:60911, Mar 17 2011, 15:16:30) [GCC 4.3.1] on linux2 Type "help", "copyright", "credits" or "license" for more information. (Google App Engine/1.5.1) >>> from lib import cloud