[mod_cluster-dev] jboss.mod_cluster.proxyList
Paul Ferraro
paul.ferraro at redhat.com
Tue May 11 11:20:11 EDT 2010
Yup - I resolved it yesterday.
On Tue, 2010-05-11 at 08:37 +0200, Bela Ban wrote:
> Great, thx, did you see the JIRA issue I opened ?
>
> Paul Ferraro wrote:
> > Good point. This actually has a couple ramifications:
> > 1. Can delay AS startup
> > 2. Can tie up jbossweb background processing thread
> >
> > This is something I can quickly fix for 1.1.0.CR2.
> >
> > On Mon, 2010-05-10 at 16:26 +0200, Bela Ban wrote:
> >
> >> I found that when I set jboss.mod_cluster.proxyList to include 2
> >> elements, and the 2nd element is not reachable, the mod-cluster
> >> subsystem takes a long time to start.
> >>
> >> How to reproduce:
> >>
> >>
> >> set jboss.mod_cluster.proxyList (either in the XML file, or via system
> >> prop) to "http1.dyndns.org:8000,http2.dyndns.org:8000"
> >>
> >> Currently http2.dyndns.org resolves to 192.168.1.5. If we cannot connect
> >> to such an interface, the socket connection blocks.
> >>
> >> I suspect, the following is done (in pseudo code) in mod-cluster (Java
> >> side):
> >>
> >> for(Host host: hosts) {
> >> Socket sock=new Socket(host, port);
> >> }
> >>
> >>
> >> However, this can block up to N minutes (depending on OS), I'd suggest
> >> the following code:
> >>
> >> int CONNECT_TIMEOUT=1000; // try to connect, but only wait for 1 sec
> >> Socket sock=new Socket();
> >>
> >> try {
> >> sock.connect(new InetSocketAddress(hostname, port), CONNECT_TIMEOUT);
> >> }
> >> catch(SocketTimeoutException ex) {
> >> // skip hostname
> >> }
> >>
> >>
> >> WDYT ?
> >>
> >>
> >
> >
> >
> >
>
More information about the mod_cluster-dev
mailing list