Skip to content

Instantly share code, notes, and snippets.

@muuki88
Created July 31, 2016 11:51
Show Gist options
  • Save muuki88/bd047a853ac32b1cb57743df7b600a7d to your computer and use it in GitHub Desktop.
Save muuki88/bd047a853ac32b1cb57743df7b600a7d to your computer and use it in GitHub Desktop.
package net.gutefrage
import com.twitter.finagle.Dtab
/**
* Holds different delegation tables
*/
object Dtabs {
def init(): Unit = {
Dtab.base = base
}
/**
* base dtab to resolve requests on your local system
*/
val base = Dtab.read(
"""|/zk## => /$/com.twitter.serverset;
|/zk# => /zk##/127.0.0.1:2181;
|/s# => /zk#/service;
|/env => /s#/local;
|/s => /env;""".stripMargin)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment