Problem loading dependencies through a proxy using the gradle tooling API


(ignace.martin) #1

Hi,

I have a strange behavior using gradle through a proxy. When using the gradle command line in my projects, the dependencies are downloaded correctly. When using the Netbeans plugin for gradle which uses the tooling API, it blocks and finally I get the error :

Caused by: org.netbeans.gradle.model.util.TransferableExceptionWrapper: >org.gradle.api.internal.externalresource.transport.http.HttpRequestException: Could not HEAD ‘http://repo.jfrog.org/artifactory/repo1-cache/junit/junit/4.10/junit-4.10.jar’. >… >Caused by: org.netbeans.gradle.model.util.TransferableExceptionWrapper: java.net.SocketException: Malformed reply from SOCKS server

I have the following setting in my build.gradle :

repositories {

maven {

url “http://repo.jfrog.org/artifactory/repo1-cache

}

maven {

url “http://repo.jfrog.org/artifactory/jcenter-cache

}

}

I have also set the proxy configuration in %GRADLE_USER_HOME%\gradle.properties file :

systemProp.http.proxyUser=myUser

systemProp.http.proxyPassword=mySecret

systemProp.http.proxyHost=proxy.intranet

systemProp.http.proxyPort=8080

systemProp.http.nonProxyHosts=*.intranet|localhost

systemProp.https.proxyUser=myUser

systemProp.https.proxyPassword=mySecret

systemProp.https.proxyHost=proxy.intranet

systemProp.https.proxyPort=8080

systemProp.https.nonProxyHosts=*.intranet|localhost

Is there something special to care using gradle tooling API? I am wondering why the error mentions SOCKS server… Is the tooling API using the socks protocol?

FYI : I have opened an issue in the Netbeans plugin list too Issue 139


Netbeans Proxy and Gradle plugin
(ignace.martin) #2

I am still getting the error when no proxy is needed :

