@hackage / logentries

Request logger middleware for Logentries

Latest0.1.0.1

About

Metadata

  • Last updated , by toddmohney
  • License BSD-3-Clause
  • Categories Web Development
  • Maintained by: toddmohney@gmail.com

  • Lottery factor: 0

Links

Installation

Readme

logentries

Example Usage

The logEntriesLogger produces a chainable Middleware type which can be used in conjunction with any other Middleware type.

-- The Middleware is chained to Servant's Application
-- Other Middlewares can be attached, as well.
app :: Application
app = requestLogger $ serve api server

-- Configures and creates the LogEntries request logger Middleware
requestLogger :: Middleware
requestLogger =
  let token = fromJust . fromString $ "00000000-0000-0000-0000-000000000000"
      logentriesConfig = Config "data.logentries.com" 80 token
  in logEntriesLogger logentriesConfig
Example Application

A Servant example can be found in the repo.