File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed
Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -94,15 +94,13 @@ you can then do:
9494
9595``` scala
9696import upperbound ._ , syntax .rate ._
97- import fs2 .StreamApp
98- import fs2 .StreamApp .ExitCode
9997import fs2 .Stream
100- import cats .effect .IO
98+ import cats .effect .{ IO , IOApp , ExitCode }
10199import scala .concurrent .ExecutionContext .Implicits .global
102100import scala .concurrent .duration ._
103101
104- object Main extends StreamApp [ IO ] {
105- override def stream (args : List [String ], requestShutdown : IO [ Unit ]) : Stream [ IO , ExitCode ] =
102+ object Main extends IOApp {
103+ override def run (args : List [String ]) : IO [ ExitCode ] =
106104 for {
107105 limiter <- Limiter .stream[IO ](100 every 1 .minute)
108106 res <- Stream .eval(YourWholeProgram (limiter.worker).doStuff).as(ExitCode .Success )
You can’t perform that action at this time.
0 commit comments