Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
StackExchange.Redis
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
tsai
StackExchange.Redis
Commits
a010a1fe
Commit
a010a1fe
authored
Aug 15, 2018
by
Nick Craver
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cursors: better error message
parent
9a2425f7
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
2 deletions
+10
-2
RedisBase.cs
StackExchange.Redis/RedisBase.cs
+10
-2
No files found.
StackExchange.Redis/RedisBase.cs
View file @
a010a1fe
...
...
@@ -178,7 +178,7 @@ protected Task<ScanResult> GetNextPageAsync(IScanningCursor obj, long cursor)
return
redis
.
ExecuteAsync
(
CreateMessage
(
cursor
),
Processor
,
server
);
}
protected
ScanResult
Wait
(
Task
<
ScanResult
>
pending
)
=>
redis
.
Wait
(
pending
);
protected
bool
TryWait
(
Task
<
ScanResult
>
pending
)
=>
redis
.
Try
Wait
(
pending
);
private
class
CursorEnumerator
:
IEnumerator
<
T
>,
IScanningCursor
{
...
...
@@ -254,7 +254,15 @@ public bool MoveNext()
// do we have an outstanding operation? wait for the background task to finish
while
(
pending
!=
null
)
{
ProcessReply
(
parent
.
Wait
(
pending
));
if
(
parent
.
TryWait
(
pending
))
{
ProcessReply
(
pending
.
Result
);
}
else
{
throw
ExceptionFactory
.
Timeout
(
parent
.
redis
.
multiplexer
.
IncludeDetailInExceptions
,
"Timeout waiting for scan cursor to complete"
,
null
,
parent
.
server
);
}
if
(
SimpleNext
())
return
true
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment