Sha256: 5f2cdec9ff4966eb5398874ef85491f8ac43c7ff97188d84de4a11f4a556d7bf
Contents?: true
Size: 1.01 KB
Versions: 1
Compression:
Stored size: 1.01 KB
Contents
module Trinidad module Extensions require File.expand_path('../../trinidad-libs/trinidad-hotdeploy-extension.jar', __FILE__) module Hotdeploy VERSION = '0.4.0' end class HotdeployWebAppExtension < WebAppExtension def configure(tomcat, app_context) monitor_file = File.expand_path(monitor(app_context)) delay = @options[:delay] || 1000 listener = org.jruby.trinidad.HotDeployLifecycleListener.new(app_context, monitor_file, delay) app_context.addLifecycleListener(listener) listener end def monitor(app_context) @options[:monitor] ||= begin doc_base = app_context.doc_base doc_base = File.join(doc_base, 'tmp/restart.txt') if !(doc_base =~ /\.war$/) doc_base end end end class HotdeployOptionsExtension < OptionsExtension def configure(parser, default_options) default_options[:extensions] ||= {} default_options[:extensions][:hotdeploy] = [] end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
trinidad_hotdeploy_extension-0.4.0 | lib/trinidad_hotdeploy_extension.rb |