aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/ruby/bin/interop
diff options
context:
space:
mode:
Diffstat (limited to 'src/ruby/bin/interop')
-rwxr-xr-xsrc/ruby/bin/interop/interop_client.rb6
-rwxr-xr-xsrc/ruby/bin/interop/interop_server.rb8
2 files changed, 7 insertions, 7 deletions
diff --git a/src/ruby/bin/interop/interop_client.rb b/src/ruby/bin/interop/interop_client.rb
index a388924722..8df03ffb3c 100755
--- a/src/ruby/bin/interop/interop_client.rb
+++ b/src/ruby/bin/interop/interop_client.rb
@@ -70,7 +70,7 @@ end
# loads the certificates used to access the test server securely.
def load_prod_cert
fail 'could not find a production cert' if ENV['SSL_CERT_FILE'].nil?
- logger.info("loading prod certs from #{ENV['SSL_CERT_FILE']}")
+ GRPC.logger.info("loading prod certs from #{ENV['SSL_CERT_FILE']}")
File.open(ENV['SSL_CERT_FILE']).read
end
@@ -115,10 +115,10 @@ def create_stub(opts)
stub_opts[:update_metadata] = auth_creds.updater_proc
end
- logger.info("... connecting securely to #{address}")
+ GRPC.logger.info("... connecting securely to #{address}")
Grpc::Testing::TestService::Stub.new(address, **stub_opts)
else
- logger.info("... connecting insecurely to #{address}")
+ GRPC.logger.info("... connecting insecurely to #{address}")
Grpc::Testing::TestService::Stub.new(address)
end
end
diff --git a/src/ruby/bin/interop/interop_server.rb b/src/ruby/bin/interop/interop_server.rb
index 72570d92f3..78cb8dd836 100755
--- a/src/ruby/bin/interop/interop_server.rb
+++ b/src/ruby/bin/interop/interop_server.rb
@@ -129,13 +129,13 @@ class TestTarget < Grpc::Testing::TestService::Service
Thread.new do
begin
reqs.each do |req|
- logger.info("read #{req.inspect}")
+ GRPC.logger.info("read #{req.inspect}")
resp_size = req.response_parameters[0].size
resp = cls.new(payload: Payload.new(type: req.response_type,
body: nulls(resp_size)))
q.push(resp)
end
- logger.info('finished reads')
+ GRPC.logger.info('finished reads')
q.push(self)
rescue StandardError => e
q.push(e) # share the exception with the enumerator
@@ -179,10 +179,10 @@ def main
s = GRPC::RpcServer.new
if opts['secure']
s.add_http2_port(host, test_server_creds)
- logger.info("... running securely on #{host}")
+ GRPC.logger.info("... running securely on #{host}")
else
s.add_http2_port(host)
- logger.info("... running insecurely on #{host}")
+ GRPC.logger.info("... running insecurely on #{host}")
end
s.handle(TestTarget)
s.run_till_terminated