Esri / arcgis-runtime-demo-java

Demo applications built with the ArcGIS Runtime SDK for Java - a SDK to create rich client mapping applications.
Apache License 2.0
16 stars 28 forks source link

Could not get unknown property 'run' for project ':scene:calculate-distance-3D' of type org.gradle.api.Project. #1

Closed yannickbruyninckx closed 7 years ago

yannickbruyninckx commented 7 years ago

Hello,

I would like to create a Java project using the arcgis sdk to fetch data via an arcgis API and display it in a browser. I know Java and I'm currently working with Intellij and Java8. I'm not familiar at all with Gradle however.

I tried your tutorial and I:

And ended up with the folowing stacktrace. Can you tell me what I am doing wrong? Also, maybe I'm not aving the right approach to try the API. Maybe there is a better approach? Finally, I'm far more familiar using Maen. Is there an equivalent arcgis-runtime-demo-java with Maven configurations instead of radle?

Thanks a lot. Yannick.


The stack trace:

$ gradle build --stacktrace

FAILURE: Build failed with an exception.

* Where:
Build file 'D:\Worskpace\arcgis-runtime-samples-java\scene\build.gradle' line: 3

* What went wrong:
A problem occurred evaluating project ':scene'.  
> Could not get unknown property 'run' for project ':scene:calculate-distance-3D' of type org.gradle.api.Project.

* Try:
Run with --info or --debug option to get more log output.

* Exception is:
org.gradle.api.GradleScriptException: A problem occurred evaluating project ':scene'.
        at org.gradle.groovy.scripts.internal.DefaultScriptRunnerFactory$ScriptRunnerImpl.run(DefaultScriptRunnerFactory.java:92)
        at org.gradle.configuration.DefaultScriptPluginFactory$ScriptPluginImpl$2.run(DefaultScriptPluginFactory.java:176)
        at org.gradle.configuration.ProjectScriptTarget.addConfiguration(ProjectScriptTarget.java:77)
        at org.gradle.configuration.DefaultScriptPluginFactory$ScriptPluginImpl.apply(DefaultScriptPluginFactory.java:181)
        at org.gradle.configuration.project.BuildScriptProcessor.execute(BuildScriptProcessor.java:38)
        at org.gradle.configuration.project.BuildScriptProcessor.execute(BuildScriptProcessor.java:25)
        at org.gradle.configuration.project.ConfigureActionsProjectEvaluator.evaluate(ConfigureActionsProjectEvaluator.java:34)
        at org.gradle.configuration.project.LifecycleProjectEvaluator.evaluate(LifecycleProjectEvaluator.java:55)
        at org.gradle.api.internal.project.DefaultProject.evaluate(DefaultProject.java:573)
        at org.gradle.api.internal.project.DefaultProject.evaluate(DefaultProject.java:125)
        at org.gradle.execution.TaskPathProjectEvaluator.configureHierarchy(TaskPathProjectEvaluator.java:47)
        at org.gradle.configuration.DefaultBuildConfigurer.configure(DefaultBuildConfigurer.java:38)
        at org.gradle.initialization.DefaultGradleLauncher$2.run(DefaultGradleLauncher.java:151)
        at org.gradle.internal.Factories$1.create(Factories.java:22)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:91)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:53)
        at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:148)
        at org.gradle.initialization.DefaultGradleLauncher.access$200(DefaultGradleLauncher.java:33)
        at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:112)
        at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:106)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:91)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:63)
        at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:106)
        at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLauncher.java:92)
        at org.gradle.launcher.exec.GradleBuildController.run(GradleBuildController.java:66)
        at org.gradle.tooling.internal.provider.ExecuteBuildActionRunner.run(ExecuteBuildActionRunner.java:28)
        at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
        at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:41)
        at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:26)
        at org.gradle.tooling.internal.provider.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:79)
        at org.gradle.tooling.internal.provider.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:51)
        at org.gradle.launcher.daemon.server.exec.ExecuteBuild.doBuild(ExecuteBuild.java:59)
        at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.WatchForDisconnection.execute(WatchForDisconnection.java:47)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.ResetDeprecationLogger.execute(ResetDeprecationLogger.java:26)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.RequestStopIfSingleUsedDaemon.execute(RequestStopIfSingleUsedDaemon.java:34)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:74)
        at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:72)
        at org.gradle.util.Swapper.swap(Swapper.java:38)
        at org.gradle.launcher.daemon.server.exec.ForwardClientInput.execute(ForwardClientInput.java:72)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.LogAndCheckHealth.execute(LogAndCheckHealth.java:55)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.LogToClient.doBuild(LogToClient.java:60)
        at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.EstablishBuildEnvironment.doBuild(EstablishBuildEnvironment.java:72)
        at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.HintGCAfterBuild.execute(HintGCAfterBuild.java:44)
        at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
        at org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy$1.run(StartBuildOrRespondWithBusy.java:50)
        at org.gradle.launcher.daemon.server.DaemonStateCoordinator$1.run(DaemonStateCoordinator.java:293)
        at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:54)
        at org.gradle.internal.concurrent.StoppableExecutorImpl$1.run(StoppableExecutorImpl.java:40)
