Sha256: 4ffa95c283fcf56287fd6065549c5c3e7f7d0a8baaadb7c1c0dfd140d6bc34bf

Contents?: true

Size: 397 Bytes

Versions: 24

Compression:

Stored size: 397 Bytes

Contents

require 'norikra/logger'
include Norikra::Log

require 'norikra/rpc'

class Norikra::RPC::Gatekeeper
  # handler of "GET /" to respond for monitor tools
  def initialize(app)
    @app = app
  end

  def call(env)
    if env["REQUEST_METHOD"] == 'GET' && env["PATH_INFO"] == '/'
      return [ 200, {'Content-Type' => 'text/plain'}, ['Norikra alive!'] ]
    end
    return @app.call(env)
  end
end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
norikra-1.5.1-java lib/norikra/rpc/gatekeeper.rb
norikra-1.5.0-java lib/norikra/rpc/gatekeeper.rb
norikra-1.4.0-java lib/norikra/rpc/gatekeeper.rb
norikra-1.3.1-java lib/norikra/rpc/gatekeeper.rb
norikra-1.3.0-java lib/norikra/rpc/gatekeeper.rb
norikra-1.3.0.beta.1-java lib/norikra/rpc/gatekeeper.rb
norikra-1.2.2-java lib/norikra/rpc/gatekeeper.rb
norikra-1.2.1-java lib/norikra/rpc/gatekeeper.rb
norikra-1.2.0-java lib/norikra/rpc/gatekeeper.rb
norikra-1.1.2-java lib/norikra/rpc/gatekeeper.rb
norikra-1.1.1-java lib/norikra/rpc/gatekeeper.rb
norikra-1.1.0-java lib/norikra/rpc/gatekeeper.rb
norikra-1.0.8-java lib/norikra/rpc/gatekeeper.rb
norikra-1.0.7-java lib/norikra/rpc/gatekeeper.rb
norikra-1.0.6-java lib/norikra/rpc/gatekeeper.rb
norikra-1.0.5-java lib/norikra/rpc/gatekeeper.rb
norikra-1.0.4-java lib/norikra/rpc/gatekeeper.rb
norikra-1.0.3-java lib/norikra/rpc/gatekeeper.rb
norikra-1.0.2-java lib/norikra/rpc/gatekeeper.rb
norikra-1.0.1-java lib/norikra/rpc/gatekeeper.rb