Browse Source

Bump Finch to 0.25 (#4144)

Vladimir Kostyukov 6 years ago
parent
commit
a294befec0

+ 3 - 3
frameworks/Scala/finch/build.sbt

@@ -1,12 +1,12 @@
-lazy val finchVersion = "0.23.0"
+lazy val finchVersion = "0.25.0"
 
 name := """techempower-benchmarks-finch"""
 version := finchVersion
 scalaVersion := "2.12.5"
 
 libraryDependencies ++= Seq(
-  "com.github.finagle" %% "finch-arrows-core" % finchVersion,
-  "com.github.finagle" %% "finch-arrows-circe" % finchVersion
+  "com.github.finagle" %% "finchx-core" % finchVersion,
+  "com.github.finagle" %% "finchx-circe" % finchVersion
 )
 
 assemblyJarName in assembly := "finch-benchmark.jar"

+ 4 - 4
frameworks/Scala/finch/src/main/scala/Main.scala

@@ -5,20 +5,20 @@ import com.twitter.finagle.Service
 import com.twitter.finagle.stack.nilStack
 import com.twitter.util.Await
 
+import cats.effect.IO
 import io.circe.Json
 import io.finch._
-import io.finch.syntax._
 import io.finch.circe._
 
-object Main extends App {
+object Main extends App with Endpoint.Module[IO] {
 
   val helloWorld: Buf = Buf.Utf8("Hello, World!")
 
-  val json: Endpoint[Json] = get("json") {
+  val json: Endpoint[IO, Json] = get("json") {
     Ok(Json.obj("message" -> Json.fromString("Hello, World!")))
   }
 
-  val plaintext: Endpoint[Buf] = get("plaintext") {
+  val plaintext: Endpoint[IO, Buf] = get("plaintext") {
     Ok(helloWorld)
   }