The Inbox: Network-dtl.137.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

The Inbox: Network-dtl.137.mcz

commits-2
A new version of Network was added to project The Inbox:
http://source.squeak.org/inbox/Network-dtl.137.mcz

==================== Summary ====================

Name: Network-dtl.137
Author: dtl
Time: 23 September 2012, 1:32:32.394 pm
UUID: b4bcd6e4-6a2d-4fc6-be4b-0d01accc3c72
Ancestors: Network-ul.136

Add a preference for "Enable IPv6 and new network support" in preference category "general". If enabled, IPv6 and the new network support will be enabled if the required primitives are present in the VM, otherwise the new network support is disabled regardless of whether the VM provides IPv6 primitives.

=============== Diff against Network-ul.136 ===============

Item was changed:
  Object subclass: #NetNameResolver
  instanceVariableNames: ''
+ classVariableNames: 'DefaultHostName EnableIPv6 HaveNetwork ResolverBusy ResolverError ResolverMutex ResolverReady ResolverSemaphore ResolverUninitialized UseOldNetwork'
- classVariableNames: 'DefaultHostName HaveNetwork ResolverBusy ResolverError ResolverMutex ResolverReady ResolverSemaphore ResolverUninitialized UseOldNetwork'
  poolDictionaries: ''
  category: 'Network-Kernel'!
 
  !NetNameResolver commentStamp: '<historical>' prior: 0!
  This class implements TCP/IP style network name lookup and translation facilities.
 
  Attempt to keep track of whether there is a network available.
  HaveNetwork true if last attempt to contact the network was successful.
  LastContact Time of that contact (totalSeconds).
  haveNetwork returns true, false, or #expired.  True means there was contact in the last 30 minutes.  False means contact failed or was false last time we asked.  Get out of false state by making contact with a server in some way (FileList or updates).!

Item was added:
+ ----- Method: NetNameResolver class>>enableIPv6 (in category 'system startup') -----
+ enableIPv6
+ <preference: 'Enable IPv6 and new network support'
+ category: 'general'
+ description: 'If true allow IPv6 support. If false, NetNameResolver useOldNetwork is set.'
+ type: #Boolean>
+ ^EnableIPv6!

Item was added:
+ ----- Method: NetNameResolver class>>enableIPv6: (in category 'system startup') -----
+ enableIPv6: aBool
+ "Set a preference to control whether IPv6 primitives and new network support
+ should be used if available, and reinitialize the UseOldNetwork flag to recognize
+ the setting. If true, the new networking support will be used if the VM provides
+ the required primitives. If false, IPv6 and new network support will not be used.
+ The new network support may be unreliable on some platforms, so this preference
+ allows it to be explicitly disabled."
+
+ EnableIPv6 := aBool.
+ self initializeOldNetworkFlag
+ !

Item was changed:
  ----- Method: NetNameResolver class>>initialize (in category 'class initialization') -----
  initialize
  "NetNameResolver initialize"
  "Note: On the Mac, the name resolver is asynchronous (i.e., Squeak can do other things while it is working), but can only handle one request at a time. On other platforms, such as Unix, the resolver is synchronous; a call to, say, the name lookup primitive will block all Squeak processes until it returns."
 
  "Resolver Status Values"
  ResolverUninitialized := 0. "network is not initialized"
  ResolverReady := 1. "resolver idle, last request succeeded"
  ResolverBusy := 2. "lookup in progress"
  ResolverError := 3. "resolver idle, last request failed"
 
  DefaultHostName := ''.
 
  UseOldNetwork := self hasIpv6PrimSupport not.
+ self enableIPv6: true. "Initialize preference to permit use of new networking"
  Smalltalk addToStartUpList: self.
 
  !

Item was added:
+ ----- Method: NetNameResolver class>>initializeOldNetworkFlag (in category 'system startup') -----
+ initializeOldNetworkFlag
+
+ UseOldNetwork := self hasIpv6PrimSupport not or: [self enableIPv6 ~= true]!

Item was changed:
  ----- Method: NetNameResolver class>>startUp: (in category 'system startup') -----
  startUp: resuming
+ "Set the UseOldNetwork flag if ipv6 primitives are not present or if the EnableIPv6 preference is not set."
- "Set the UseOldNetwork flag if ipv6 primitives are not present"
 
+ resuming ifTrue: [self initializeOldNetworkFlag]!
- resuming ifTrue: [UseOldNetwork := self hasIpv6PrimSupport not]!


Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: Network-dtl.137.mcz

David T. Lewis
There are problems with the new network support when running on Windows
with a newer VM that provides IPv6 primitives. This preference allows the
new network support to be disabled.

Default setting is true, which enables the new network support (as
is currently the case for a trunk image). It can be set false to disable
new network support, and I think that this should be done for the
Squeak 4.4 release image, otherwise we are going to cause problems
for lots of Windows users.

If no objections I will move this to trunk in a day or so.

Dave


On Sun, Sep 23, 2012 at 05:32:54PM +0000, [hidden email] wrote:

