Bug 51324

GemStone/S 64 Bit

3.7.2, 3.7.1, 3.7, 3.6.8, 3.6.7, 3.6.6, 3.6.5, 3.6.4, 3.6.3, 3.6.2, 3.6.1, 3.6, 3.5.8, 3.5.7, 3.5.6, 3.5.5, 3.5.4, 3.5.3, 3.5.2, 3.5.1, 3.5, earlier versions

System class >> processKindForSlot: can return zero, breaking System class cacheStatisticsDescriptionAt:

There is a very small window during the period where a session is logging in, for which System class >> processKindForSlot: for the new session's slot (invoked by another session) may return 0.

The method System class >> cacheStatisticsDescriptionAt: expects a non-zero result, and gets a primitive error.

Workaround

To patch cacheStatisticsDescriptionAt:, file in the following as SystemUser

cacheStatisticsDescriptionAt: aSlot

"Returns an array of strings which describe the cache statistics for the
 kind using the cache slot with index anInt.  Returns an empty array if
 the slot is not in use."

| kind |
kind := self processKindForSlot: aSlot .
^kind < 1
    ifTrue:[ Array new ]
    ifFalse:[ self cacheStatisticsDescriptionForType: kind ]

Last updated: 2/13/25