Permalink
Browse files

added depth arg to UrlResolver

  • Loading branch information...
1 parent 7dae582 commit 64073e22dcdaa514a0b689a3f0bd4f317b3dea5e Gregg committed May 10, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/main/scala/com/janxspirit/yltib/UrlResolver.scala
@@ -9,7 +9,7 @@ import akka.util.duration._
import java.util.concurrent.Executors
-class UrlResolver(poolSize: Int) {
+class UrlResolver(poolSize: Int, linkResolveDepth: Int=3) {
val ec = ExecutionContext.fromExecutorService(
Executors.newCachedThreadPool()
)
@@ -20,7 +20,7 @@ class UrlResolver(poolSize: Int) {
def resolveUrls(urls: List[String]) = {
val futures = urls.map(url => {
- router.ask(ResolveUrl(url, 10))(30 seconds)
+ router.ask(ResolveUrl(url, linkResolveDepth))(30 seconds)
})
futures.map(fut => {

0 comments on commit 64073e2

Please sign in to comment.