> A new version of Network was added to project The Inbox:
> http://source.squeak.org/inbox/Network-dtl.137.mcz
>
> ==================== Summary ====================
>
> Name: Network-dtl.137
> Author: dtl
> Time: 23 September 2012, 1:32:32.394 pm
> UUID: b4bcd6e4-6a2d-4fc6-be4b-0d01accc3c72
> Ancestors: Network-ul.136
>
> Add a preference for "Enable IPv6 and new network support" in preference category "general". If enabled, IPv6 and the new network support will be enabled if the required primitives are present in the VM, otherwise the new network support is disabled regardless of whether the VM provides IPv6 primitives.
>

Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: Network-dtl.137.mcz

Chris Muller-3
Is the image ready for a default value for enableIpv6 of true?



On Sun, Sep 23, 2012 at 12:44 PM, David T. Lewis <[hidden email]> wrote:

> There are problems with the new network support when running on Windows
> with a newer VM that provides IPv6 primitives. This preference allows the
> new network support to be disabled.
>
> Default setting is true, which enables the new network support (as
> is currently the case for a trunk image). It can be set false to disable
> new network support, and I think that this should be done for the
> Squeak 4.4 release image, otherwise we are going to cause problems
> for lots of Windows users.
>
> If no objections I will move this to trunk in a day or so.
>
> Dave
>
>
> On Sun, Sep 23, 2012 at 05:32:54PM +0000, [hidden email] wrote:
>> A new version of Network was added to project The Inbox:
>> http://source.squeak.org/inbox/Network-dtl.137.mcz
>>
>> ==================== Summary ====================
>>
>> Name: Network-dtl.137
>> Author: dtl
>> Time: 23 September 2012, 1:32:32.394 pm
>> UUID: b4bcd6e4-6a2d-4fc6-be4b-0d01accc3c72
>> Ancestors: Network-ul.136
>>
>> Add a preference for "Enable IPv6 and new network support" in preference category "general". If enabled, IPv6 and the new network support will be enabled if the required primitives are present in the VM, otherwise the new network support is disabled regardless of whether the VM provides IPv6 primitives.
>>
>

Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: Network-dtl.137.mcz

David T. Lewis
On Sun, Sep 23, 2012 at 03:35:49PM -0500, Chris Muller wrote:
> Is the image ready for a default value for enableIpv6 of true?
>

Yes. That's how it has been working for quite some time now. If we default
it to false in trunk, it will just turn into dead code.

I am suggesting that we disable it in the release image so as not to inflict
pain on users of an official release image, but keep it enabled in trunk so
that we either fix it or take a decision to abandon it in favor of something
better.

Dave


>
>
> On Sun, Sep 23, 2012 at 12:44 PM, David T. Lewis <[hidden email]> wrote:
> > There are problems with the new network support when running on Windows
> > with a newer VM that provides IPv6 primitives. This preference allows the
> > new network support to be disabled.
> >
> > Default setting is true, which enables the new network support (as
> > is currently the case for a trunk image). It can be set false to disable
> > new network support, and I think that this should be done for the
> > Squeak 4.4 release image, otherwise we are going to cause problems
> > for lots of Windows users.
> >
> > If no objections I will move this to trunk in a day or so.
> >
> > Dave
> >
> >
> > On Sun, Sep 23, 2012 at 05:32:54PM +0000, [hidden email] wrote:
> >> A new version of Network was added to project The Inbox:
> >> http://source.squeak.org/inbox/Network-dtl.137.mcz
> >>
> >> ==================== Summary ====================
> >>
> >> Name: Network-dtl.137
> >> Author: dtl
> >> Time: 23 September 2012, 1:32:32.394 pm
> >> UUID: b4bcd6e4-6a2d-4fc6-be4b-0d01accc3c72
> >> Ancestors: Network-ul.136
> >>
> >> Add a preference for "Enable IPv6 and new network support" in preference category "general". If enabled, IPv6 and the new network support will be enabled if the required primitives are present in the VM, otherwise the new network support is disabled regardless of whether the VM provides IPv6 primitives.
> >>
> >

Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: Network-dtl.137.mcz

Bert Freudenberg

On 2012-09-23, at 23:02, "David T. Lewis" <[hidden email]> wrote:

> On Sun, Sep 23, 2012 at 03:35:49PM -0500, Chris Muller wrote:
>> Is the image ready for a default value for enableIpv6 of true?
>>
>
> Yes. That's how it has been working for quite some time now. If we default
> it to false in trunk, it will just turn into dead code.
>
> I am suggesting that we disable it in the release image so as not to inflict
> pain on users of an official release image, but keep it enabled in trunk so
> that we either fix it or take a decision to abandon it in favor of something
> better.
>
> Dave


+1

- Bert -



Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: Network-dtl.137.mcz

Frank Shearar-3
On 24 September 2012 11:14, Bert Freudenberg <[hidden email]> wrote:

>
> On 2012-09-23, at 23:02, "David T. Lewis" <[hidden email]> wrote:
>
>> On Sun, Sep 23, 2012 at 03:35:49PM -0500, Chris Muller wrote:
>>> Is the image ready for a default value for enableIpv6 of true?
>>>
>>
>> Yes. That's how it has been working for quite some time now. If we default
>> it to false in trunk, it will just turn into dead code.
>>
>> I am suggesting that we disable it in the release image so as not to inflict
>> pain on users of an official release image, but keep it enabled in trunk so
>> that we either fix it or take a decision to abandon it in favor of something
>> better.
>>
>> Dave
>
>
> +1
>
> - Bert -

I'm keeping track of these sorts of things at http://wiki.squeak.org/squeak/6188

frank