@@ -303,7 +303,7 @@ private CachedRouteLookupResponse asyncRlsCall(
303303 // on this result
304304 return CachedRouteLookupResponse .backoffEntry (createBackOffEntry (
305305 routeLookupRequestKey , Status .RESOURCE_EXHAUSTED .withDescription ("RLS throttled" ),
306- backoffPolicy , routeLookupReason ));
306+ backoffPolicy ));
307307 }
308308 final SettableFuture <RouteLookupResponse > response = SettableFuture .create ();
309309 io .grpc .lookup .v1 .RouteLookupRequest routeLookupRequest = REQUEST_CONVERTER .convert (
@@ -417,7 +417,7 @@ private void pendingRpcComplete(PendingCacheEntry entry) {
417417 // reattempt picks when the child LB is done connecting
418418 } catch (Exception e ) {
419419 createBackOffEntry (entry .routeLookupRequestKey , Status .fromThrowable (e ),
420- entry .backoffPolicy , entry . routeLookupReason );
420+ entry .backoffPolicy );
421421 // Cache updated. updateBalancingState() to reattempt picks
422422 helper .triggerPendingRpcProcessing ();
423423 }
@@ -439,9 +439,8 @@ private DataCacheEntry createDataEntry(
439439 }
440440
441441 @ GuardedBy ("lock" )
442- private BackoffCacheEntry createBackOffEntry (
443- RouteLookupRequestKey routeLookupRequestKey , Status status ,
444- @ Nullable BackoffPolicy backoffPolicy , RouteLookupRequest .Reason routeLookupReason ) {
442+ private BackoffCacheEntry createBackOffEntry (RouteLookupRequestKey routeLookupRequestKey ,
443+ Status status , @ Nullable BackoffPolicy backoffPolicy ) {
445444 if (backoffPolicy == null ) {
446445 backoffPolicy = backoffProvider .get ();
447446 }
@@ -450,8 +449,7 @@ private BackoffCacheEntry createBackOffEntry(
450449 ChannelLogLevel .DEBUG ,
451450 "[RLS Entry {0}] Transition to back off: status={1}, delayNanos={2}" ,
452451 routeLookupRequestKey , status , delayNanos );
453- BackoffCacheEntry entry = new BackoffCacheEntry (routeLookupRequestKey , status , backoffPolicy ,
454- routeLookupReason );
452+ BackoffCacheEntry entry = new BackoffCacheEntry (routeLookupRequestKey , status , backoffPolicy );
455453 // Lock is held, so the task can't execute before the assignment
456454 entry .scheduledFuture = scheduledExecutorService .schedule (
457455 () -> refreshBackoffEntry (entry ), delayNanos , TimeUnit .NANOSECONDS );
@@ -469,7 +467,7 @@ private void refreshBackoffEntry(BackoffCacheEntry entry) {
469467 logger .log (ChannelLogLevel .DEBUG ,
470468 "[RLS Entry {0}] Calling RLS for transition to pending" , entry .routeLookupRequestKey );
471469 linkedHashLruCache .invalidate (entry .routeLookupRequestKey );
472- asyncRlsCall (entry .routeLookupRequestKey , entry .backoffPolicy , entry . routeLookupReason );
470+ asyncRlsCall (entry .routeLookupRequestKey , entry .backoffPolicy , RouteLookupRequest . Reason . REASON_MISS );
473471 }
474472 }
475473
@@ -779,15 +777,13 @@ private static final class BackoffCacheEntry extends CacheEntry {
779777
780778 private final Status status ;
781779 private final BackoffPolicy backoffPolicy ;
782- private final RouteLookupRequest .Reason routeLookupReason ;
783780 private Future <?> scheduledFuture ;
784781
785782 BackoffCacheEntry (RouteLookupRequestKey routeLookupRequestKey , Status status ,
786- BackoffPolicy backoffPolicy , RouteLookupRequest . Reason routeLookupReason ) {
783+ BackoffPolicy backoffPolicy ) {
787784 super (routeLookupRequestKey );
788785 this .status = checkNotNull (status , "status" );
789786 this .backoffPolicy = checkNotNull (backoffPolicy , "backoffPolicy" );
790- this .routeLookupReason = checkNotNull (routeLookupReason , "routeLookupReason" );
791787 }
792788
793789 Status getStatus () {
0 commit comments