Sha256: 93972c76304e51c4ddb8a6abd93ffa60ac2a3e1e8264cbca2b58561e2bd368f0
Contents?: true
Size: 780 Bytes
Versions: 9
Compression:
Stored size: 780 Bytes
Contents
module JettyRails module Adapters class MerbAdapter < AbstractAdapter def init_params # please refer to goldspike and jruby-rack documentation @merb_params ||= { 'merb.root' => '/', 'merb.environment' => config[:environment] }.merge(base_init_params) end def event_listeners [ Rack::MerbServletContextListener.new, SignalHandler.new ] end class SignalHandler include Java::JavaxServlet::ServletContextListener def contextInitialized(cfg) trap("INT") do puts "\nbye!" java.lang.System.exit(0) end end def contextDestroyed(cfg) end end end end end
Version data entries
9 entries across 9 versions & 3 rubygems