Git Product home page Git Product logo

talisker's Introduction

Talisker - an opinionated WSGI app platform

image

image

Documentation Status

Talisker is a runtime for your wsgi app that aims to provide a common platform for your python services.

tl;dr

Simply run your wsgi app with talisker as if it was gunicorn.:

talisker app:wsgi -c config.py ...

Talisker will wrap your app in a some simple WSGI middleware, and configure logging to output structured logging like so:

logger = logging.getLogger('app')
logger.info('something happened', extra={'context': 'I haz it'})

will output:

2016-01-13 10:24:07.357Z INFO app "something happened" svc.context="I haz it" request_id=...

It also exposes some status endpoints you can use, go to the /_status/ url on your app to see them.

This all works out of the box by using the talisker runner instead of gunicorns, and there are many more features you can use too.

Elevator Pitch

Talisker is based on a number of standard python tools:

  • stdlib logging for logs
  • gunicorn for a wsgi runner
  • requests for http requests
  • statsd for metrics
  • raven for errors
  • werkzeug for thread locals and wsgi utilities

It is designed sepcifically to be used in both development and production, and aims to provide a default set of features out of the box:

  • standard log format, including ISO/UTC timestamps
  • structured logging with python stdlib
  • improved gunicorn access logs, with ms precision UTC timestamps
  • request id tracing
  • standard set of status endpoints for your app
  • easier statsd endpoint configuration
  • sentry/raven middleware (TODO)

All the above are available by just using the talisker entry point script, rather than gunicorn.

In addition, with a small amount of effort, your app can benefit from additional features:

  • simple deeper nagios checks - just implement a _status/check url in your app
  • per-thread requests connection pool managment (WIP)
  • automatic statsd metrics for outgoing HTTP requests (WIP)
  • more efficient statsd client management (WIP)

Additionally, talisker provides additional tools for integrating with your infrastructure:

  • grok filters for log parsing (WIP)
  • rsyslog templates and config for log shipping (TODO)

Talisker is opinionated, and derived directly from the authors' needs and as such not currently very configurable. However, PR's are very welcome!

For more information, see The Documentation, which should be found at:

https://talisker.readthedocs.io

talisker's People

Contributors

1stvamp avatar bloodearnest avatar facundobatista avatar fgallina avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.