django_socio_grpc.log
logging utils
Module Contents
Functions
This method and the setting associated is deprecated This method is the default used for the grpc_settings: LOG_EXTRA_CONTEXT_FUNCTION. It allow logs to have extra data about the current context of the log. Used especially for tracing system. |
|
This method and the setting associated is deprecated This method is not used by default. You juste have to execute it in your app code. Preferentially at some entrypoint. It will allow to inject the default extra context of each service in the log record if needed. If this method is call before any log you can use grpc_service_name, grpc_action, grpc_user_pk in your log formatter |
API
- django_socio_grpc.log.default_get_log_extra_context(service: django_socio_grpc.generics.GenericService)
This method and the setting associated is deprecated This method is the default used for the grpc_settings: LOG_EXTRA_CONTEXT_FUNCTION. It allow logs to have extra data about the current context of the log. Used especially for tracing system.
- django_socio_grpc.log.set_log_record_factory()
This method and the setting associated is deprecated This method is not used by default. You juste have to execute it in your app code. Preferentially at some entrypoint. It will allow to inject the default extra context of each service in the log record if needed. If this method is call before any log you can use grpc_service_name, grpc_action, grpc_user_pk in your log formatter