I'm using Python3.4 and Falcon1.0.0 and I'm serving my falcon application using apache2. Now, I want to maintain logs in my falcon application.
相关问题
- how to define constructor for Python's new Nam
- streaming md5sum of contents of a large remote tar
- How to get the background from multiple images by
- Django __str__ returned non-string (type NoneType)
- Evil ctypes hack in python
You can use following way, i.e. Store following function in file "logger.py":
So now whenever you want to log anything, just call this function there and log whatever you want to log.
Let take this as the example:
I hope this will help you.
There's nothing specifically built-in from Falcon on that regard. Actually that is what make it different from other frameworks; with Falcon you are free to use any library you wish.
For most of my projects, the standard python module
logging
is good enough.