summaryrefslogtreecommitdiffhomepage
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/grpc/cpp/gobgp_api_client.cc2
-rw-r--r--tools/grpc/nodejs/get_neighbors.js2
-rw-r--r--tools/grpc/python/get_neighbor.py2
-rw-r--r--tools/grpc/ruby/get_neighbors.rb2
4 files changed, 4 insertions, 4 deletions
diff --git a/tools/grpc/cpp/gobgp_api_client.cc b/tools/grpc/cpp/gobgp_api_client.cc
index 2d0b0960..4780ded7 100644
--- a/tools/grpc/cpp/gobgp_api_client.cc
+++ b/tools/grpc/cpp/gobgp_api_client.cc
@@ -245,7 +245,7 @@ class GrpcClient {
};
int main(int argc, char** argv) {
- GrpcClient gobgp_client(grpc::CreateChannel("localhost:8080", grpc::InsecureChannelCredentials()));
+ GrpcClient gobgp_client(grpc::CreateChannel("localhost:50051", grpc::InsecureChannelCredentials()));
std::string reply = gobgp_client.GetNeighbor("213.133.111.200");
std::cout << "Neighbor information: " << reply << std::endl;
diff --git a/tools/grpc/nodejs/get_neighbors.js b/tools/grpc/nodejs/get_neighbors.js
index c1ec763b..ba2296fa 100644
--- a/tools/grpc/nodejs/get_neighbors.js
+++ b/tools/grpc/nodejs/get_neighbors.js
@@ -1,6 +1,6 @@
var grpc = require('grpc');
var api = grpc.load('gobgp.proto').gobgpapi;
-var stub = new api.GobgpApi('localhost:8080', grpc.Credentials.createInsecure());
+var stub = new api.GobgpApi('localhost:50051', grpc.Credentials.createInsecure());
var call = stub.getNeighbors({});
call.on('data', function(neighbor) {
diff --git a/tools/grpc/python/get_neighbor.py b/tools/grpc/python/get_neighbor.py
index 867f1124..f49a61bf 100644
--- a/tools/grpc/python/get_neighbor.py
+++ b/tools/grpc/python/get_neighbor.py
@@ -7,7 +7,7 @@ _TIMEOUT_SECONDS = 10
def run(gobgpd_addr, neighbor_addr):
- channel = implementations.insecure_channel(gobgpd_addr, 8080)
+ channel = implementations.insecure_channel(gobgpd_addr, 50051)
with gobgp_pb2.beta_create_GobgpApi_stub(channel) as stub:
peer = stub.GetNeighbor(gobgp_pb2.Arguments(rf=4, name=neighbor_addr), _TIMEOUT_SECONDS)
print("BGP neighbor is %s, remote AS %d" % (peer.conf.neighbor_address, peer.conf.peer_as))
diff --git a/tools/grpc/ruby/get_neighbors.rb b/tools/grpc/ruby/get_neighbors.rb
index 83ed9155..e47b7913 100644
--- a/tools/grpc/ruby/get_neighbors.rb
+++ b/tools/grpc/ruby/get_neighbors.rb
@@ -4,7 +4,7 @@ require 'gobgp_services'
host = 'localhost'
host = ARGV[0] if ARGV.length > 0
-stub = Gobgpapi::GobgpApi::Stub.new("#{host}:8080")
+stub = Gobgpapi::GobgpApi::Stub.new("#{host}:50051")
arg = Gobgpapi::Arguments.new()
stub.get_neighbors(arg).each do |n|
puts "BGP neighbor is #{n.conf.neighbor_address}, remote AS #{n.conf.peer_as}"