<< | Index | >>
I could fix error of yesterday.
Tha problem is that my Session class was not called.
If you use SBSM gem, make sure definitions of following constants in app file (like a oddbapp.rb
).
We can load view in our Session class by these value.
z.B.
This is the most tiny app file src/util/shoeapp.rb
(like a oddbapp.rb)
require 'sbsm/drbserver' require 'sbsm/index' require 'util/shoeconfig' require 'util/session' require 'util/validator' require 'fileutils' module SHOE class App < SBSM::DRbServer SESSION = Session VALIDATOR = Validator def initialize opts={} start = Time.now puts "init system" puts "init system: #{Time.now - start}" puts "setup drb-delegation" # pending puts "system initialized" puts "initialized: #{Time.now - start}" super() end end end
SBSM needs following class in application.
In mock, Session class has follownig values specified by Validator.
@valid_input
@active_state
http://example.com/(lang)/(flavor)/(event)
http://example.com/de/test/hallo
@validator = {:default_flavor=>"gcc", :language=>"de", :flavor=>"test", :event=>:hello} @active_state = #<SHOE::State::Greet::Hello:0xa184638>
http://example.com/de/test/goodbye
@validator = {:default_flavor=>"gcc", :language=>"de", :flavor=>"test", :event=>:goodbye} @active_state = #<SHOE::State::Greet::Hello:0xa047540>
We can freely, setup view files.
HtmlGrid has Composite class as main feature.
z.B.
in /path/to/project/src
I have yet another problem im my mock application.
Once, connect to mock via browser (It works),
After few minutes later of previous connection, bind(2) Error
of DRuby caused via Apache.
It seems that few connection from Apache to DRbServer remains.
[Tue Feb 28 18:38:48 2012] [error] mod_ruby: error in ruby [Tue Feb 28 18:38:48 2012] [error] mod_ruby: /usr/local/lib/ruby/1.9.1/drb/drb.rb:861:in `initialize': Address already in use - bind(2) (Errno::EADDRINUSE) [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /usr/local/lib/ruby/1.9.1/drb/drb.rb:861:in `open' [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /usr/local/lib/ruby/1.9.1/drb/drb.rb:861:in `open_server' [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /usr/local/lib/ruby/1.9.1/drb/drb.rb:759:in `block in open_server' [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /usr/local/lib/ruby/1.9.1/drb/drb.rb:757:in `each' [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /usr/local/lib/ruby/1.9.1/drb/drb.rb:757:in `open_server' [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /usr/local/lib/ruby/1.9.1/drb/drb.rb:1342:in `initialize' [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /usr/local/lib/ruby/1.9.1/drb/drb.rb:1624:in `new' [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /usr/local/lib/ruby/1.9.1/drb/drb.rb:1624:in `start_service' [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /var/www/shoe/doc/index.rbx:6:in `<top (required)>' [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /usr/local/lib/ruby/1.9.1/apache/ruby-run.rb:53:in `load' [Tue Feb 28 18:38:48 2012] [error] mod_ruby: from /usr/local/lib/ruby/1.9.1/apache/ruby-run.rb:53:in `handler'
to check actions on using ports with lsof -i