2

Rational Application Developer v9.0 を実行しており、Gradle IDE Eclipse プラグイン (v3.4.0) を使用して gradle プロジェクトをインポートしようとしています。

私の Gradle プロジェクト (ネストされたマルチ プロジェクト ビルド) はコマンド ラインで正しくビルドされますが、それをインポートしbuild modelてコンソールをクリックしようとすると、この見苦しいスタック トレースがぼやけます:

Problems handling incoming cache access requests.
java.lang.UnsatisfiedLinkError: net (C:\Program Files (x86)\IBM\SDP_1\jdk\jre\bin\net.dll is not a valid Win32 application. )
    at java.lang.ClassLoader.loadLibraryWithPath(ClassLoader.java:1197)
    at java.lang.ClassLoader.loadLibraryWithClassLoader(ClassLoader.java:1161)
    at java.lang.System.loadLibrary(System.java:527)
    at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:79)
    at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:59)
    at java.security.AccessController.doPrivileged(AccessController.java:229)
    at java.net.DatagramPacket.<clinit>(DatagramPacket.java:60)
    at java.lang.J9VMInternals.initializeImpl(Native Method)
    at java.lang.J9VMInternals.initialize(J9VMInternals.java:236)
    at org.gradle.cache.internal.FileLockCommunicator.receive(FileLockCommunicator.java:59)
    at org.gradle.cache.internal.locklistener.DefaultFileLockContentionHandler$1.doRun(DefaultFileLockContentionHandler.java:66)
    at org.gradle.cache.internal.locklistener.DefaultFileLockContentionHandler$1.run(DefaultFileLockContentionHandler.java:53)
    at org.gradle.internal.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(DefaultExecutorFactory.java:64)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1156)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:626)
    at java.lang.Thread.run(Thread.java:780)

以前は問題なくプロジェクトをインポートできましたが、現在このエラーが発生しており、その理由がわかりません。

あなたの助けに感謝します:)。

更新:ワークスペースの .metadata ディレクトリにあるログ ファイルには、より詳細なログ メッセージが表示されます。

!ENTRY org.springsource.ide.eclipse.gradle.core 4 0 2014-02-07 12:40:03.751
!MESSAGE An existing connection was forcibly closed by the remote host.
!STACK 0
java.lang.reflect.InvocationTargetException
    at org.springsource.ide.eclipse.gradle.core.util.GradleRunnable.run(Unknown Source)
    at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(Unknown Source)
Caused by: org.eclipse.core.runtime.CoreException: An existing connection was forcibly closed by the remote host.
    at org.springsource.ide.eclipse.gradle.core.GradleModelProvider$GroupedModelProvider.ensureModels(Unknown Source)
    at org.springsource.ide.eclipse.gradle.core.GradleProject.getGradleModel(Unknown Source)
    at org.springsource.ide.eclipse.gradle.core.GradleProject.getSkeletalGradleModel(Unknown Source)
    at org.springsource.ide.eclipse.gradle.ui.wizards.GradleImportWizardPageOne$11.doit(Unknown Source)
    ... 2 more
Caused by: org.gradle.tooling.GradleConnectionException: Could not fetch model of type 'HierarchicalEclipseProject' using Gradle distribution 'http://services.gradle.org/distributions/gradle-1.11-rc-1-all.zip'.
    at org.gradle.tooling.internal.consumer.ResultHandlerAdapter.onFailure(Unknown Source)
    at org.gradle.tooling.internal.consumer.async.DefaultAsyncConsumerActionExecutor$1$1.run(Unknown Source)
    at org.gradle.internal.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.BlockingResultHandler.attachCallerThreadStackTrace(Unknown Source)
    at org.gradle.tooling.internal.consumer.BlockingResultHandler.getResult(Unknown Source)
    at org.gradle.tooling.internal.consumer.DefaultModelBuilder.get(Unknown Source)
    at org.springsource.ide.eclipse.gradle.core.GradleModelProvider.buildModel(Unknown Source)
    ... 6 more
Caused by: org.gradle.launcher.daemon.client.DaemonConnectionException: Could not receive a message from the daemon.
    at org.gradle.launcher.daemon.client.DaemonClientConnection.receive(Unknown Source)
    at org.gradle.launcher.daemon.client.DaemonClient.monitorBuild(Unknown Source)
    at org.gradle.launcher.daemon.client.DaemonClient.executeBuild(Unknown Source)
    at org.gradle.launcher.daemon.client.DaemonClient.execute(Unknown Source)
    at org.gradle.launcher.daemon.client.DaemonClient.execute(Unknown Source)
    at org.gradle.tooling.internal.provider.DaemonBuildActionExecuter.execute(Unknown Source)
    at org.gradle.tooling.internal.provider.DaemonBuildActionExecuter.execute(Unknown Source)
    at org.gradle.tooling.internal.provider.LoggingBridgingBuildActionExecuter.execute(Unknown Source)
    at org.gradle.tooling.internal.provider.LoggingBridgingBuildActionExecuter.execute(Unknown Source)
    at org.gradle.tooling.internal.provider.ProviderConnection.run(Unknown Source)
    at org.gradle.tooling.internal.provider.ProviderConnection.run(Unknown Source)
    at org.gradle.tooling.internal.provider.DefaultConnection.getModel(Unknown Source)
    at org.gradle.tooling.internal.consumer.connection.ModelBuilderBackedConsumerConnection.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.DefaultModelBuilder$1.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.connection.LazyConsumerActionExecutor.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.connection.ProgressLoggingConsumerActionExecutor.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.connection.LoggingInitializerConsumerActionExecutor.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.async.DefaultAsyncConsumerActionExecutor$1$1.run(Unknown Source)
    at org.gradle.internal.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
