Xen wrote:
There is a different between writing your own logs without any kind of functionality, and writing your own logs when an API for that is already present as part of existing libraries.
Not much of a difference, I submit. Whether you use your own write2log() call or that of an existing library does not make a real difference, except in the packaging (if you plan to distribute your code).
I did not compare two equivalent modes of functionality.
I compared one mode of functionality that is meagre, because you need to write it yourself for your application yourself. The other one is rich, because other people have written it with the idea of being used by a lot of people.
Right.
The difference is they call him king, the difference frightens me.
What I mean is very simple, and you already know the answer.
- Anything you write yourself you will have to write from scratch if you cannot reuse someone else's code.
- This will take a lot of energy and is less efficient than reusing existing code if you agree with that code.
In principle this is absolutely true, in practice for a write2log() call, less so. Unless that call was part of a framework I wanted to use in my application anyway, I would not bother. It would take me less time to write my own than to learn how to use a foreign one.
You DO understand why libraries exist in the first place right? So not everyone has to constantly reinvent the wheel. I mean are you just purposefully being thick here? I mean pretending not to understand so you won't have to reach a certain conclusion? So no, the difference is not packaging, the difference is effort required to reach a certain level of functionality. That's WHY you use existing libraries.
Would you like to be a little less condescending?
Now if those libraries don't exist, you have a problem. A certain feature in the system ecosystem is missing.
If they don't exist, you have no option but to write them yourself. I don't see a problem here.
And if existing syslogd and logrotate do not fit your purposes, then what?
1) invent your own wheel or, 2) change your purpose to suit the wheels at hand
Are there situations where a programmer could /use/ application-level logging functionality instead of system-wide features? Definitely. Why not?
That what I keep saying. It's called write(). see "man 2 write". -- Per Jessen, Zürich (8.9°C) http://www.hostsuisse.com/ - virtual servers, made in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org