This is the mail archive of the java-discuss@sourceware.cygnus.com mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Servlets, Apache JServ and gcj/libgcj


Joerg Brunsmann wrote:

> P.S.: Since I'm a total idiot can someone please explain, why
> the libcj ServerSocket implementation complains about
>
> Exception creating the server socket: java.net.BindException: SocketImpl.bind: Error 0
>
> after stopping the JServ servlet engine with Ctrl-C wheras the
> same program executed with a java vm starts again without
> complaining. Netstat says that the state is TIME_WAIT.

When you kill a libgcj app with Ctrl-C, it often seems to take a while for all its
threads to actually die. You
can see this on programs which are continuously writing to System.out - after you press
ctrl-c the data
keeps coming for a second or two. If you have a server app, it sometimes takes 10 seconds
or mroe for
the kernel to release the sockets your app was using. If your program exits with
System.exit(), though,
there doesn't seem to be a problem.

regards

  [ bryce ]



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]