HydraTools and minimal images
Klaus D. Witzel
klaus.witzel at cobss.com
Fri Feb 15 12:11:03 UTC 2008
On Fri, 15 Feb 2008 09:47:54 +0100, Igor Stasenko wrote:
> On 15/02/2008, Klaus D. Witzel wrote:
>> On Thu, 14 Feb 2008 22:52:41 +0100, Igor Stasenko wrote:
...
>> > Of course, a bidirectional protocol will look as much as close to
>> > sockets :)
>>
>> NB, some fruits with HydraSMS and its same-method principle, a #doit
>> from
>> a workspace, just out of the blue and neither any other preparation nor
>> other knowledge:
>>
>> | sms | sms := HydraSMS doitAt: 2.
>> sms atHomeDo: [Transcript cr; show: 'Hydra .image #2 is up and
>> running']
>>
>> , for which #doitAt: automagically compiles the very-same method in the
>> other image :)
>>
> Be warned, that using index instead of handle to identify interpreter
> is not a good way.
Well, that's exactly what the higher levels are good for: tell the user
what's up, without demanding from him to know anything about the
internals. Of course I cannot post the above example so that it rises all
possible exceptions, so at the moment you have to engage imagination and
*think* that proper notification is given (NetworkContext does check and
report whatever problem it finds).
> All primitives are handle-oriented, an #at: methods simply doing:
> HydraVM interpreters at: n.
We cannot really want the user to type in values for your
interpreterHandle, unless they are used to typing MS$ registry keys and
*demand* that from us ;-)
> There is a danger, that when in future i add code to shutdown images,
> then indexed can be changed, and thus, code based on indexes might
> fail, because if you having 3 interpreters running:
>
> #(x y z)
>
> and you shutting down 2nd one,
> then 'HydraVM interpreters' will return array with 2 handles:
> #(x z) , so #at: 3 will lead to error,
What error, Smalltalk's Error instance? Image crash? Interpreter crash?
Executable crash? OS crash? Market melt-down? Blackout of the Internet?
And, BTW, why would you make that undeterministic? I'm used to multi-CPU
machines for decades and we always index the physical processor (also
virtual processor) by its constant index. I could send you an indexing
schema in case you need one.
> and #at: 2 will return different handle.
I don't see much danger with different handles, since I will be carefully
reading your future Hydra release notes :)
>> /Klaus
>>
>>
>>
>
>
More information about the Squeak-dev
mailing list
|