logentries: Request logger middleware for Logentries

[ bsd3, library, web ] [ Propose Tags ]

Wai Middleware request logger for Logentries


[Skip to Readme]

Modules

  • Network
    • Wai
      • Middleware
        • RequestLogger
          • Network.Wai.Middleware.RequestLogger.LogEntries

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

  • No Candidates
Versions [RSS] 0.1.0.1
Dependencies base (>=4.7 && <5), bytestring (>=0.10.6.0 && <0.10.7.0), data-default (>=0.5.3 && <0.6.0), fast-logger (>=2.4.6 && <2.5.0), network (>=2.6.2.1 && <2.6.3.0), stm (>=2.4.4.1 && <2.4.5.0), uuid-types (>=1.0.3 && <1.1.0), wai (>=3.2.1.1 && <3.2.2.0), wai-extra (>=3.0.15.1 && <3.0.16.0) [details]
License BSD-3-Clause
Copyright 2016 Todd Mohney
Author Todd Mohney
Maintainer toddmohney@gmail.com
Category Web
Home page https://github.com/toddmohney/logentries#README.md
Source repo head: git clone https://github.com/toddmohney/logentries.git
head: git clone https://github.com/toddmohney/logentries
Uploaded by toddmohney at 2016-07-12T03:31:20Z
Distributions
Reverse Dependencies 1 direct, 0 indirect [details]
Downloads 786 total (4 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs not available [build log]
All reported builds failed as of 2016-11-22 [all 2 reports]

Readme for logentries-0.1.0.1

[back to package description]

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.