Skip to main content

A Django Middleware for logging requests and responses accordingly to Zupit Standards

Project description

A Django Middleware for logging requests and responses accordingly to Zupit Standards.

Installation

Install using pip:

pip install django_zupit_logging

Configuration

Add django_zupit_logging to your INSTALLED_APPS setting:

INSTALLED_APPS = [
    ...
    'django_zupit_logging',
]

Add django_zupit_logging.middleware.ZupitLoggingMiddleware to your MIDDLEWARE setting:

MIDDLEWARE = [
    ...
    'django_zupit_logging.middleware.ZupitLoggingMiddleware',
]

Add ZUPIT_LOGGING to your settings.py file:

ZUPIT_LOGGING = {
    "APP_INSIGHTS_CONNECTION_STRING": env("APP_INSIGHTS_CONNECTION_STRING"),
}

Use enable_zupit_logger(LOGGING) to your settings.py file:

from django_zupit_logging.settings import enable_zupit_logger

if env("APP_INSIGHTS_CONNECTION_STRING"):
    enable_zupit_logger(LOGGING)

Usage

The middleware will log requests and responses accordingly to Zupit Standards.

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

django_zupit_logging-0.0.8.tar.gz (6.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

django_zupit_logging-0.0.8-py3-none-any.whl (8.0 kB view details)

Uploaded Python 3

File details

Details for the file django_zupit_logging-0.0.8.tar.gz.

File metadata

  • Download URL: django_zupit_logging-0.0.8.tar.gz
  • Upload date:
  • Size: 6.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.7

File hashes

Hashes for django_zupit_logging-0.0.8.tar.gz
Algorithm Hash digest
SHA256 d4b6ba26b836e25f25d08793577d3a63097af5e7a286120dffe57847449b6b7c
MD5 9195808a7d42e7cd42ac4f8cc2f21e4f
BLAKE2b-256 72b89861ca9d7562bbb2eb6f65be227c7736ed1dca67b6136329e11fc0380a9c

See more details on using hashes here.

File details

Details for the file django_zupit_logging-0.0.8-py3-none-any.whl.

File metadata

File hashes

Hashes for django_zupit_logging-0.0.8-py3-none-any.whl
Algorithm Hash digest
SHA256 7b23b7a970f4ed34418035f45e615547fb3f71e4c94d92e6cd6409f6231babd0
MD5 18f62109f3da7f3e59c5bfc6e4505172
BLAKE2b-256 393106b68c416f040ca2b7fe0cdbf05077a70e547083eee541f402cffec8f4c0

See more details on using hashes here.

Supported by

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