Caused by: groovy.lang.MissingPropertyException: Could not get unknown property 'run' for project ':scene:calculate-distance-3D' of type org.gradle.api.Project.
        at org.gradle.internal.metaobject.AbstractDynamicObject.getMissingProperty(AbstractDynamicObject.java:85)
        at org.gradle.internal.metaobject.AbstractDynamicObject.getProperty(AbstractDynamicObject.java:62)
        at org.gradle.api.internal.project.DefaultProject_Decorated.getProperty(Unknown Source)
        at build_dyzp6uy5p1kkos3e7dkgzmljd$_run_closure1.doCall(D:\Worskpace\arcgis-runtime-samples-java\scene\build.gradle:3)
        at org.gradle.api.internal.ClosureBackedAction.execute(ClosureBackedAction.java:70)
        at org.gradle.util.ConfigureUtil.configureTarget(ConfigureUtil.java:160)
        at org.gradle.util.ConfigureUtil.configureSelf(ConfigureUtil.java:136)
        at org.gradle.api.internal.AbstractTask.configure(AbstractTask.java:519)
        at org.gradle.api.internal.project.DefaultProject.task(DefaultProject.java:960)
        at org.gradle.internal.metaobject.BeanDynamicObject$MetaClassAdapter.invokeMethod(BeanDynamicObject.java:382)
        at org.gradle.internal.metaobject.BeanDynamicObject.invokeMethod(BeanDynamicObject.java:170)
        at org.gradle.internal.metaobject.CompositeDynamicObject.invokeMethod(CompositeDynamicObject.java:96)
        at org.gradle.internal.metaobject.MixInClosurePropertiesAsMethodsDynamicObject.invokeMethod(MixInClosurePropertiesAsMethodsDynamicObject.java:30)
        at org.gradle.internal.metaobject.AbstractDynamicObject.invokeMethod(AbstractDynamicObject.java:163)
        at org.gradle.groovy.scripts.BasicScript.methodMissing(BasicScript.java:83)
        at build_dyzp6uy5p1kkos3e7dkgzmljd.run(D:\Worskpace\arcgis-runtime-samples-java\scene\build.gradle:1)
        at org.gradle.groovy.scripts.internal.DefaultScriptRunnerFactory$ScriptRunnerImpl.run(DefaultScriptRunnerFactory.java:90)
        ... 58 more

BUILD FAILED

Total time: 2.927 secs

The imported jars:

Classes C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\apache-mime4j.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\ArcGIS_Runtime_Java.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\ArcGIS_Runtime_Java_Toolkit.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\commons-codec.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\commons-logging.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\httpclient.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\httpcore.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\httpmime.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\jackson-core-lgpl.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\jackson-mapper-lgpl.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\jcifs.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\jcommon.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\jfreechart.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\json.jar Sources C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\samples\samplecode\src C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\jars\ArcGIS_Runtime_Java_Toolkit-sources.jar JavaDocs C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\help\api reference\ArcGIS_Runtime_Java-javadoc.jar C:\Program Files (x86)\ArcGIS SDKs\java10.2.4\sdk\help\api reference\ArcGIS_Runtime_Java_Toolkit-javadoc.jar

yannickbruyninckx commented 7 years ago

sorry, wrong github repo :D

mbcoder commented 7 years ago

Yannick,

If you have questions about the 10.2.4 release then post a question on the forum linked on this page https://developers.arcgis.com/java/

If you are starting a new runtime project, then take a look at the Beta release we have out at the moment. This will be very shortly be released as a non beta product. The runtime SDKs are really for developing native applications. If you are wanting to write a web application then you should consider using the JavaScript API.

Good luck!

Mark