Re: Output bufferring
"James K. Lowden" <[email protected]>
| Newsgroups | gmane.comp.db.tds.freetds |
|---|---|
| Message-ID | <[email protected]> |
On Thu, 14 Apr 2016 09:18:34 +0200 <[email protected]> wrote: > We have tried tracing on several levels and we have found that in > FreeTDS trace log messages are written at every itteration. However > in UnixODBC trace messages are shown when procedure finishes. > > [...] Is freeTDS bufferring messages on it's output (but after > tracing log is written), or are these messages buffered in the > UnixODBC? If you look at the FreeTDS logging function, you'll see it opens and closes the logfile each time a message is written. That ensures each message is flushed to the disk, but it's very expensive in terms of performance. You don't want to use TDSDUMP in production. From your description, it sounds like you're using log message to monitor your application's data status. If so, I would counsel you that that's a mistake. Better at the application level to capture the statistics you need and flush them under application control (or, you know, insert them in a table). Then you don't have to worry about the vagaries of ODBC log buffering. HTH. --jkl