[squeak-dev] when safe to set maxExternalSemaphores:? What value?
eliot.miranda at gmail.com
Fri May 21 04:27:24 UTC 2021
> On May 20, 2021, at 8:46 PM, Chris Muller <ma.chris.m at gmail.com> wrote:
> Hi, the comment in maxExternalSemaphores: says:
> "Setting this at any time other than start-up can potentially lose requests.
> i.e. during the realloc new storage is allocated,
> the old contents are copied and then pointers are switched.
> Requests occurring during copying won't be seen if they occur to indices already copied.
> The intended use is to set the table to some adequate maximum at start-up"
> I could use some help in translating this to my limited user-level comprehension. Does "start-up" here refer to the #startUp: hook?
Yes Before the image starts listening for events.
> Could "requests won't be seen" result in an image crash, or simply a few lost InputEvents? If a crash is possible, I might be nervous to risk messing with it at all even in #startUp: in case it happened to be too low in the list, for example, and my image became unstartable..
Simply lost input events. And lost input events include e.g. notifications of readable socket data, etc.
> Any guidance on what these external semaphores are for (at a high level) and a good suggested value for a chatty TCP/IP server would be greatly appreciated.
They are used in the Semaphore implementation. You’re probably using them already.
More information about the Squeak-dev