-
Notifications
You must be signed in to change notification settings - Fork 0
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
[TS-1928] Support keepOpen
option for searchMessageGroups
gRPC r…
#86
base: dev-version-2
Are you sure you want to change the base?
Conversation
@isengrims : Current version has the problem internal task isn't canceled when deadline exceeded or message with timestamp more than request end time got from cradle |
keepOpen
option for searchMessageGroups
gRPC r…keepOpen
option for searchMessageGroups
gRPC r…
app/src/main/kotlin/com/exactpro/th2/lwdataprovider/grpc/GrpcDataProviderBackPressure.kt
Outdated
Show resolved
Hide resolved
app/src/main/kotlin/com/exactpro/th2/lwdataprovider/grpc/GrpcDataProviderBackPressure.kt
Outdated
Show resolved
Hide resolved
app/src/main/kotlin/com/exactpro/th2/lwdataprovider/grpc/GrpcDataProviderBackPressure.kt
Outdated
Show resolved
Hide resolved
app/src/main/kotlin/com/exactpro/th2/lwdataprovider/grpc/GrpcDataProviderImpl.kt
Outdated
Show resolved
Hide resolved
@@ -140,6 +140,7 @@ class SearchMessagesHandler( | |||
val allLoaded = hashSetOf<Stream>() | |||
do { | |||
val continuePulling = pullUpdates(request, order, sink, allLoaded) | |||
Thread.sleep(configuration.keepOpenPullingTimeoutMs) |
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.
note: please check if we should keep pulling before calling sleep
method. As an alternative, I think you can call sleep method before calling pullUpdates
. I think it would make sense to wait a bit before first pull attempt as well
|
||
assertInstanceOf<CancelableResponseHandler>(capturedRequestContext) | ||
|
||
Thread.sleep(200) |
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.
suggestion: you could use awaitility library instead of sleep call
…equest