diff --git a/.github/workflows/check-pr.yaml b/.github/workflows/check-pr.yaml index b14e3f1e00..3bc81c7e95 100644 --- a/.github/workflows/check-pr.yaml +++ b/.github/workflows/check-pr.yaml @@ -15,7 +15,7 @@ jobs: - uses: actions/setup-java@v3 with: distribution: 'zulu' - java-version: '8' + java-version: '11' - name: Cache SBT uses: actions/cache@v3 with: diff --git a/README.md b/README.md index b534ebb95a..7776c20a6f 100644 --- a/README.md +++ b/README.md @@ -58,17 +58,17 @@ A quick introduction of the minimal setup you need to get a running node. Linux systems: ```bash sudo apt-get update -sudo apt-get install openjdk-8-jre +sudo apt-get install openjdk-11-jre java -jar node/target/waves-all*.jar path/to/config/waves-{network}.conf ``` Mac systems (assuming already installed homebrew): ```bash -brew cask install adoptopenjdk/openjdk/adoptopenjdk8 +brew cask install adoptopenjdk/openjdk/adoptopenjdk11 java -jar node/target/waves-all*.jar path/to/config/waves-{network}.conf ``` -Windows systems (assuming already installed OpenJDK 8): +Windows systems (assuming already installed OpenJDK 11): ```bash java -jar node/target/waves-all*.jar path/to/config/waves-{network}.conf ``` @@ -97,9 +97,9 @@ To build and test this project, you will have to follow these steps: ```bash sudo apt-get update -sudo apt-get install openjdk-8-jre # Ubuntu +sudo apt-get install openjdk-11-jre # Ubuntu # or -# brew cask install adoptopenjdk/openjdk/adoptopenjdk8 # Mac +# brew cask install adoptopenjdk/openjdk/adoptopenjdk11 # Mac ``` - Install SBT (Scala Build Tool) diff --git a/benchmark/build.sbt b/benchmark/build.sbt index fb9b5a66ff..c2e086488d 100644 --- a/benchmark/build.sbt +++ b/benchmark/build.sbt @@ -1,6 +1,6 @@ enablePlugins(JmhPlugin) -Jmh / version := "1.33" +Jmh / version := "1.37" libraryDependencies ++= Seq( "org.scodec" %% "scodec-core" % "1.11.10", diff --git a/build.sbt b/build.sbt index a3a14508e4..7f4f492311 100644 --- a/build.sbt +++ b/build.sbt @@ -13,7 +13,7 @@ enablePlugins(GitVersioning) git.uncommittedSignifier := Some("DIRTY") git.useGitDescribe := true ThisBuild / git.useGitDescribe := true -ThisBuild / PB.protocVersion := "3.24.4" // https://protobuf.dev/support/version-support/#java +ThisBuild / PB.protocVersion := "3.25.1" // https://protobuf.dev/support/version-support/#java lazy val lang = crossProject(JSPlatform, JVMPlatform) diff --git a/docker/node-sbt-builder.Dockerfile b/docker/node-sbt-builder.Dockerfile index 038589c20b..7707e3f852 100644 --- a/docker/node-sbt-builder.Dockerfile +++ b/docker/node-sbt-builder.Dockerfile @@ -1,4 +1,4 @@ -FROM eclipse-temurin:8-jdk-jammy +FROM eclipse-temurin:11-jdk-jammy ARG WAVES_VERSION ARG SBT_VERSION diff --git a/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/BinaryOperation.scala b/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/BinaryOperation.scala index 9adfa10697..a552017657 100644 --- a/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/BinaryOperation.scala +++ b/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/BinaryOperation.scala @@ -2,6 +2,7 @@ package com.wavesplatform.lang.v1.parser import com.wavesplatform.lang.v1.parser.Expressions.* import fastparse.* +import fastparse.MultiLineWhitespace.* sealed abstract class BinaryOperation { val func: String diff --git a/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/Parser.scala b/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/Parser.scala index 0a61ef2788..45667b8781 100644 --- a/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/Parser.scala +++ b/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/Parser.scala @@ -139,8 +139,7 @@ class Parser(stdLibVersion: StdLibVersion)(implicit offset: LibrariesOffset) { } def invalid[A: P]: P[INVALID] = { - import fastparse.NoWhitespace.* - P(Index ~~ CharPred(_ != '\n').rep(1) ~~ Index) + P(Index ~~ CharPred(_ != '\n').repX(1) ~~ Index) .map { case (start, end) => INVALID(Pos(start, end), "can't parse the expression") } diff --git a/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/UnaryOperation.scala b/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/UnaryOperation.scala index 2e1a999d2e..dd0496cdf4 100644 --- a/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/UnaryOperation.scala +++ b/lang/shared/src/main/scala/com/wavesplatform/lang/v1/parser/UnaryOperation.scala @@ -3,6 +3,7 @@ package com.wavesplatform.lang.v1.parser import com.wavesplatform.lang.v1.parser.Expressions.* import com.wavesplatform.lang.v1.parser.Parser.LibrariesOffset import fastparse.* +import fastparse.MultiLineWhitespace.* sealed abstract class UnaryOperation { val func: String diff --git a/node/build.sbt b/node/build.sbt index 6317232b8c..334c0ba084 100644 --- a/node/build.sbt +++ b/node/build.sbt @@ -155,7 +155,7 @@ inConfig(Debian)( maintainer := "com.wavesplatform", packageSource := sourceDirectory.value / "package", linuxStartScriptTemplate := (packageSource.value / "systemd.service").toURI.toURL, - debianPackageDependencies += "java8-runtime-headless", + debianPackageDependencies += "java11-runtime-headless", maintainerScripts := maintainerScriptsFromDirectory(packageSource.value / "debian", Seq("postinst", "postrm", "prerm")) ) ) diff --git a/project/Dependencies.scala b/project/Dependencies.scala index bb0e4980c3..75ed55e7d8 100644 --- a/project/Dependencies.scala +++ b/project/Dependencies.scala @@ -8,15 +8,15 @@ object Dependencies { private[this] val protoSchemasLib = "com.wavesplatform" % "protobuf-schemas" % "1.5.1-SNAPSHOT" classifier "protobuf-src" intransitive () - private def akkaModule(module: String) = "com.typesafe.akka" %% s"akka-$module" % "2.6.21" + private def akkaModule(module: String) = "com.typesafe.akka" %% s"akka-$module" % "2.8.5" - private def akkaHttpModule(module: String) = "com.typesafe.akka" %% module % "10.2.10" + private def akkaHttpModule(module: String) = "com.typesafe.akka" %% module % "10.5.3" - private def kamonModule(module: String) = "io.kamon" %% s"kamon-$module" % "2.6.5" + private def kamonModule(module: String) = "io.kamon" %% s"kamon-$module" % "2.6.6" private def jacksonModule(group: String, module: String) = s"com.fasterxml.jackson.$group" % s"jackson-$module" % "2.15.3" - private def web3jModule(module: String) = "org.web3j" % module % "4.9.8" // https://github.com/web3j/web3j/issues/1907 + private def web3jModule(module: String) = "org.web3j" % module % "4.9.8" // 4.10+ requires Java 17 https://github.com/web3j/web3j/issues/1907 def monixModule(module: String): Def.Initialize[ModuleID] = Def.setting("io.monix" %%% s"monix-$module" % "3.4.1") @@ -26,21 +26,21 @@ object Dependencies { val googleGuava = "com.google.guava" % "guava" % "32.1.3-jre" val kamonCore = kamonModule("core") val machinist = "org.typelevel" %% "machinist" % "0.6.8" - val logback = "ch.qos.logback" % "logback-classic" % "1.3.11" // 1.4.x and later is built for Java 11 + val logback = "ch.qos.logback" % "logback-classic" % "1.4.11" // 1.4.x and later is built for Java 11 val janino = "org.codehaus.janino" % "janino" % "3.1.10" val asyncHttpClient = "org.asynchttpclient" % "async-http-client" % "2.12.3" val curve25519 = "com.wavesplatform" % "curve25519-java" % "0.6.6" - val nettyHandler = "io.netty" % "netty-handler" % "4.1.100.Final" + val nettyHandler = "io.netty" % "netty-handler" % "4.1.101.Final" val shapeless = Def.setting("com.chuusai" %%% "shapeless" % "2.3.10") - val playJson = "com.typesafe.play" %% "play-json" % "2.9.4" // 2.10.x and later is built for Java 11 + val playJson = "com.typesafe.play" %% "play-json" % "2.10.3" // 2.10.x and later is built for Java 11 val scalaTest = "org.scalatest" %% "scalatest" % "3.2.17" % Test - val scalaJsTest = Def.setting("com.lihaoyi" %%% "utest" % "0.8.1" % Test) + val scalaJsTest = Def.setting("com.lihaoyi" %%% "utest" % "0.8.2" % Test) - val sttp3 = "com.softwaremill.sttp.client3" % "core_2.13" % "3.5.2" // 3.6.x and later is built for Java 11 - val sttp3Monix = "com.softwaremill.sttp.client3" %% "monix" % "3.5.2" + val sttp3 = "com.softwaremill.sttp.client3" % "core_2.13" % "3.9.1" // 3.6.x and later is built for Java 11 + val sttp3Monix = "com.softwaremill.sttp.client3" %% "monix" % "3.9.1" val bouncyCastleProvider = "org.bouncycastle" % s"bcprov-jdk15on" % "1.70" @@ -59,9 +59,9 @@ object Dependencies { // explicit dependency can likely be removed when monix 3 is released monixModule("eval").value, "org.typelevel" %%% s"cats-core" % "2.10.0", - "com.lihaoyi" %%% "fastparse" % "2.3.3", + "com.lihaoyi" %%% "fastparse" % "3.0.2", shapeless.value, - "org.typelevel" %%% "cats-mtl" % "1.3.1", + "org.typelevel" %%% "cats-mtl" % "1.4.0", "ch.obermuhlner" % "big-math" % "2.3.2", googleGuava, // BaseEncoding.base16() curve25519, @@ -74,7 +74,7 @@ object Dependencies { lazy val it = scalaTest +: Seq( logback, "com.spotify" % "docker-client" % "8.16.0", - "com.fasterxml.jackson.dataformat" % "jackson-dataformat-properties" % "2.14.2", + "com.fasterxml.jackson.dataformat" % "jackson-dataformat-properties" % "2.16.0", asyncHttpClient ).map(_ % Test) @@ -97,9 +97,9 @@ object Dependencies { akkaModule("slf4j") % Runtime ) - private val rocksdb = "org.rocksdb" % "rocksdbjni" % "8.5.4" + private val rocksdb = "org.rocksdb" % "rocksdbjni" % "8.8.1" - private val scalapbJson = "com.thesamet.scalapb" %% "scalapb-json4s" % "0.11.1" + private val scalapbJson = "com.thesamet.scalapb" %% "scalapb-json4s" % "0.12.1" lazy val node = Def.setting( Seq( @@ -127,14 +127,14 @@ object Dependencies { nettyHandler, "com.typesafe.scala-logging" %% "scala-logging" % "3.9.5", "eu.timepit" %% "refined" % "0.11.0" exclude ("org.scala-lang.modules", "scala-xml_2.13"), - "com.esaulpaugh" % "headlong" % "9.4.0", + "com.esaulpaugh" % "headlong" % "10.0.1", web3jModule("abi"), akkaModule("testkit") % Test, akkaHttpModule("akka-http-testkit") % Test, ) ++ test ++ console ++ logDeps ++ protobuf.value ++ langCompilerPlugins.value ) - val gProto = "com.google.protobuf" % "protobuf-java" % "3.24.4" + val gProto = "com.google.protobuf" % "protobuf-java" % "3.25.1" lazy val scalapbRuntime = Def.setting( Seq( @@ -162,8 +162,8 @@ object Dependencies { scalapbJson, // https://github.com/netty/netty/wiki/Native-transports // "io.netty" % "netty-transport-native-epoll" % "4.1.79.Final" classifier "linux-x86_64", - "com.github.ben-manes.caffeine" % "caffeine" % "3.1.2", - "net.logstash.logback" % "logstash-logback-encoder" % "7.2" % Runtime, + "com.github.ben-manes.caffeine" % "caffeine" % "3.1.8", + "net.logstash.logback" % "logstash-logback-encoder" % "7.4" % Runtime, "org.ehcache" % "sizeof" % "0.4.3", // Weighing caches kamonModule("caffeine"), kamonModule("prometheus"), @@ -171,9 +171,9 @@ object Dependencies { sttp3Monix, "org.scala-lang.modules" %% "scala-xml" % "2.2.0", // JUnit reports akkaHttpModule("akka-http-testkit") % Test, - "com.softwaremill.diffx" %% "diffx-core" % "0.8.3" % Test, - "com.softwaremill.diffx" %% "diffx-scalatest-should" % "0.8.3" % Test, - "io.grpc" % "grpc-inprocess" % scalapb.compiler.Version.grpcJavaVersion % Test + "com.softwaremill.diffx" %% "diffx-core" % "0.9.0" % Test, + "com.softwaremill.diffx" %% "diffx-scalatest-should" % "0.9.0" % Test, + "io.grpc" % "grpc-inprocess" % "1.59.0" % Test ) ++ Dependencies.console ++ Dependencies.logDeps ++ Dependencies.test ) @@ -189,5 +189,5 @@ object Dependencies { // https://github.com/sbt/sbt-javaagent#scopes // dist (only sbt-native-packager), because causes using logs before needed, so System.setProperty in RideRunnerWithPreparedStateApp has no effect. lazy val kanela = - Seq("io.kamon" % "kanela-agent" % "1.0.17" % "dist") + Seq("io.kamon" % "kanela-agent" % "1.0.18" % "dist") } diff --git a/project/plugins.sbt b/project/plugins.sbt index 94eeb1a889..0d0b022093 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -9,7 +9,7 @@ addSbtPlugin("com.thesamet" % "sbt-protoc" % "1.0.6") libraryDependencies += "com.thesamet.scalapb" %% "compilerplugin" % "0.11.14" Seq( - "com.eed3si9n" % "sbt-assembly" % "2.1.3", + "com.eed3si9n" % "sbt-assembly" % "2.1.5", "com.github.sbt" % "sbt-native-packager" % "1.9.16", "se.marcuslonnberg" % "sbt-docker" % "1.11.0", "org.scala-js" % "sbt-scalajs" % "1.14.0", @@ -20,7 +20,7 @@ Seq( ).map(addSbtPlugin) libraryDependencies ++= Seq( - "com.fasterxml.jackson.module" %% "jackson-module-scala" % "2.15.3", + "com.fasterxml.jackson.module" %% "jackson-module-scala" % "2.16.0", "org.hjson" % "hjson" % "3.1.0", "org.vafer" % "jdeb" % "1.10" artifacts Artifact("jdeb", "jar", "jar"), "org.slf4j" % "jcl-over-slf4j" % "2.0.9",