Sha256: 06d58dc1523e65250e9f9d78d44b7be6cf632c673d44ff6d6df29eb02a01b28b

Contents?: true

Size: 818 Bytes

Versions: 4

Compression:

Stored size: 818 Bytes

Contents

module Le
  module Host

#!    def self.new(token, local, debug, ssl, datahub_enabled, datahub_ip, datahub_port, host_id, host_name_enabled, host_name)
    def self.new(token, local, debug, ssl, datahub_endpoint, host_id, custom_host, udp_port)

      Le::Host::HTTP.new(token, local, debug, ssl, datahub_endpoint, host_id, custom_host, udp_port)
    end

    module InstanceMethods
      def formatter
        proc do |severity, datetime, _, msg|
          message = "#{datetime} "
          message << format_message(msg, severity)
        end
      end

      def format_message(message_in, severity)
        message_in = message_in.inspect unless message_in.is_a?(String)

        "severity=#{severity}, #{message_in.lstrip}"
      end
    end

  end
end

require File.join(File.dirname(__FILE__), 'host', 'http')

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
le-2.7.0 lib/le/host.rb
le-2.6.2 lib/le/host.rb
le-2.6.1 lib/le/host.rb
le-2.6.0 lib/le/host.rb