reubano / pygogo

A Python logging library with superpowers
MIT License
281 stars 20 forks source link

Loggly support? #11

Closed pankaj22 closed 6 years ago

pankaj22 commented 6 years ago

Does this library have loggly (https://www.loggly.com/) support ?

reubano commented 6 years ago

Based on their config example and the gogo custom handler example, you should be able to do something like this:

from loggly.handlers import HTTPSHandler
import pygogo as gogo

hdlr = HTTPSHandler('https://logs-01.loggly.com/inputs/TOKEN/tag/python')
logger = gogo.Gogo('myLogger', low_hdlr=hdlr).get_logger()
logger.info('Test log')
reubano commented 6 years ago

I'll assume my previous comment was sufficient. Feel free to reopen if it wasn't.