Can't sync with Connect

Recently I have been having trouble syncing my customer's server with my project on Studio. They are using a proxy server, but I'm not sure what port Connect uses to sync my project. I am able to browse the web from the server, so clearly port 80 is open. Does anybody have any idea what port Connect uses? I have pasted the error message from the server log below. Thanks Stuart

2013-02-27 10:31:08,623 INFO  [org.apache.commons.httpclient.HttpMethodDirector] I/O exception (java.net.ConnectException) caught when processing request: Connection refused: connect
2013-02-27 10:31:08,623 INFO  [org.apache.commons.httpclient.HttpMethodDirector] Retrying request
2013-02-27 10:31:12,176 INFO  [org.apache.commons.httpclient.HttpMethodDirector] I/O exception (java.net.ConnectException) caught when processing request: Connection refused: connect
2013-02-27 10:31:12,176 INFO  [org.apache.commons.httpclient.HttpMethodDirector] Retrying request
2013-02-27 10:31:15,489 INFO  [org.apache.commons.httpclient.HttpMethodDirector] I/O exception (java.net.ConnectException) caught when processing request: Connection refused: connect
2013-02-27 10:31:15,489 INFO  [org.apache.commons.httpclient.HttpMethodDirector] Retrying request
2013-02-27 10:31:16,489 WARN  [org.nuxeo.connect.connector.http.ConnectHttpConnector] Connect Server is not reachable
2013-02-27 10:31:16,489 WARN  [org.nuxeo.connect.client.status.ConnectStatusHolder] can not reach connect server
org.nuxeo.connect.connector.CanNotReachConnectServer: Connection refused: connect
    at org.nuxeo.connect.connector.http.ConnectHttpConnector.execServerCall(ConnectHttpConnector.java:138)
    at org.nuxeo.connect.connector.AbstractConnectConnector.execCall(AbstractConnectConnector.java:59)
    at org.nuxeo.connect.connector.AbstractConnectConnector.getConnectStatus(AbstractConnectConnector.java:68)
    at org.nuxeo.connect.connector.http.ConnectHttpConnector.getConnectStatus(ConnectHttpConnector.java:173)
    at org.nuxeo.connect.client.status.ConnectStatusHolder.getStatus(ConnectStatusHolder.java:90)
    at org.nuxeo.connect.client.status.ConnectStatusHolder.getStatus(ConnectStatusHolder.java:70)
    at org.nuxeo.connect.client.jsf.ConnectStatusActionBean.isConnectServerReachable(ConnectStatusActionBean.java:208)
0 votes

1 answers

2904 views

ANSWER

I do have the exact same issue when running a nuxeo in OpenShift. I am using latest published 5.7 and my nuxeo-connect-client version is 1.4.6.
03/28/2013

So after some digging it looks like this is due to a limitation of httpclient 3.x which forces a local socket binding on '0.0.0.0'. As OpenShift prevents this it fails.

There are 2 options to solve this:

  • migrate to httpclient 4.x and use ConnRoutePNames#LOCAL_ADDRESS to bind to nuxeo.bind.address
  • follow this hack

Unfortunately evenso this fixes the issue I still fail to get Studio hot reloading working.

03/28/2013

Julien, do you mean that therefore httpclient 3.x with its regular API cannot be used anywhere on OpenShift? I don't understand why connecting to a remote server would binds locally to 0.0.0.0. Can you share stack traces of what happens? Note that connecting to the Nuxeo Connect server should not require binding to a local port on the Nuxeo server.
03/29/2013

> Julien, do you mean that therefore httpclient 3.x with its regular API cannot be used anywhere on OpenShift?

Yes. There's a couple of threads in OpenShift forum about this.

>I don't understand why connecting to a remote server would binds locally to 0.0.0.0.

Me neither. You can see doc for the Socket constructor used here. They explicitly state there will be a local bind. Alternative constructors work fine on OpenShift.

The exception I had was similar to the one mentioned in this thread. Underlying cause was a permission denied. For the record I moved away from OpenShift for now as it proved too much time consuming (hot reloading was still not correctly working even after this issue patched).

03/29/2013



Hi,

Please provide the version of your Nuxeo server, especially the nuxeo-connect-client version.

Default port is 443 (HTTPS), not 80. Note you can provide some proxy parameters to the Connect client.

0 votes