Hello IWhite,
Thanks for your reply.
I investigated it just now. The size is 25. It seems to
be the size is harded coded in source.
com.sun.enterprise.ee.admin.configbeans.ServersConfigBean?.resolvePortConflicts()
} catch (PortInUseException ex) {
if (i++ > 25) {
//We do not want to throw the PortInUseException since it is an internal
//class and protected.
throw new InstanceException(ex.getMessage());
}
//If there were port conflicts, then we pick unused ports.
ArrayList newPorts = pickNonConflictingPorts(server, ex.getConflictingPorts());
//Keep track of the initial list of conflicting ports. This is tricky
//since the list in the PortInUseException will shrink as conflicts
//are resolved.
if (portsInUse == null) {
portsInUse = newPorts;
} else {
//Now take all the newly resolved ports and apply them to the original list, updating
//only the new port.
for (int j = 0; j < newPorts.size(); j++) {
PortInUse newPort = (PortInUse)newPorts.get(j);
for (int k = 0; k < portsInUse.size(); k++) {
PortInUse port = (PortInUse)portsInUse.get(k);
if (port.getPropertyName().equals(newPort.getPropertyName())) {
port.setNewPort(newPort.getNewPort());
break;
}
}
}
}
Besides, I found a useful link
https://glassfish.dev.java.net/issues/show_bug.cgi?id=3510
Thank u again.
Best Regards,
Zhang Biyun
[Message sent by forum member 'snailbreak' (snailbreak)]
http://forums.java.net/jive/thread.jspa?messageID=262852