aboutsummaryrefslogtreecommitdiff
path: root/examples/fork-example/Main.scala
diff options
context:
space:
mode:
Diffstat (limited to 'examples/fork-example/Main.scala')
-rw-r--r--examples/fork-example/Main.scala29
1 files changed, 29 insertions, 0 deletions
diff --git a/examples/fork-example/Main.scala b/examples/fork-example/Main.scala
new file mode 100644
index 0000000..2ce5af8
--- /dev/null
+++ b/examples/fork-example/Main.scala
@@ -0,0 +1,29 @@
+package cbt_examples.fork_example
+
+import akka.http.scaladsl.server._
+import akka.http.scaladsl.model._
+import akka.http.scaladsl.server.Directives._
+import akka.http.scaladsl.settings._
+
+object Service extends HttpApp with App {
+ // should all appear in separate lines
+ System.out.println("HelloHello")
+ System.err.println("HelloHello")
+ System.out.println("HelloHello")
+ System.err.println("HelloHello")
+ System.out.println("HelloHello")
+ System.err.println("HelloHello")
+ System.out.println("HelloHello")
+ System.err.println("HelloHello")
+ System.out.println("HelloHello")
+ System.err.println("HelloHello")
+
+ override protected def route =
+ path("test") {
+ get {
+ complete(HttpResponse())
+ }
+ }
+
+ startServer("localhost", 8080)
+}