Just curious: why not just put granular timestamps on the messages?
Wouldn't that have been simpler?


On Thu, Apr 3, 2014 at 5:37 PM, Bernd Oppolzer
<[email protected]>wrote:

> The problem is that the physical writes to the output streams
> are deferred, and you don't have full control about the flushing of
> the buffers, at least it does not work in the way we expect it.
> This is no problem of the legacy data sets; it's only a problem of
> the two RTLs, both writing to SYSPRINT (for example) and both
> doing their own buffering. When we moved all the C printf work
> to PL/1-PUT in the past (by our own printf replacement), all worked
> well, of course.
>
> The problem is not that important; we separated the trace output
> to different DD-Names (PL/1: DRTRACE, C: CEEMSGS), and
> we don't need to correlate the trace output ... in fact, there are not that
> many calls when we cross borders (PL/1 to C and back), but large
> time frames, when we stay within one language ("normal" business
> logic in PL/1, insurance math service routines in C).
>
> Other important features: the trace output can dynamically be activated
> from outside (job control) on a per module base; different trace levels
> are supported. No recompile needed. Activating traces is possible
> even in production environment. This turned out to be very important
> and helpful in error diagnosis.
>
> Kind regards
>
> Bernd
>
>
>
> Am 03.04.2014 23:21, schrieb Paul Gilmartin:
>
>  On Thu, 3 Apr 2014 23:05:28 +0200, Bernd Oppolzer wrote:
>>
>>> But: we still have the problem, that the trace output from PL/1-PUT
>>> and C printf are not in sync ... that is: due to different buffering in
>>> the PL/1 and C RTL, the trace output does not appear in the correct time
>>> order.
>>>
>>>  Don't know about legacy data sets; don't know about PL/[1I], but if I
>> use UNIX files and sprintf(); write(); I expect more orderly results.
>>
>> fflush(); might also help.
>>
>> setvbuf( stream, NULL, _IOLBF, ... ); might likewise help.
>>
>> -- gil
>>
>> ----------------------------------------------------------------------
>> For IBM-MAIN subscribe / signoff / archive access instructions,
>> send email to [email protected] with the message: INFO IBM-MAIN
>>
>>
> ----------------------------------------------------------------------
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to [email protected] with the message: INFO IBM-MAIN
>



-- 
zMan -- "I've got a mainframe and I'm not afraid to use it"

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to