Comments (2)
I just made an update and extracted some logic of the daily setup into a base class that can be reused by new setups.
Check out the current existing implemtations:
Suggestion
I do pass in FileLogger.Event.Data
to the getFileKey
function now, this allows you to decide which file name is the correct one based on this data, it should contain everything you need to make your decision. The base setup will create log files based on the file key like following:
I would do following:
- create your own setup implementation
- derive a key from the class name
- be aware, that the logging implemention in the background will close/open log files whenever the key changes - everthing is done on a backgroud thread, still keep that in mind
I don't know why you really need files for each class, maybe think about using multiple instances of FileLoggers and add some filter to them 'FileLogger(setup, filter = ...)`?
from lumberjack.
Thank you @MFlisar, I managed to create a different log file for the activity responsible with the incoming/outgoing calls and a separate one for the entire app.
I'l close this.
from lumberjack.
Related Issues (17)
- Synthetic stacktrace didn't have enough elements: are you using proguard? HOT 5
- Log messages do not contain full package name HOT 1
- Not Compatible With Timber 5 HOT 4
- How to extend the provided Trees in Kotlin? HOT 1
- File Returned By getAllExistingLogFiles() Does Not Exist HOT 2
- Fails to show notification on api 31+ HOT 1
- Getting parse error when using file logging. HOT 1
- Runtime crash HOT 6
- Could not find com.github.MFlisar:CacheFileProvider:0.2. HOT 4
- Sending log file by email crashes when FileProvider paths are used in application HOT 2
- Use Timber. and L. together HOT 8
- Overlay logger - Advanced filter options HOT 1
- Overlay logger - Open advanced activity HOT 3
- Overlay logger - more layout options HOT 1
- General - improve filter HOT 1
- code line number is repeated HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lumberjack.