[Pharo-project] Invalid socket handle in Zinc Server after image startup
Hi all, Is anyone else having problems with Zinc servers not starting up correctly when the image is loaded? After the image starts up the server has an invalid socket handle. To reproduce, evaluate the following in a workspace, then save and quit the image. aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start Any ideas? Mark
On Apr 8, 2012, at 4:11 PM, Mark Smith wrote:
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
I changed the path and in my browser I get the list of mcz file. I saved and restarted my image and I got the same
Mark, On 08 Apr 2012, at 16:11, Mark Smith wrote:
Hi all,
Is anyone else having problems with Zinc servers not starting up correctly when the image is loaded?
After the image starts up the server has an invalid socket handle.
To reproduce, evaluate the following in a workspace, then save and quit the image.
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
Any ideas?
Mark
Only the default server (ZnServer default) is sent #register on #start so that it will be sent #start/#stop on System #startUp/#shutDown. Have a look at ZnSingleThreadedServer>>#start and/or follow ZnServer>>#register. To make this work, either change your example to aServer := ZnServer defaultOn: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start or to aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer register. aServer start It is by design that not every server is registered (as not everyone needs this behavior). The default server is an exception because it is used for first time and more casual usage and many people expect this behavior in Smalltalk. HTH, Sven -- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
Hi Sven, That makes a lot of sense :). Perhaps this could be added to the Getting Started section of the website? Thanks! Mark On 8 Apr 2012, at 17:11, Sven Van Caekenberghe wrote:
Mark,
On 08 Apr 2012, at 16:11, Mark Smith wrote:
Hi all,
Is anyone else having problems with Zinc servers not starting up correctly when the image is loaded?
After the image starts up the server has an invalid socket handle.
To reproduce, evaluate the following in a workspace, then save and quit the image.
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
Any ideas?
Mark
Only the default server (ZnServer default) is sent #register on #start so that it will be sent #start/#stop on System #startUp/#shutDown. Have a look at ZnSingleThreadedServer>>#start and/or follow ZnServer>>#register.
To make this work, either change your example to
aServer := ZnServer defaultOn: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
or to
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer register. aServer start
It is by design that not every server is registered (as not everyone needs this behavior). The default server is an exception because it is used for first time and more casual usage and many people expect this behavior in Smalltalk.
HTH,
Sven
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
I'm trying to make sven write a chapter :) So I added it to the server section :) Stef
Hi Sven,
That makes a lot of sense :).
Perhaps this could be added to the Getting Started section of the website?
Thanks!
Mark
On 8 Apr 2012, at 17:11, Sven Van Caekenberghe wrote:
Mark,
On 08 Apr 2012, at 16:11, Mark Smith wrote:
Hi all,
Is anyone else having problems with Zinc servers not starting up correctly when the image is loaded?
After the image starts up the server has an invalid socket handle.
To reproduce, evaluate the following in a workspace, then save and quit the image.
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
Any ideas?
Mark
Only the default server (ZnServer default) is sent #register on #start so that it will be sent #start/#stop on System #startUp/#shutDown. Have a look at ZnSingleThreadedServer>>#start and/or follow ZnServer>>#register.
To make this work, either change your example to
aServer := ZnServer defaultOn: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
or to
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer register. aServer start
It is by design that not every server is registered (as not everyone needs this behavior). The default server is an exception because it is used for first time and more casual usage and many people expect this behavior in Smalltalk.
HTH,
Sven
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
Great :). I hope you succeed in coaxing Sven to write a chapter. The more written down the better :). Mark. On 8 Apr 2012, at 17:48, Stéphane Ducasse wrote:
I'm trying to make sven write a chapter :) So I added it to the server section :)
Stef
Hi Sven,
That makes a lot of sense :).
Perhaps this could be added to the Getting Started section of the website?
Thanks!
Mark
On 8 Apr 2012, at 17:11, Sven Van Caekenberghe wrote:
Mark,
On 08 Apr 2012, at 16:11, Mark Smith wrote:
Hi all,
Is anyone else having problems with Zinc servers not starting up correctly when the image is loaded?
After the image starts up the server has an invalid socket handle.
To reproduce, evaluate the following in a workspace, then save and quit the image.
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
Any ideas?
Mark
Only the default server (ZnServer default) is sent #register on #start so that it will be sent #start/#stop on System #startUp/#shutDown. Have a look at ZnSingleThreadedServer>>#start and/or follow ZnServer>>#register.
To make this work, either change your example to
aServer := ZnServer defaultOn: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
or to
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer register. aServer start
It is by design that not every server is registered (as not everyone needs this behavior). The default server is an exception because it is used for first time and more casual usage and many people expect this behavior in Smalltalk.
HTH,
Sven
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
Am 08.04.2012 um 18:56 schrieb Mark Smith:
Great :). I hope you succeed in coaxing Sven to write a chapter.
The more written down the better :).
So, do it. Documentation written from a user perspective is often more useful than the one written by the developer. The problems you faced and solved are pretty much the same another user will encounter. So you can answer it best. Don't rely on Sven to write documentation but ask him about things you don't understand. Norbert
On 8 Apr 2012, at 17:48, Stéphane Ducasse wrote:
I'm trying to make sven write a chapter :) So I added it to the server section :)
Stef
Hi Sven,
That makes a lot of sense :).
Perhaps this could be added to the Getting Started section of the website?
Thanks!
Mark
On 8 Apr 2012, at 17:11, Sven Van Caekenberghe wrote:
Mark,
On 08 Apr 2012, at 16:11, Mark Smith wrote:
Hi all,
Is anyone else having problems with Zinc servers not starting up correctly when the image is loaded?
After the image starts up the server has an invalid socket handle.
To reproduce, evaluate the following in a workspace, then save and quit the image.
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
Any ideas?
Mark
Only the default server (ZnServer default) is sent #register on #start so that it will be sent #start/#stop on System #startUp/#shutDown. Have a look at ZnSingleThreadedServer>>#start and/or follow ZnServer>>#register.
To make this work, either change your example to
aServer := ZnServer defaultOn: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
or to
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer register. aServer start
It is by design that not every server is registered (as not everyone needs this behavior). The default server is an exception because it is used for first time and more casual usage and many people expect this behavior in Smalltalk.
HTH,
Sven
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
On 9 Apr 2012, at 10:07, Norbert Hartl wrote:
Am 08.04.2012 um 18:56 schrieb Mark Smith:
Great :). I hope you succeed in coaxing Sven to write a chapter.
The more written down the better :).
So, do it. Documentation written from a user perspective is often more useful than the one written by the developer. The problems you faced and solved are pretty much the same another user will encounter. So you can answer it best. Don't rely on Sven to write documentation but ask him about things you don't understand.
Norbert
That seems very reasonable. Is there a place I should put such documentation or should I just blog it and hope that someone finds it in Google? Mark
On 8 Apr 2012, at 17:48, Stéphane Ducasse wrote:
I'm trying to make sven write a chapter :) So I added it to the server section :)
Stef
Hi Sven,
That makes a lot of sense :).
Perhaps this could be added to the Getting Started section of the website?
Thanks!
Mark
On 8 Apr 2012, at 17:11, Sven Van Caekenberghe wrote:
Mark,
On 08 Apr 2012, at 16:11, Mark Smith wrote:
Hi all,
Is anyone else having problems with Zinc servers not starting up correctly when the image is loaded?
After the image starts up the server has an invalid socket handle.
To reproduce, evaluate the following in a workspace, then save and quit the image.
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
Any ideas?
Mark
Only the default server (ZnServer default) is sent #register on #start so that it will be sent #start/#stop on System #startUp/#shutDown. Have a look at ZnSingleThreadedServer>>#start and/or follow ZnServer>>#register.
To make this work, either change your example to
aServer := ZnServer defaultOn: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer start
or to
aServer := ZnServer on: 8080. aServer delegate: ((ZnMonticelloServerDelegate new) directory: (FileDirectory on: '/Users/sven/Tmp/monticello')). aServer register. aServer start
It is by design that not every server is registered (as not everyone needs this behavior). The default server is an exception because it is used for first time and more casual usage and many people expect this behavior in Smalltalk.
HTH,
Sven
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
On 08 Apr 2012, at 18:48, Stéphane Ducasse wrote:
I'm trying to make sven write a chapter :) So I added it to the server section :)
Yes, I have to write some (more) documentation, I know. It is on my list. And one day it will happen. Sven
Sven I started to collect material in the Draft/Zinc/ folder on pharobooks. Do you need access to it? Stef On Apr 9, 2012, at 6:46 PM, Sven Van Caekenberghe wrote:
On 08 Apr 2012, at 18:48, Stéphane Ducasse wrote:
I'm trying to make sven write a chapter :) So I added it to the server section :)
Yes, I have to write some (more) documentation, I know. It is on my list. And one day it will happen.
Sven
On 09 Apr 2012, at 21:21, Stéphane Ducasse wrote:
Sven I started to collect material in the Draft/Zinc/ folder on pharobooks. Do you need access to it?
Yes, I can have a look, we don't have to do double work ;-)
Stef
On Apr 9, 2012, at 6:46 PM, Sven Van Caekenberghe wrote:
On 08 Apr 2012, at 18:48, Stéphane Ducasse wrote:
I'm trying to make sven write a chapter :) So I added it to the server section :)
Yes, I have to write some (more) documentation, I know. It is on my list. And one day it will happen.
Sven
You were already in :) svn checkout svn://scm.gforge.inria.fr/svnroot/pharobooks/ svn checkout --username anonsvn https://scm.gforge.inria.fr/svn/pharobooks/ Stef On Apr 9, 2012, at 10:51 PM, Sven Van Caekenberghe wrote:
On 09 Apr 2012, at 21:21, Stéphane Ducasse wrote:
Sven I started to collect material in the Draft/Zinc/ folder on pharobooks. Do you need access to it?
Yes, I can have a look, we don't have to do double work ;-)
Stef
On Apr 9, 2012, at 6:46 PM, Sven Van Caekenberghe wrote:
On 08 Apr 2012, at 18:48, Stéphane Ducasse wrote:
I'm trying to make sven write a chapter :) So I added it to the server section :)
Yes, I have to write some (more) documentation, I know. It is on my list. And one day it will happen.
Sven
participants (4)
-
Mark Smith -
Norbert Hartl -
Stéphane Ducasse -
Sven Van Caekenberghe