Instantly share code, notes, and snippets.

Embed
What would you like to do?
class ZookeeperService(hostInfo: HostInfo)
extends ClusterService with EmbeddedZookeeper {
def nodeId: String = hostInfo.hostname + ":" + hostInfo.basePort + 1
@Value("${zookeeperService.client.enabled:false}")
var enabled: Boolean = _
@Value("${zookeeperService.leaderPath:/ls}")
var leaderPath: String = _
@Value("${zookeeperService.sessionTimeoutSec:30}")
var sessionTimeoutSec: Int = _
@Value("${zookeeperService.connectionTimeoutSec:5}")
var connectionTimeoutSec: Int = _
var curatorFramework: CuratorFramework = _
var leaderLatch: LeaderLatch = _
// ClusterService implementation
// ...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment