Robert Munteanu created SLING-8254:
--------------------------------------

             Summary: Connecting to a Sling Server does not allow cancelling 
the operation
                 Key: SLING-8254
                 URL: https://issues.apache.org/jira/browse/SLING-8254
             Project: Sling
          Issue Type: Bug
          Components: IDE
            Reporter: Robert Munteanu
             Fix For: Sling Eclipse IDE 1.2.4


When connecting to a remote server with poor connectivity there are two 
problematic issues:

# there is no timeout, so the connection stalls forever
# there is no way to cancel as it's apparently not propagated from the UI

This, together with the around the repository map means that connecting to 
servers is not possible unless Eclipse is restarted or a long time (minutes?) 
is elapsed.

The stack trace of the hanging thread is

{noforomat}
"Worker-20: Starting Some Author" #86 prio=5 os_prio=0 tid=0x00007f6e443a4800 
nid=0x1a22 runnable [0x00007f6eb8cff000]
   java.lang.Thread.State: RUNNABLE
        at java.net.PlainSocketImpl.socketConnect(Native Method)
        at 
java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
        - locked <0x0000000722107898> (a java.net.SocksSocketImpl)
        at 
java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
        at 
java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
        at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
        at java.net.Socket.connect(Socket.java:589)
        at 
org.apache.http.conn.socket.PlainConnectionSocketFactory.connectSocket(PlainConnectionSocketFactory.java:75)
        at 
org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:142)
        at 
org.apache.http.impl.conn.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:359)
        at 
org.apache.http.impl.execchain.MainClientExec.establishRoute(MainClientExec.java:381)
        at 
org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:237)
        at 
org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:185)
        at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:89)
        at 
org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:111)
        at 
org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:185)
        at 
org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:83)
        at 
org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:56)
        at 
org.apache.jackrabbit.spi2dav.RepositoryServiceImpl.executeRequest(RepositoryServiceImpl.java:2802)
        at 
org.apache.jackrabbit.spi2dav.RepositoryServiceImpl.getRepositoryDescriptors(RepositoryServiceImpl.java:692)
        at 
org.apache.jackrabbit.jcr2spi.RepositoryImpl.<init>(RepositoryImpl.java:82)
        at 
org.apache.jackrabbit.jcr2spi.RepositoryImpl.create(RepositoryImpl.java:95)
        at 
org.apache.jackrabbit.jcr2spi.Jcr2spiRepositoryFactory.getRepository(Jcr2spiRepositoryFactory.java:163)
        at 
org.apache.jackrabbit.client.RepositoryFactoryImpl.getRepository(RepositoryFactoryImpl.java:75)
        at 
org.apache.jackrabbit.vault.davex.DAVExRepositoryFactory.createRepository(DAVExRepositoryFactory.java:110)
        at 
org.apache.sling.ide.jcr.RepositoryUtils.getRepositoryAddress(RepositoryUtils.java:84)
        - locked <0x0000000722108058> (a java.lang.Object)
        at 
org.apache.sling.ide.jcr.RepositoryUtils.getRepository(RepositoryUtils.java:52)
        at 
org.apache.sling.ide.impl.vlt.VltRepository.connect(VltRepository.java:70)
        at 
org.apache.sling.ide.impl.vlt.VltRepositoryFactory.connectRepository(VltRepositoryFactory.java:69)
        - locked <0x00000006c2037968> (a java.util.HashMap)
        at 
org.apache.sling.ide.eclipse.core.ServerUtil.connectRepository(ServerUtil.java:146)
        at 
org.apache.sling.ide.eclipse.core.internal.SlingLaunchpadBehaviour.start(SlingLaunchpadBehaviour.java:95)
        at 
org.apache.sling.ide.eclipse.core.internal.SlingLaunchpadLaunchConfigurationDelegate.launch(SlingLaunchpadLaunchConfigurationDelegate.java:45)
        at 
org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:862)
        at 
org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:720)
        at 
org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:715)
        at 
org.eclipse.wst.server.core.internal.Server.startImpl2(Server.java:3566)
        at 
org.eclipse.wst.server.core.internal.Server.startImpl(Server.java:3502)
        at 
org.eclipse.wst.server.core.internal.Server$StartJob.run(Server.java:377)
        at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
{noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to