Code Monkey home page Code Monkey logo

Comments (7)

rust avatar rust commented on June 16, 2024

このサンプルコードを実行するのに必要な環境作りに難航しているのですが、ExtJSの部分は再現するのに必須ですか?

from jpmobile.

yuuna avatar yuuna commented on June 16, 2024

bundle install
bundle update
rake db:migrate
してたいだいて
./script/rails s
で実行できるとおもいます。

トップにアクセスしてもらうと"index"としますので
"test"をいてもらうとdeviseの認証になるので登録してみてください

するとtestにアクセスできます。

同じのをdocomoのcookie非対応でtrans_sidつきで回すとログイン無限ループになります
よろしくお願いします。

from jpmobile.

rust avatar rust commented on June 16, 2024

今のテスト環境だと、JavaScript runtimeが入っていないので、下記のエラーが出て rails コマンドが実行できません。

Could not find a JavaScript runtime. See https://github.com/sstephenson/execjs for a list of available runtimes.

なので、できれば最小構成で再現できるコードをいただけると助かります。

from jpmobile.

yuuna avatar yuuna commented on June 16, 2024

rails3.1の素でビルドした状態なんですよね……
3.1からJavaScript runtimeが必須になったようなきがしますが
最小構成で再度つくってみます。

from jpmobile.

yuuna avatar yuuna commented on June 16, 2024

一応pushしましたが、ここにかいてあるのをしただけです。

http://stackoverflow.com/questions/5955004/ruby-on-rails-3-1-without-execjs

from jpmobile.

rust avatar rust commented on June 16, 2024

Node.jsとmemcachedをインストールして再現できることを確認したのですが、
jpmobileではいまのところActiveRecordStoreのみでMemCacheStoreに対応していません。
ActiveRecordStoreに変更してみたところ、ループせずに動作しました。

対応予定はありますが、すぐには対応できないので、
いまのところはActiveRecordStoreを使うようにしてください。

from jpmobile.

yuuna avatar yuuna commented on June 16, 2024

MemCacheStoreに対応してないとは申し訳ありません。。。
複数の別案件のそれぞれのチームから同時にきてみんなで頭抱えていました。

メンバーが動作するpatchつくったので参考までにはっておきます。

class Rack::Session::Memcache
 def destroy_session(env, session_id, options)
   with_lock(env) do
     @pool.delete(session_id)
     generate_sid unless options[:drop]
   end

   session_id || generate_sid
 end
end

class ActionDispatch::Session::MemCacheStore
 def extract_session_id(env)
   request = ::Rack::Request.new(env)
   if request.params[@key] and !@cookie_only
     sid = request.params[@key]
   end

   sid ||= request.cookies[@key]
   sid
 end
end

initializerで対応できます。。
参考までにはっておきます。

from jpmobile.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.