- Install IntelliJ + Scala Plugin
- Don’t do the Coursera courses yet.
- Don’t do the “red book” Functional Programming in Scala yet.
- Do: http://underscore.io/books/
- Essential Scala
- Essential Play
- Essential Slick
- Do Scala for the Impatient: https://www.amazon.com/Scala-Impatient-Cay-S-Horstmann/dp/0321774094
- The Neophyte’s Guide to Scala http://danielwestheide.com/scala/neophytes.html
Getting this?
java.lang.NoSuchMethodError: play.api.libs.iteratee.Execution$Implicits$.trampoline()Lscala/concurrent/ExecutionContext;
Is your build.sbt including a dependency like this?
"org.reactivemongo" %% "play2-reactivemongo" % "0.12.6-play24"
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import com.vimeo.networking._ | |
| import com.vimeo.networking.model._ | |
| import com.vimeo.networking.model.error.VimeoError; | |
| import com.vimeo.networking.callbacks._ | |
| import java.io.File | |
| import scala.concurrent.{Future, Promise} | |
| import scala.reflect.ClassTag | |
| import scala.reflect._ | |
| import okhttp3.CacheControl |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Delete any old test index | |
| DELETE example_copy | |
| # Create index with appropriate mappings/settings | |
| # Note that the pattern is meant to not match anything so that the entire field is taken as the "token" | |
| PUT example_copy | |
| { | |
| "settings": { | |
| "analysis": { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import java.io.FileOutputStream | |
| import java.nio.file.{Files, Paths, Path, FileVisitResult} | |
| import java.nio.file.attribute.BasicFileAttributes | |
| import java.nio.file.SimpleFileVisitor | |
| def autoClosing[C <: Closeable, T](closeable: C)(c: C => T) = { | |
| try { | |
| c(closeable) | |
| } finally { | |
| closeable.close() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package module | |
| /* Don't import ._ because there's naming conflicts between sttp and ws for request bodies and whatnot */ | |
| import play.api.libs.ws | |
| import ws.{ WSClient, WSClientConfig, WSRequest, WSResponse } | |
| import play.api.libs.iteratee.Enumerator | |
| import com.softwaremill.sttp._ | |
| import com.softwaremill.sttp.internal.SttpFile | |
| import com.softwaremill.sttp.monadSyntax._ |
OlderNewer