diff --git a/src/ruby/.rubocop.yml b/src/ruby/.rubocop.yml
index 312bdca384e538030d18a3f70e3d9645920031ec..d740b79ffda551c581117166cd0f3932fb5a68ed 100644
--- a/src/ruby/.rubocop.yml
+++ b/src/ruby/.rubocop.yml
@@ -9,3 +9,9 @@ AllCops:
     - 'bin/math_services.rb'
     - 'pb/grpc/health/v1alpha/*'
     - 'pb/test/**/*'
+
+Metrics/CyclomaticComplexity:
+  Max: 8
+
+Metrics/PerceivedComplexity:
+  Max: 8
\ No newline at end of file
diff --git a/src/ruby/lib/grpc/generic/rpc_server.rb b/src/ruby/lib/grpc/generic/rpc_server.rb
index 8dfc9b67637263f4325d9c96142be5becd8ef1a8..228c500672b859499596e8e769e0f40929ba71df 100644
--- a/src/ruby/lib/grpc/generic/rpc_server.rb
+++ b/src/ruby/lib/grpc/generic/rpc_server.rb
@@ -416,13 +416,10 @@ module GRPC
       until stopped?
         begin
           an_rpc = @server.request_call(@cq, loop_tag, INFINITE_FUTURE)
+          break if (!an_rpc.nil?) && an_rpc.call.nil?
+
           c = new_active_server_call(an_rpc)
-          if c.nil?
-            # With infinite timeout on request_call, a nil call implies that the
-            # server has shut down. Waiting for another call at that point will
-            # not accomplish anything.
-            break
-          else
+          unless c.nil?
             mth = an_rpc.method.to_sym
             @pool.schedule(c) do |call|
               rpc_descs[mth].run_server_method(call, rpc_handlers[mth])