Sha256: ea108196088e5d4b66c9bf782bf8afd1ffc00812ac34dacbab31659ed5761672

Contents?: true

Size: 1.05 KB

Versions: 1

Compression:

Stored size: 1.05 KB

Contents

# Only require jars if in the "master" process
unless Kirk.sub_process?
  require "kirk/jetty/servlet-api-2.5"

  %w(util http io continuation server client).each do |mod|
    require "kirk/jetty/jetty-#{mod}-7.4.2.v20110526"
  end
end

module Kirk
  module Jetty
    # Gimme Jetty
    java_import "org.eclipse.jetty.client.HttpClient"
    java_import "org.eclipse.jetty.client.HttpExchange"
    java_import "org.eclipse.jetty.client.ContentExchange"

    java_import "org.eclipse.jetty.io.ByteArrayBuffer"

    java_import "org.eclipse.jetty.server.nio.SelectChannelConnector"
    java_import "org.eclipse.jetty.server.handler.AbstractHandler"
    java_import "org.eclipse.jetty.server.handler.ContextHandler"
    java_import "org.eclipse.jetty.server.handler.ContextHandlerCollection"
    java_import "org.eclipse.jetty.server.Server"

    java_import "org.eclipse.jetty.util.component.LifeCycle"
    java_import "org.eclipse.jetty.util.log.Log"
    java_import "org.eclipse.jetty.util.log.JavaUtilLog"

    Log.set_log Jetty::JavaUtilLog.new unless Kirk.sub_process?
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
kirk-0.2.0.beta.5-java lib/kirk/jetty.rb