This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| in dev_appserver: | |
| => Booting DevAppServer | |
| => Press Ctrl-C to shutdown server | |
| => Generating configuration files | |
| Warning: The Mac OS -XstartOnFirstThread: is currently unsupported | |
| Bad level value for property: .level | |
| Apr 6, 2010 7:31:38 AM com.google.apphosting.utils.jetty.JettyLogger info | |
| INFO: jetty-6.1.x |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require "open-uri" | |
| require "thread" | |
| require "monitor" | |
| $stdout.sync = true | |
| class GaeWarm2 | |
| def initialize | |
| @monitor = Monitor.new |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module AppEngine | |
| module Datastore | |
| class << self | |
| alias convert_exceptions_ORIG convert_exceptions | |
| def convert_exceptions | |
| begin | |
| convert_exceptions_ORIG do | |
| yield | |
| end | |
| rescue com.google.apphosting.api.ApiProxy::ApplicationException => ex |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # add to config/environments/production.rb or development.rb | |
| require "appengine_mem_cache_store.rb" | |
| config.cache_store = AppEngine::Memcache::RailsStore.new(:namespace=>"cache_store") | |
| config.action_controller.perform_caching = true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ServletFilter | |
| initial Status=1. | |
| default app_ttl=2 | |
| default ttl=5 or 10 or ? | |
| [Status=1]: Java loaded(only 1sec.). Need to load JRuby. | |
| - "App request" AND "Status=1 less than 1 minute" | |
| - async-kick_url(ttl=5?) | |
| - async-kick_url(ttl=5?) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| tkrmb:~/tmp/gae_jruby_20100420_015717% VERBOSE=1 LANG=C appcfg.rb run -S irb | |
| "java" "-Dfile.encoding=UTF-8" "-cp" "/Users/takeru/tmp/gae_jruby_20100420_015717/WEB-INF/lib/appengine-api-1.0-sdk-1.3.2.jar:/Users/takeru/tmp/gae_jruby_20100420_015717/WEB-INF/lib/appengine-api-labs-1.3.2.jar:/Users/takeru/tmp/gae_jruby_20100420_015717/WEB-INF/lib/appengine-jruby-0.0.7.pre.jar:/Users/takeru/tmp/gae_jruby_20100420_015717/WEB-INF/lib/gems.jar:/Users/takeru/tmp/gae_jruby_20100420_015717/WEB-INF/lib/jruby-rack-0.9.7.jar:/opt/local/lib/ruby/gems/1.8/gems/appengine-sdk-1.3.2/appengine-java-sdk-1.3.2/lib/shared/appengine-local-runtime-shared.jar:/opt/local/lib/ruby/gems/1.8/gems/appengine-sdk-1.3.2/appengine-java-sdk-1.3.2/lib/impl/appengine-api-stubs.jar:/opt/local/lib/ruby/gems/1.8/gems/appengine-sdk-1.3.2/appengine-java-sdk-1.3.2/lib/impl/appengine-local-runtime.jar:/opt/local/lib/ruby/gems/1.8/gems/appengine-sdk-1.3.2/appengine-java-sdk-1.3.2/lib/testing/appengine-testing.jar" "org.jruby.Main" "-rappengine_boot" "-S" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def each(opts={}) #todo(tx=nil) | |
| TinyDS::LowDS.retry_if_timeout do | |
| index = 0 | |
| @q.each(opts.dup) do |entity| # <= HERE | |
| if opts[:limit] && opts[:limit]<=index | |
| TinyDS::Base.logger.warn "too_many_results: each limit=#{opts[:limit]} index=#{index}" | |
| break | |
| end | |
| index += 1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # ADD support "req.body" for appengine-apis. | |
| # http://www.ruby-lang.org/ja/man/html/Net_HTTPRequest.html | |
| ####################################### | |
| ## webserver.rb | |
| require 'webrick' | |
| s = WEBrick::HTTPServer.new( | |
| :BindAddress => '127.0.0.1', | |
| :Port => 18080, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'appengine-rack' | |
| AppEngine::Rack.configure_app( | |
| :application => "rack20100430-023242", | |
| :precompilation_enabled => true, | |
| :version => "1") | |
| #ENV['RACK_ENV'] = AppEngine::Rack.environment | |
| if true | |
| s = File.lstat("/Users") ## <<<<<<<<<<<<<<<<<<<<<< SUCCESS | |
| p ["A:", s] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git a/examples/basic/Gemfile b/examples/basic/Gemfile | |
| index 3e9fbe9..16c32f0 100644 | |
| --- a/examples/basic/Gemfile | |
| +++ b/examples/basic/Gemfile | |
| @@ -5,6 +5,6 @@ bundle_path ".gems/bundler_gems" | |
| # List gems to bundle here: | |
| gem 'appengine-rack', '0.0.7' | |
| -gem 'appengine-apis', '0.0.14' | |
| +gem 'appengine-apis', '0.0.15' |