Skip to main content

NewRelic logger with headerless logging api

Project description

NewRelic Logger

Python Logo

A simple project to log data to NewRelic using its headerless logging api along with built-in logging.

The project was intended to send logs to both original monitoring tool and NewRelic

Installing

pip install new-relic-logger

Usage example

import logging
from new_relic_logger import NewRelicLogger

...
logger = NewRelicLogger(
    api_key=<API_KEY_HERE>,
    hostname=<HOST_NAME_HERE>,
    service=<SERVICE>,
    enable_built_in_logging=True,
)

logger.info("Updated User Object!")
...
logger.warning("Primary key for user object is not set yet!")
...
logger.error("Failed to retrive user profile!")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

new_relic_logger-0.3.tar.gz (4.1 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page