Question Lucas Galdino · Oct 26, 2023

doubt about CACHE.WIJ behavior

I'm dealing with a situation that leaves in doubt what I understand about CACHE.WIJ (C:\Roche\CobasInfinity\HealthShare\mgr).. 
Journal files store records already written to the base.. and CACHE.WIJ records not yet written to the base..
theoretically, the data contained in CACHE.WIJ is temporary... until the record is written to the base (consequently generating journal).
The question arose because I have a .WIJ file from 03/10/2023 (modification date) with approx. 4GB.. theoretically the WIJ does not should it be written/modified every day? because the system is in full use, with continuous transactions.

Thank you

Product version: Caché 2018.1

Comments

Robert Cemper · Oct 26, 2023

Simplified:
WIJ is the on-disk image of your modified buffers.
If buffers are changed they get updated on-disk by an asynchronous background process.
The modified date is typically the last modification at file close.
writing modification date at every file update as you expect will break every file system.

Transposing your expectation to a text editor would mean to update the file and date at every new line:
I suppose you would be disappointed by the related performance reduction.
Though, from personal experience, this seems to be the standard operating style of almost every government.😉

0
Yaron Munz  Oct 26, 2023 to Robert Cemper

Robert, 

WIJ is used to write data to the Db. WIJ holds the copy of Db blocks before they are written to the Db to allow to keep Db integrity (Cache checks if there are "dirty" blocks on WIJ when started, if so writtes them to the Dbs).

"cache buffers" are used to store blocks that were READ from the Db to aviod disk access for concurrent reads

0
Alexander Pettitt · Oct 26, 2023

I would expect the WIJ to close to force it to the disk about every 80 seconds ie every write cycle.

my quick testing:

$while true; do
> ls -l IRIS.WIJ | cut -f 10-13 -d ' '
> sleep 40
> done
Oct 2612:26 IRIS.WIJ
Oct 2612:27 IRIS.WIJ
Oct 2612:27 IRIS.WIJ
Oct 2612:28 IRIS.WIJ
Oct 2612:28 IRIS.WIJ
Oct 2612:30 IRIS.WIJ
Oct 2612:30 IRIS.WIJ
Oct 2612:31 IRIS.WIJ
Oct 2612:31 IRIS.WIJ
Oct 2612:32 IRIS.WIJ
Oct 2612:32 IRIS.WIJ
Oct 2612:34 IRIS.WIJ
Oct 2612:34 IRIS.WIJ
Oct 2612:35 IRIS.WIJ
Oct 2612:35 IRIS.WIJ
Oct 2612:36 IRIS.WIJ

0