Getting error in Custom Java code

0
Hi All, I’m getting this error in Eclipse while debugging  Java action, Exception in thread "main" java.lang.NoSuchMethodError: java.nio.file.Path.of(Ljava/lang/String;[Ljava/lang/String;)Ljava/nio/file/Path;     at com.mendix.container.config.package$.toPath(package.scala:33)     at com.mendix.container.config.ConfigFromEnvironment$.$anonfun$readMxInstallPath$1(ConfigFromEnvironment.scala:66)     at cats.data.Validated.andThen(Validated.scala:264)     at com.mendix.container.config.ConfigFromEnvironment$.readMxInstallPath(ConfigFromEnvironment.scala:66)     at com.mendix.container.config.ConfigFromEnvironment$.apply(ConfigFromEnvironment.scala:58)     at com.mendix.container.boot.Main$.delayedEndpoint$com$mendix$container$boot$Main$1(Main.scala:13)     at com.mendix.container.boot.Main$delayedInit$body.apply(Main.scala:10)     at scala.Function0.apply$mcV$sp(Function0.scala:39)     at scala.Function0.apply$mcV$sp$(Function0.scala:39)     at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:17)     at scala.App.$anonfun$main$1$adapted(App.scala:80)     at scala.collection.immutable.List.foreach(List.scala:392)     at scala.App.main(App.scala:80)     at scala.App.main$(App.scala:78)     at com.mendix.container.boot.Main$.main(Main.scala:10)     at com.mendix.container.boot.Main.main(Main.scala) Can anyone help me I’m not understanding how to solve this one? Thanks in Advance.      
asked
1 answers
1

I think you need Java 11 and you are using Java 8.

The “of” method is available in 11. As per Mendix system requirements, to run Mendix 8 you need Java 11. Read the system requirements of Mendix. 

https://docs.mendix.com/refguide/system-requirements

https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/file/Path.html

answered