Answer the question
In order to leave comments, you need to log in
Checking with a log entry, where to store the log in the database or in a file?
I'm learning not to throw rotten tomatoes! )
Task - you need to send a request to the API once every 5 minutes, get a response and add a line to the log log
. I tried to log in a file, but noticed that the load on the processor had risen.
Question - if you transfer the storage of logs to the database, will this reduce the load? And if so, what type of cell is best to use?
Thank you!
Answer the question
In order to leave comments, you need to log in
Sequential logging of logs to regular files is the most minimally loading system entry.
If you don't, look for the problem.
With a DB - there will be more loading in the general case.
Do like this:
See the principles of ELK operation.
If the load is small, then you can immediately go to the database.
But, based on the fact that even simple writing to files slows you down - I would not go into the database.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question