Alfresco / alfresco-sdk

The Alfresco In-Process SDK is based on Apache Maven, includes support for rapid and standard development, testing, packaging, versioning and release of your Alfresco integration and extension projects
Apache License 2.0
185 stars 113 forks source link

java.net.UnknownHostException: share-acs #577

Closed ghost closed 3 years ago

ghost commented 5 years ago

SDK - 4.0.0 platform.version - 6.1.2-ga share.version - 6.1.0-RC3 Host: Ubuntu java: openjdk version "1.8.0_222"

Error below:

share-share_1  | 2019-09-22 13:26:07,909  INFO  [webscripts.connector.RemoteClient] [http-nio-8080-exec-62] Exception calling (GET) http://share-acs:8080/alfresco/s/api/admin/restrictions?guest=true
share-share_1  | 2019-09-22 13:26:07,911  INFO  [webscripts.connector.RemoteClient] [http-nio-8080-exec-62] Error status 503 share-acs
share-share_1  | java.net.UnknownHostException: share-acs
share-share_1  |    at java.base/java.net.InetAddress$CachedAddresses.get(InetAddress.java:797)
share-share_1  |    at java.base/java.net.InetAddress.getAllByName0(InetAddress.java:1505)
share-share_1  |    at java.base/java.net.InetAddress.getAllByName(InetAddress.java:1364)
share-share_1  |    at java.base/java.net.InetAddress.getAllByName(InetAddress.java:1298)
share-share_1  |    at org.apache.http.impl.conn.SystemDefaultDnsResolver.resolve(SystemDefaultDnsResolver.java:45)
share-share_1  |    at org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:111)
share-share_1  |    at org.apache.http.impl.conn.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:353)
share-share_1  |    at org.apache.http.impl.execchain.MainClientExec.establishRoute(MainClientExec.java:380)
share-share_1  |    at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:236)
share-share_1  |    at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:184)
share-share_1  |    at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88)
share-share_1  |    at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110)
share-share_1  |    at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184)
share-share_1  |    at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82)
share-share_1  |    at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:107)
share-share_1  |    at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:55)
share-share_1  |    at org.springframework.extensions.webscripts.connector.RemoteClient.service(RemoteClient.java:1164)
share-share_1  |    at org.springframework.extensions.webscripts.connector.RemoteClient.service(RemoteClient.java:931)
share-share_1  |    at org.springframework.extensions.webscripts.connector.RemoteClient.call(RemoteClient.java:654)
share-share_1  |    at org.springframework.extensions.webscripts.connector.RemoteClient.call(RemoteClient.java:588)
share-share_1  |    at org.springframework.extensions.webscripts.connector.HttpConnector.call(HttpConnector.java:70)
share-share_1  |    at org.springframework.extensions.webscripts.RequestCachingConnector.call(RequestCachingConnector.java:91)
share-share_1  |    at org.springframework.extensions.webscripts.connector.AbstractConnector.call(AbstractConnector.java:116)
share-share_1  |    at org.springframework.extensions.webscripts.connector.AuthenticatingConnector.call(AuthenticatingConnector.java:114)
share-share_1  |    at org.alfresco.web.site.EditionInterceptor.preHandle(EditionInterceptor.java:116)
share-share_1  |    at org.springframework.web.servlet.handler.WebRequestHandlerInterceptorAdapter.preHandle(WebRequestHandlerInterceptorAdapter.java:55)
share-share_1  |    at org.springframework.web.servlet.HandlerExecutionChain.applyPreHandle(HandlerExecutionChain.java:134)
share-share_1  |    at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:928)
share-share_1  |    at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:867)
share-share_1  |    at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:953)
share-share_1  |    at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:844)
share-share_1  |    at javax.servlet.http.HttpServlet.service(HttpServlet.java:635)
share-share_1  |    at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:829)
share-share_1  |    at javax.servlet.http.HttpServlet.service(HttpServlet.java:742)
share-share_1  |    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
share-share_1  |    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
share-share_1  |    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
share-share_1  |    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
share-share_1  |    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
share-share_1  |    at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:728)
share-share_1  |    at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:470)
share-share_1  |    at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:395)
share-share_1  |    at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:316)
share-share_1  |    at org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:213)
share-share_1  |    at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:171)
share-share_1  |    at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145)
share-share_1  |    at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92)
share-share_1  |    at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:389)
share-share_1  |    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
share-share_1  |    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
share-share_1  |    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)
share-share_1  |    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
share-share_1  |    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:493)
share-share_1  |    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)
share-share_1  |    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)
share-share_1  |    at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:650)
share-share_1  |    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
share-share_1  |    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342)
share-share_1  |    at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:800)
share-share_1  |    at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
share-share_1  |    at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:806)
share-share_1  |    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1498)
share-share_1  |    at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
share-share_1  |    at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
share-share_1  |    at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
share-share_1  |    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
share-share_1  |    at java.base/java.lang.Thread.run(Thread.java:834)
jlosornogil commented 5 years ago

Hello @rastoh ,

The problem it is shown in your log is Alfresco Share can't connect to ACS (Alfresco repository), so I think the source of your problem is that ACS hasn't started properly. I can't see the complete log so I can't tell you for sure, but I offer you a couple of ideas:

  1. (Most likely) I can see that you're using Alfresco version 6.1 and JDK 1.8. ACS 6.1 requires Java 11 to work so I guess the startup of platform is failing because of that.
  2. You're using the share archetype that has the platform service commented out in the docker-compose.yml file. In order to use it you should uncomment it.

I hope this helps :)

mapimienta commented 4 years ago

In share I modified pom.xml [with the acs.host that appears in the pom.xml from repo]</acs.host>