-
Notifications
You must be signed in to change notification settings - Fork 3.9k
rls: fake direct scheduled executor supports schedule #6957
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
rls/src/test/java/io/grpc/rls/internal/DoNotUseDirectScheduledExecutorService.java
Show resolved
Hide resolved
rls/src/test/java/io/grpc/rls/internal/DoNotUseDirectScheduledExecutorService.java
Outdated
Show resolved
Hide resolved
rls/src/test/java/io/grpc/rls/internal/DoNotUseDirectScheduledExecutorService.java
Outdated
Show resolved
Hide resolved
rls/src/test/java/io/grpc/rls/internal/DoNotUseDirectScheduledExecutorService.java
Outdated
Show resolved
Hide resolved
rls/src/test/java/io/grpc/rls/internal/DoNotUseDirectScheduledExecutorService.java
Outdated
Show resolved
Hide resolved
} | ||
|
||
@Override | ||
public ScheduledFuture<?> schedule(Runnable command, long delay, TimeUnit unit) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: final?
rls/src/test/java/io/grpc/rls/internal/DoNotUseDirectScheduledExecutorService.java
Outdated
Show resolved
Hide resolved
} | ||
} | ||
|
||
class FakeTimeProvider implements TimeProvider { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: final
return scheduledRunnable.scheduledFuture; | ||
} | ||
|
||
FakeTimeProvider getFakeTimeProvider() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: final
FYI. the schedule method is not used in this test, but will be used in other test.