Caused by: org.gradle.messaging.remote.internal.MessageIOException: Could not read message from '/127.0.0.1:50434'.
    at org.gradle.messaging.remote.internal.inet.SocketConnection.receive(Unknown Source)
    ... 22 more
Caused by: java.io.IOException: An existing connection was forcibly closed by the remote host.
    at sun.nio.ch.SocketDispatcher.read0(Native Method)
    at sun.nio.ch.SocketDispatcher.read(Unknown Source)
    at sun.nio.ch.IOUtil.readIntoNativeBuffer(Unknown Source)
    at sun.nio.ch.IOUtil.read(Unknown Source)
    at sun.nio.ch.SocketChannelImpl.read(Unknown Source)
    at org.gradle.messaging.remote.internal.inet.SocketConnection$SocketInputStream.read(Unknown Source)
    at java.io.ObjectInputStream$PeekInputStream.read(Unknown Source)
    at java.io.ObjectInputStream$PeekInputStream.readFully(Unknown Source)
    at java.io.ObjectInputStream$BlockDataInputStream.readShort(Unknown Source)
    at java.io.ObjectInputStream.readStreamHeader(Unknown Source)
    at java.io.ObjectInputStream.<init>(Unknown Source)
    at org.gradle.internal.io.ClassLoaderObjectInputStream.<init>(Unknown Source)
    at org.gradle.messaging.remote.internal.Message$ExceptionReplacingObjectInputStream.<init>(Unknown Source)
    at org.gradle.messaging.remote.internal.Message.receive(Unknown Source)
    at org.gradle.messaging.remote.internal.DefaultMessageSerializer$MessageReader.read(Unknown Source)
    ... 23 more
Root exception:
org.eclipse.core.runtime.CoreException: An existing connection was forcibly closed by the remote host.
    at org.springsource.ide.eclipse.gradle.core.GradleModelProvider$GroupedModelProvider.ensureModels(Unknown Source)
    at org.springsource.ide.eclipse.gradle.core.GradleProject.getGradleModel(Unknown Source)
    at org.springsource.ide.eclipse.gradle.core.GradleProject.getSkeletalGradleModel(Unknown Source)
    at org.springsource.ide.eclipse.gradle.ui.wizards.GradleImportWizardPageOne$11.doit(Unknown Source)
    at org.springsource.ide.eclipse.gradle.core.util.GradleRunnable.run(Unknown Source)
    at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(Unknown Source)
Caused by: org.gradle.tooling.GradleConnectionException: Could not fetch model of type 'HierarchicalEclipseProject' using Gradle distribution 'http://services.gradle.org/distributions/gradle-1.11-rc-1-all.zip'.
    at org.gradle.tooling.internal.consumer.ResultHandlerAdapter.onFailure(Unknown Source)
    at org.gradle.tooling.internal.consumer.async.DefaultAsyncConsumerActionExecutor$1$1.run(Unknown Source)
    at org.gradle.internal.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.BlockingResultHandler.attachCallerThreadStackTrace(Unknown Source)
    at org.gradle.tooling.internal.consumer.BlockingResultHandler.getResult(Unknown Source)
    at org.gradle.tooling.internal.consumer.DefaultModelBuilder.get(Unknown Source)
    at org.springsource.ide.eclipse.gradle.core.GradleModelProvider.buildModel(Unknown Source)
    ... 6 more
Caused by: org.gradle.launcher.daemon.client.DaemonConnectionException: Could not receive a message from the daemon.
    at org.gradle.launcher.daemon.client.DaemonClientConnection.receive(Unknown Source)
    at org.gradle.launcher.daemon.client.DaemonClient.monitorBuild(Unknown Source)
    at org.gradle.launcher.daemon.client.DaemonClient.executeBuild(Unknown Source)
    at org.gradle.launcher.daemon.client.DaemonClient.execute(Unknown Source)
    at org.gradle.launcher.daemon.client.DaemonClient.execute(Unknown Source)
    at org.gradle.tooling.internal.provider.DaemonBuildActionExecuter.execute(Unknown Source)
    at org.gradle.tooling.internal.provider.DaemonBuildActionExecuter.execute(Unknown Source)
    at org.gradle.tooling.internal.provider.LoggingBridgingBuildActionExecuter.execute(Unknown Source)
    at org.gradle.tooling.internal.provider.LoggingBridgingBuildActionExecuter.execute(Unknown Source)
    at org.gradle.tooling.internal.provider.ProviderConnection.run(Unknown Source)
    at org.gradle.tooling.internal.provider.ProviderConnection.run(Unknown Source)
    at org.gradle.tooling.internal.provider.DefaultConnection.getModel(Unknown Source)
    at org.gradle.tooling.internal.consumer.connection.ModelBuilderBackedConsumerConnection.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.DefaultModelBuilder$1.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.connection.LazyConsumerActionExecutor.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.connection.ProgressLoggingConsumerActionExecutor.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.connection.LoggingInitializerConsumerActionExecutor.run(Unknown Source)
    at org.gradle.tooling.internal.consumer.async.DefaultAsyncConsumerActionExecutor$1$1.run(Unknown Source)
    at org.gradle.internal.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
Caused by: org.gradle.messaging.remote.internal.MessageIOException: Could not read message from '/127.0.0.1:50434'.
    at org.gradle.messaging.remote.internal.inet.SocketConnection.receive(Unknown Source)
    ... 22 more
Caused by: java.io.IOException: An existing connection was forcibly closed by the remote host.
    at sun.nio.ch.SocketDispatcher.read0(Native Method)
    at sun.nio.ch.SocketDispatcher.read(Unknown Source)
    at sun.nio.ch.IOUtil.readIntoNativeBuffer(Unknown Source)
    at sun.nio.ch.IOUtil.read(Unknown Source)
    at sun.nio.ch.SocketChannelImpl.read(Unknown Source)
    at org.gradle.messaging.remote.internal.inet.SocketConnection$SocketInputStream.read(Unknown Source)
    at java.io.ObjectInputStream$PeekInputStream.read(Unknown Source)
    at java.io.ObjectInputStream$PeekInputStream.readFully(Unknown Source)
    at java.io.ObjectInputStream$BlockDataInputStream.readShort(Unknown Source)
    at java.io.ObjectInputStream.readStreamHeader(Unknown Source)
    at java.io.ObjectInputStream.<init>(Unknown Source)
    at org.gradle.internal.io.ClassLoaderObjectInputStream.<init>(Unknown Source)
    at org.gradle.messaging.remote.internal.Message$ExceptionReplacingObjectInputStream.<init>(Unknown Source)
    at org.gradle.messaging.remote.internal.Message.receive(Unknown Source)
    at org.gradle.messaging.remote.internal.DefaultMessageSerializer$MessageReader.read(Unknown Source)
    ... 23 more
4

2 に答える 2

4

私は同じ RAD9/Gradle プラグインの戦いも戦ってきましたが、最終的にインポートまたは単純な Java プロジェクトを成功させました。

Sun/Oracle JDK 7 をどこかにインストールしてみてください。Gradle 自体がそれを使用するように構成されていることを確認してから、RAD Preferences/Gradle/Arguments に移動し、Java ホームをワークスペース JRE に設定します: - Sun/Oracle Java 7 JDK を指す(JREではない)?

ここに画像の説明を入力

これを機能させるために多くのことを変更しましたが、これ以上の設定が必要になる場合があります。ただし、これは確かにそれを機能させる最終的な設定でした. 調査結果を投稿してください。うまくいかない場合は、セットアップに関する追加情報 (JAVA_HOME、GRADLE_HOME など) を投稿できます。

于 2014-03-05T12:14:06.803 に答える
0

「既存の接続がリモートホストによって強制的に閉じられました」というGradleに関するポップアップメッセージが表示され、Elipseログファイルには上記と同じものがありました。これは何度もうまくいきました。これが私がしたことです.

  1. コンピューターに JDK をインストールします (例: C:\Program Files\Java\jdk1.7.0_71)。
  2. 上記と同じパス (例: C:\Program Files\Java\jdk1.7.0_71) を使用して、[Window] > [Preferences] > [Java] > [Installed JREs] の下で Eclipse に追加します。
    (注: ここで現在アクティブなものとしてチェックする必要はありません。インストールする必要があるだけです。)
    - [適用] をクリックします。
  3. Gradle > Arguments > Workspace JRE を、追加したばかりの JRE (jdk のもの) に設定します。
    - [適用] と [OK] をクリックします。
  4. Gradle ビルドを再開します。一度、すぐに同じエラーが発生しましたが、いくつかのこと (クリーンなプロジェクト、JRE/Gradle 構成のダブルチェックなど) を試したところ、ビルドが開始され、エラーが解消されました。

于 2015-10-07T12:40:57.197 に答える