Liferay 6.2 CE GA4无法在互联网上创建任何portlet

时间:2015-07-30 08:54:22

标签: java eclipse liferay

我使用预先下载的SDK / Tomcat / LR Source创建了一个全新的Liferay 6.2 CE GA4。我在eclipse中创建了服务器,当我第一次尝试创建portlet时,它尝试下载" gradle-2.2.1-bin.zip"来自互联网。

我已经从#34; https://downloads.gradle.org/distributions/gradle-2.2.1-bin.zip"并把它放在" liferay-plugins-sdk-6.2 \ tools \ gradle \ gradle \ wrapper"中。

仍显示与以下相同的错误:

`Downloading https://services.gradle.org/distributions/gradle-2.2.1-bin.zip

Exception in thread "main" java.net.ConnectException: Connection timed out: connect
    at java.net.PlainSocketImpl.socketConnect(Native Method)
    at java.net.PlainSocketImpl.doConnect(Unknown Source)
    at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
    at java.net.PlainSocketImpl.connect(Unknown Source)
    at java.net.SocksSocketImpl.connect(Unknown Source)
    at java.net.Socket.connect(Unknown Source)
    at com.sun.net.ssl.internal.ssl.SSLSocketImpl.connect(Unknown Source)
    at com.sun.net.ssl.internal.ssl.BaseSSLSocketImpl.connect(Unknown Source)
    at sun.net.NetworkClient.doConnect(Unknown Source)
    at sun.net.www.http.HttpClient.openServer(Unknown Source)
    at sun.net.www.http.HttpClient.openServer(Unknown Source)
    at sun.net.www.protocol.https.HttpsClient.(Unknown Source)
    at sun.net.www.protocol.https.HttpsClient.New(Unknown Source)
    at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(Unknown Source)
    at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
    at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
    at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(Unknown Source)
    at org.gradle.wrapper.Download.downloadInternal(Download.java:56)
    at org.gradle.wrapper.Download.download(Download.java:42)
    at org.gradle.wrapper.Install$1.call(Install.java:57)
    at org.gradle.wrapper.Install$1.call(Install.java:44)
    at org.gradle.wrapper.ExclusiveFileAccessManager.access(ExclusiveFileAccessManager.java:65)
    at org.gradle.wrapper.Install.createDist(Install.java:44)
    at org.gradle.wrapper.WrapperExecutor.execute(WrapperExecutor.java:126)
    at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:56)
`

我将该zip放在错误的目录上还是遗漏了其他内容?

2 个答案:

答案 0 :(得分:1)

从错误消息中,我说:是的,好像你把文件放到了错误的目录中。哪一个是正确的?我不知道。在连接到互联网时,最简单的方法是进行首次构建。下载只会发生一次(也可能会有更多需要下载的依赖项),之后您可以离线完成构建。

答案 1 :(得分:0)

要解决您的问题,您需要:

  

1)删除内容:
  D:\ Profiles \ XXX.gradle \ wrapper \ dists \ gradle-2.2.1-bin \ 88n1whbyjvxg3s40jzz5ur27

     

2)手动下载:
  https://services.gradle.org/distributions/gradle-2.2.1-bin.zip

     

3)将gradle-2.2.1-bin.zip打开:
  d:\概况\ XXX.gradle \包装\ dists中\ gradle这个-2.2.1槽\ 88n1whbyjvxg3s40jzz5ur27