Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 15 Next »

This place is to document the development of the Python POC for Security Logging.

Tentative Plan to develop Python POC

  1. Create a new repository for Python Logging Library
    1. You should create a ticket on LF IT Jira to create a new repository Project Support Services | Help Center (linuxfoundation.org)
  2. Create a Security Logging Python library and commit to an ONAP gerrit repository
    1. https://gerrit.onap.org
  3. Make the it available to install using pip from ONAP’s nexus
    1. I don’t know any working example of using ONAP nexus as a pip index, but for sure LF can also support on that.
    2. I think that this is the Nexus repo Michal refers to: https://nexus3.onap.org/#browse/search/pypi
  4. Integration Team (PTL Michal) will create a version of base Python image with Logging Python Library
  5. DCAE Team (PTL Vijay and Tony Hansen) will provide DCAE Integration Validation


Technical Approach

  • Most fields from Jakarta Best Practice Proposal for Standardized Logging Fields page can be configured using Python logging standard library
    • Some fields are already defined logging — Logging facility for Python — Python 3.10.7 documentation)
    • The rest is to create a proper configuration that could be reused by all projects (the question is if that should be done by some package or kept in one place in wiki or something).
  • Configuration could be a part of the ONAP Python base image and developers can only load it from a file stored on the container, which is explained there (Logging HOWTO — Python 3.10.7 documentation).
  • That would be the easiest part but… we are going to have some custom fields on record so looks like we have to define our own logging (Logging facility for Python — Python 3.10.7 documentation) LogRecord class.
  • So probably the best way is to create a package with that and install it on all base containers, so developers could import it. 

ONAP Related Resources

DCAE Python Base Modules

  • heartbeat
  • pm-service-handler
  • smnptrap


  • No labels