fix some issues after merge
This commit is contained in:
@@ -101,7 +101,7 @@ class UpstreamsConfigReader(
|
|||||||
val connConfigNode = getMapping(connNode, "grpc")!!
|
val connConfigNode = getMapping(connNode, "grpc")!!
|
||||||
val upstream = UpstreamsConfig.Upstream<UpstreamsConfig.GrpcConnection>()
|
val upstream = UpstreamsConfig.Upstream<UpstreamsConfig.GrpcConnection>()
|
||||||
readUpstreamCommon(upNode, upstream)
|
readUpstreamCommon(upNode, upstream)
|
||||||
readUpstreamGrpc(upNode, upstream)
|
readUpstreamGrpc(upNode)
|
||||||
if (isValid(upstream)) {
|
if (isValid(upstream)) {
|
||||||
config.upstreams.add(upstream)
|
config.upstreams.add(upstream)
|
||||||
val connection = UpstreamsConfig.GrpcConnection()
|
val connection = UpstreamsConfig.GrpcConnection()
|
||||||
@@ -245,7 +245,6 @@ class UpstreamsConfigReader(
|
|||||||
|
|
||||||
internal fun readUpstreamGrpc(
|
internal fun readUpstreamGrpc(
|
||||||
upNode: MappingNode,
|
upNode: MappingNode,
|
||||||
upstream: UpstreamsConfig.Upstream<UpstreamsConfig.GrpcConnection>
|
|
||||||
) {
|
) {
|
||||||
// Dshackle gRPC connection dispatches requests to different upstreams, which may
|
// Dshackle gRPC connection dispatches requests to different upstreams, which may
|
||||||
// be on different blockchains, and each may have different set of labels.
|
// be on different blockchains, and each may have different set of labels.
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ open class EthereumPosGrpcUpstream(
|
|||||||
private val parentId: String,
|
private val parentId: String,
|
||||||
role: UpstreamsConfig.UpstreamRole,
|
role: UpstreamsConfig.UpstreamRole,
|
||||||
private val chain: Chain,
|
private val chain: Chain,
|
||||||
remote: ReactorBlockchainGrpc.ReactorBlockchainStub,
|
private val remote: ReactorBlockchainGrpc.ReactorBlockchainStub,
|
||||||
client: JsonRpcGrpcClient,
|
client: JsonRpcGrpcClient,
|
||||||
nodeRating: Int
|
nodeRating: Int
|
||||||
) : EthereumPosUpstream(
|
) : EthereumPosUpstream(
|
||||||
@@ -121,6 +121,10 @@ open class EthereumPosGrpcUpstream(
|
|||||||
return upstreamStatus.getNodes()
|
return upstreamStatus.getNodes()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override fun getBlockchainApi(): ReactorBlockchainGrpc.ReactorBlockchainStub {
|
||||||
|
return remote
|
||||||
|
}
|
||||||
|
|
||||||
// ------------------------------------------------------------------------------------------
|
// ------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
override fun getLabels(): Collection<UpstreamsConfig.Labels> {
|
override fun getLabels(): Collection<UpstreamsConfig.Labels> {
|
||||||
|
|||||||
Reference in New Issue
Block a user