org.gradle.tooling.BuildException: Could not run build action using Gradle installation ‘C:\Tools\gradle-1.12’. > at org.gradle.tooling.internal.consumer.ResultHandlerAdapter.onFailure(ResultHandlerAdapter.java:53) > at org.gradle.tooling.internal.consumer.async.DefaultAsyncConsumerActionExecutor$1$1.run(DefaultAsyncConsumerActionExecutor.java:57) > at org.gradle.internal.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(DefaultExecutorFactory.java:64) > at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) > at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) > at java.lang.Thread.run(Thread.java:744) > at org.gradle.tooling.internal.consumer.BlockingResultHandler.getResult(BlockingResultHandler.java:46) > at org.gradle.tooling.internal.consumer.DefaultBuildActionExecuter.run(DefaultBuildActionExecuter.java:43) > at org.netbeans.gradle.model.GenericModelFetcher.getModels(GenericModelFetcher.java:166) > at org.netbeans.gradle.project.model.NbGradle18ModelLoader$ProjectModelFetcher.getModels(NbGradle18ModelLoader.java:374) > at org.netbeans.gradle.project.model.NbGradle18ModelLoader.loadModels(NbGradle18ModelLoader.java:79) > at org.netbeans.gradle.project.model.GradleModelLoader.loadModelWithProgress(GradleModelLoader.java:496) > at org.netbeans.gradle.project.model.GradleModelLoader.access$600(GradleModelLoader.java:57) > at org.netbeans.gradle.project.model.GradleModelLoader$6.run(GradleModelLoader.java:364) > at org.netbeans.gradle.project.tasks.GradleDaemonManager.runNonBlockingGradleTask(GradleDaemonManager.java:24) > at org.netbeans.gradle.project.tasks.GradleDaemonManager.access$100(GradleDaemonManager.java:14) > at org.netbeans.gradle.project.tasks.GradleDaemonManager$2.run(GradleDaemonManager.java:105) > at org.netbeans.gradle.project.tasks.GradleDaemonManager$3.run(GradleDaemonManager.java:130) > at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1432) > at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2042) >Caused by: org.gradle.internal.exceptions.LocationAwareException: A problem occurred configuring project ‘:irdlib’. > at org.gradle.initialization.DefaultExceptionAnalyser.transform(DefaultExceptionAnalyser.java:77) > at org.gradle.initialization.MultipleBuildFailuresExceptionAnalyser.transform(MultipleBuildFailuresExceptionAnalyser.java:47) > at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:115) > at org.gradle.initialization.DefaultGradleLauncher.getBuildAnalysis(DefaultGradleLauncher.java:92) > at org.gradle.launcher.exec.InProcessBuildActionExecuter$DefaultBuildController.configure(InProcessBuildActionExecuter.java:68) > at org.gradle.tooling.internal.provider.ClientProvidedBuildAction.run(ClientProvidedBuildAction.java:66) > at org.gradle.tooling.internal.provider.ClientProvidedBuildAction.run(ClientProvidedBuildAction.java:33) > at org.gradle.tooling.internal.provider.ConfiguringBuildAction.run(ConfiguringBuildAction.java:150) > at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:35) > at org.gradle.launcher.daemon.server.exec.ExecuteBuild.doBuild(ExecuteBuild.java:45) > at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:34) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.WatchForDisconnection.execute(WatchForDisconnection.java:42) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.ResetDeprecationLogger.execute(ResetDeprecationLogger.java:24) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.StartStopIfBuildAndStop.execute(StartStopIfBuildAndStop.java:33) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.ReturnResult.execute(ReturnResult.java:34) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:71) > at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:69) > at org.gradle.util.Swapper.swap(Swapper.java:38) > at org.gradle.launcher.daemon.server.exec.ForwardClientInput.execute(ForwardClientInput.java:69) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.LogToClient.doBuild(LogToClient.java:60) > at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:34) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.EstablishBuildEnvironment.doBuild(EstablishBuildEnvironment.java:60) > at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:34) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy$1.run(StartBuildOrRespondWithBusy.java:45) > at org.gradle.launcher.daemon.server.DaemonStateCoordinator.runCommand(DaemonStateCoordinator.java:186) > at org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy.doBuild(StartBuildOrRespondWithBusy.java:49) > at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:34) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.HandleStop.execute(HandleStop.java:36) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.DaemonHygieneAction.execute(DaemonHygieneAction.java:39) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.CatchAndForwardDaemonFailure.execute(CatchAndForwardDaemonFailure.java:32) > at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:125) > at org.gradle.launcher.daemon.server.exec.DefaultDaemonCommandExecuter.executeCommand(DefaultDaemonCommandExecuter.java:51) > at org.gradle.launcher.daemon.server.DefaultIncomingConnectionHandler$ConnectionWorker.handleCommand(DefaultIncomingConnectionHandler.java:155) > at org.gradle.launcher.daemon.server.DefaultIncomingConnectionHandler$ConnectionWorker.receiveAndHandleCommand(DefaultIncomingConnectionHandler.java:128) > at org.gradle.launcher.daemon.server.DefaultIncomingConnectionHandler$ConnectionWorker.run(DefaultIncomingConnectionHandler.java:116) > at org.gradle.internal.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(DefaultExecutorFactory.java:64) > at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) > at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) > at java.lang.Thread.run(Thread.java:662) >Caused by: org.gradle.api.ProjectConfigurationException: A problem occurred configuring project ‘:mylib’. > at org.gradle.configuration.project.LifecycleProjectEvaluator.addConfigurationFailure(LifecycleProjectEvaluator.java:79) > at org.gradle.configuration.project.LifecycleProjectEvaluator.evaluate(LifecycleProjectEvaluator.java:57) > at org.gradle.api.internal.project.AbstractProject.evaluate(AbstractProject.java:493) > at org.gradle.api.internal.project.AbstractProject.evaluate(AbstractProject.java:80) > at org.gradle.configuration.DefaultBuildConfigurer.configure(DefaultBuildConfigurer.java:31) > at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:142) > at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:113) > … 47 more >Caused by: org.gradle.api.artifacts.ResolveException: Could not resolve all dependencies for configuration ‘:irdlib:classpath’. > at org.gradle.api.internal.artifacts.ivyservice.DefaultLenientConfiguration.rethrowFailure(DefaultLenientConfiguration.java:52) > at org.gradle.api.internal.artifacts.ivyservice.DefaultResolvedConfiguration.rethrowFailure(DefaultResolvedConfiguration.java:36) > at org.gradle.api.internal.artifacts.ivyservice.SelfResolvingDependencyResolver$FilesAggregatingResolvedConfiguration.rethrowFailure(SelfResolvingDependencyResolver.java:110) > at org.gradle.api.internal.artifacts.ivyservice.ErrorHandlingArtifactDependencyResolver$ErrorHandlingResolvedConfiguration.rethrowFailure(ErrorHandlingArtifactDependencyResolver.java:180) > at org.gradle.api.internal.artifacts.configurations.DefaultConfiguration$ConfigurationFileCollection.getFiles(DefaultConfiguration.java:465) > at org.gradle.api.internal.artifacts.configurations.DefaultConfiguration.getFiles(DefaultConfiguration.java:202) > at org.gradle.api.internal.artifacts.configurations.DefaultConfiguration_Decorated.getFiles(Unknown Source) > at org.gradle.configuration.DefaultScriptPluginFactory$ScriptPluginImpl.apply(DefaultScriptPluginFactory.java:127) > at org.gradle.configuration.project.BuildScriptProcessor.execute(BuildScriptProcessor.java:40) > at org.gradle.configuration.project.BuildScriptProcessor.execute(BuildScriptProcessor.java:26) > at org.gradle.configuration.project.ConfigureActionsProjectEvaluator.evaluate(ConfigureActionsProjectEvaluator.java:34) > at org.gradle.configuration.project.LifecycleProjectEvaluator.evaluate(LifecycleProjectEvaluator.java:55) > … 52 more >Caused by: org.gradle.api.internal.artifacts.ivyservice.ModuleVersionResolveException: Could not resolve xmlunit:xmlunit:1.2. >Required by: >

FlexING:irdlib:unspecified > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.RepositoryChainDependencyResolver.resolve(RepositoryChainDependencyResolver.java:72) > at org.gradle.api.internal.artifacts.ivyservice.clientmodule.ClientModuleResolver.resolve(ClientModuleResolver.java:35) > at org.gradle.api.internal.artifacts.ivyservice.projectmodule.ProjectDependencyResolver.resolve(ProjectDependencyResolver.java:49) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.LazyDependencyToModuleResolver$AbstractVersionResolveResult.resolve(LazyDependencyToModuleResolver.java:69) > at org.gradle.api.internal.artifacts.ivyservice.resolveengine.DependencyGraphBuilder$ModuleVersionResolveState.resolve(DependencyGraphBuilder.java:655) > at org.gradle.api.internal.artifacts.ivyservice.resolveengine.DependencyGraphBuilder$ModuleVersionResolveState.getMetaData(DependencyGraphBuilder.java:666) > at org.gradle.api.internal.artifacts.ivyservice.resolveengine.DependencyGraphBuilder$DependencyEdge.calculateTargetConfigurations(DependencyGraphBuilder.java:340) > at org.gradle.api.internal.artifacts.ivyservice.resolveengine.DependencyGraphBuilder$DependencyEdge.attachToTargetConfigurations(DependencyGraphBuilder.java:314) > at org.gradle.api.internal.artifacts.ivyservice.resolveengine.DependencyGraphBuilder.traverseGraph(DependencyGraphBuilder.java:130) > at org.gradle.api.internal.artifacts.ivyservice.resolveengine.DependencyGraphBuilder.resolve(DependencyGraphBuilder.java:70) > at org.gradle.api.internal.artifacts.ivyservice.resolveengine.DefaultDependencyResolver$1.execute(DefaultDependencyResolver.java:116) > at org.gradle.api.internal.artifacts.ivyservice.resolveengine.DefaultDependencyResolver$1.execute(DefaultDependencyResolver.java:82) > at org.gradle.internal.Transformers$3.transform(Transformers.java:131) > at org.gradle.api.internal.artifacts.ivyservice.DefaultIvyContextManager.withIvy(DefaultIvyContextManager.java:61) > at org.gradle.api.internal.artifacts.ivyservice.DefaultIvyContextManager.withIvy(DefaultIvyContextManager.java:39) > at org.gradle.api.internal.artifacts.ivyservice.resolveengine.DefaultDependencyResolver.resolve(DefaultDependencyResolver.java:82) > at org.gradle.api.internal.artifacts.ivyservice.CacheLockingArtifactDependencyResolver$1.run(CacheLockingArtifactDependencyResolver.java:42) > at org.gradle.internal.Factories$1.create(Factories.java:22) > at org.gradle.cache.internal.DefaultCacheAccess.useCache(DefaultCacheAccess.java:187) > at org.gradle.cache.internal.DefaultCacheAccess.useCache(DefaultCacheAccess.java:175) > at org.gradle.cache.internal.DefaultPersistentDirectoryStore.useCache(DefaultPersistentDirectoryStore.java:106) > at org.gradle.cache.internal.DefaultCacheFactory$ReferenceTrackingCache.useCache(DefaultCacheFactory.java:193) > at org.gradle.api.internal.artifacts.ivyservice.DefaultCacheLockingManager.useCache(DefaultCacheLockingManager.java:65) > at org.gradle.api.internal.artifacts.ivyservice.CacheLockingArtifactDependencyResolver.resolve(CacheLockingArtifactDependencyResolver.java:40) > at org.gradle.api.internal.artifacts.ivyservice.SelfResolvingDependencyResolver.resolve(SelfResolvingDependencyResolver.java:45) > at org.gradle.api.internal.artifacts.ivyservice.ShortcircuitEmptyConfigsArtifactDependencyResolver.resolve(ShortcircuitEmptyConfigsArtifactDependencyResolver.java:55) > at org.gradle.api.internal.artifacts.ivyservice.ErrorHandlingArtifactDependencyResolver.resolve(ErrorHandlingArtifactDependencyResolver.java:47) > at org.gradle.api.internal.artifacts.ivyservice.DefaultConfigurationResolver.resolve(DefaultConfigurationResolver.java:46) > at org.gradle.api.internal.artifacts.configurations.DefaultConfiguration.resolveNow(DefaultConfiguration.java:240) > at org.gradle.api.internal.artifacts.configurations.DefaultConfiguration.getResolvedConfiguration(DefaultConfiguration.java:230) > at org.gradle.api.internal.artifacts.configurations.DefaultConfiguration_Decorated.getResolvedConfiguration(Unknown Source) > at org.gradle.api.internal.artifacts.configurations.DefaultConfiguration$ConfigurationFileCollection.getFiles(DefaultConfiguration.java:463) > … 59 more >Caused by: org.gradle.api.internal.externalresource.transport.http.HttpRequestException: Could not GET ‘http://vls.europe.intranet:8085/nexus/content/groups/public/xmlunit/xmlunit/1.2/xmlunit-1.2.pom’. > at org.gradle.api.internal.externalresource.transport.http.HttpClientHelper.performRequest(HttpClientHelper.java:80) > at org.gradle.api.internal.externalresource.transport.http.HttpClientHelper.performRawGet(HttpClientHelper.java:66) > at org.gradle.api.internal.externalresource.transport.http.HttpClientHelper.performGet(HttpClientHelper.java:70) > at org.gradle.api.internal.externalresource.transport.http.HttpResourceAccessor.getResource(HttpResourceAccessor.java:46) > at org.gradle.api.internal.externalresource.transport.http.HttpResourceAccessor.getResource(HttpResourceAccessor.java:32) > at org.gradle.api.internal.externalresource.transfer.ProgressLoggingExternalResourceAccessor.getResource(ProgressLoggingExternalResourceAccessor.java:38) > at org.gradle.api.internal.externalresource.transfer.DefaultCacheAwareExternalResourceAccessor.getResource(DefaultCacheAwareExternalResourceAccessor.java:60) > at org.gradle.api.internal.externalresource.transport.DefaultExternalResourceRepository.getResource(DefaultExternalResourceRepository.java:65) > at org.gradle.api.internal.artifacts.repositories.resolver.ExternalResourceResolver$ArtifactResolver.getResource(ExternalResourceResolver.java:579) > at org.gradle.api.internal.artifacts.repositories.resolver.ExternalResourceResolver$ArtifactResolver.findStaticResourceUsingPatterns(ExternalResourceResolver.java:564) > at org.gradle.api.internal.artifacts.repositories.resolver.ExternalResourceResolver$ArtifactResolver.resolveMetaDataArtifact(ExternalResourceResolver.java:548) > at org.gradle.api.internal.artifacts.repositories.resolver.ExternalResourceResolver.findMetaDataArtifact(ExternalResourceResolver.java:191) > at org.gradle.api.internal.artifacts.repositories.resolver.ExternalResourceResolver.resolveStaticDependency(ExternalResourceResolver.java:165) > at org.gradle.api.internal.artifacts.repositories.resolver.MavenResolver.getDependency(MavenResolver.java:83) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.CacheLockingModuleVersionRepository$2.run(CacheLockingModuleVersionRepository.java:54) > at org.gradle.internal.Factories$1.create(Factories.java:22) > at org.gradle.cache.internal.DefaultCacheAccess.longRunningOperation(DefaultCacheAccess.java:237) > at org.gradle.cache.internal.DefaultCacheAccess.longRunningOperation(DefaultCacheAccess.java:308) > at org.gradle.cache.internal.DefaultPersistentDirectoryStore.longRunningOperation(DefaultPersistentDirectoryStore.java:114) > at org.gradle.cache.internal.DefaultCacheFactory$ReferenceTrackingCache.longRunningOperation(DefaultCacheFactory.java:185) > at org.gradle.api.internal.artifacts.ivyservice.DefaultCacheLockingManager.longRunningOperation(DefaultCacheLockingManager.java:57) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.CacheLockingModuleVersionRepository.getDependency(CacheLockingModuleVersionRepository.java:52) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.CachingModuleVersionRepository.getDependency(CachingModuleVersionRepository.java:137) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.memcache.CachedRepository.getDependency(CachedRepository.java:74) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.RepositoryChainDependencyResolver$RepositoryResolveState$RemoteModuleAccess.getDependency(RepositoryChainDependencyResolver.java:216) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.RepositoryChainDependencyResolver$StaticVersionRepositoryResolveState.process(RepositoryChainDependencyResolver.java:228) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.RepositoryChainDependencyResolver$RepositoryResolveState.resolve(RepositoryChainDependencyResolver.java:182) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.RepositoryChainDependencyResolver.findLatestModule(RepositoryChainDependencyResolver.java:110) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.RepositoryChainDependencyResolver.findLatestModule(RepositoryChainDependencyResolver.java:86) > at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.RepositoryChainDependencyResolver.resolve(RepositoryChainDependencyResolver.java:61) > … 90 more >Caused by: java.net.SocketException: Malformed reply from SOCKS server > at java.net.SocksSocketImpl.readSocksReply(SocksSocketImpl.java:90) > at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:429) > at java.net.Socket.connect(Socket.java:529) > at org.apache.http.conn.scheme.PlainSocketFactory.connectSocket(PlainSocketFactory.java:127) > at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:180) > at org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedClientConnectionImpl.java:294) > at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:640) > at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:479) > at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:906) > at org.apache.http.impl.client.DecompressingHttpClient.execute(DecompressingHttpClient.java:137) > at org.apache.http.impl.client.DecompressingHttpClient.execute(DecompressingHttpClient.java:118) > at org.gradle.api.internal.externalresource.transport.http.HttpClientHelper.performHttpRequest(HttpClientHelper.java:111) > at org.gradle.api.internal.externalresource.transport.http.HttpClientHelper.executeGetOrHead(HttpClientHelper.java:87) > at org.gradle.api.internal.externalresource.transport.http.HttpClientHelper.performRequest(HttpClientHelper.java:78) > … 119 more

Looking at this post it seems that “java.net.Socket always uses a proxy when a default ProxySelector is set” and the solution would be to set the default to null :

ProxySelector.setDefault(null);


(ignace.martin) #3

I have tried several solutions without success… I am still blocked with this issue and I am more and more convinced that the problem lies in the fact that the tooling API at a certain point is not using the proxy settings in gradle.properties.

Clearly, it works with command line and blocks with the Netbeans IDE plugin. It was working before we switched to the new version of the plugin using the tooling API.

It seems that I am not the only one to get this problem cf this link.

Could you raise an issue on that point? Thanks in advance


(ignace.martin) #4

I found a clue : setting the --debug mode, It seems that for the plugin project reload, the proxy settings of Netbeans are used, not the ones in gradle.properties.


(Radim Kubacki) #5

Oh yes, NetBeans reads system proxy settings from a registry in its launcher and sets a

java.net.ProxySelector

and/or some system properties and/or environment variables to make sure java.net package uses your proxy. Through env var or system proxy it gets propagated to Gradle daemon (I think the former but I am not sure at the moment). You can simply turn it off in IDE options dialog.