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
2f46249d
Commit
2f46249d
authored
Aug 16, 2018
by
Marc Gravell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
this may be a terrible idea
parent
dc1038a9
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
12 deletions
+8
-12
ChannelMessageQueue.cs
StackExchange.Redis/ChannelMessageQueue.cs
+5
-9
ConnectionMultiplexer.cs
StackExchange.Redis/ConnectionMultiplexer.cs
+1
-1
PhysicalBridge.cs
StackExchange.Redis/PhysicalBridge.cs
+1
-1
PhysicalConnection.cs
StackExchange.Redis/PhysicalConnection.cs
+1
-1
No files found.
StackExchange.Redis/ChannelMessageQueue.cs
View file @
2f46249d
...
...
@@ -151,12 +151,10 @@ private void AssertOnMessage(Delegate handler)
public
void
OnMessage
(
Action
<
ChannelMessage
>
handler
)
{
AssertOnMessage
(
handler
);
using
(
ExecutionContext
.
SuppressFlow
())
{
ThreadPool
.
QueueUserWorkItem
(
state
=>
((
ChannelMessageQueue
)
state
).
OnMessageSyncImpl
(),
this
);
}
}
private
async
void
OnMessageSyncImpl
()
{
...
...
@@ -184,12 +182,10 @@ private async void OnMessageSyncImpl()
public
void
OnMessage
(
Func
<
ChannelMessage
,
Task
>
handler
)
{
AssertOnMessage
(
handler
);
using
(
ExecutionContext
.
SuppressFlow
())
{
ThreadPool
.
QueueUserWorkItem
(
state
=>
((
ChannelMessageQueue
)
state
).
OnMessageAsyncImpl
(),
this
);
}
}
private
async
void
OnMessageAsyncImpl
()
{
...
...
StackExchange.Redis/ConnectionMultiplexer.cs
View file @
2f46249d
...
...
@@ -857,7 +857,7 @@ public static ConnectionMultiplexer Connect(string configuration, TextWriter log
/// <param name="log">The <see cref="TextWriter"/> to log to.</param>
public
static
ConnectionMultiplexer
Connect
(
ConfigurationOptions
configuration
,
TextWriter
log
=
null
)
{
using
(
ExecutionContext
.
SuppressFlow
())
using
(
ExecutionContext
.
IsFlowSuppressed
()
?
null
:
(
AsyncFlowControl
?)
ExecutionContext
.
SuppressFlow
())
{
return
ConnectImpl
(()
=>
CreateMultiplexer
(
configuration
),
log
);
}
...
...
StackExchange.Redis/PhysicalBridge.cs
View file @
2f46249d
...
...
@@ -669,7 +669,7 @@ private PhysicalConnection GetConnection(TextWriter log)
// in that case PhysicalConnection will call back to PhysicalBridge, and most of PhysicalBridge methods assumes that physical is not null;
physical
=
new
PhysicalConnection
(
this
);
using
(
ExecutionContext
.
SuppressFlow
())
using
(
ExecutionContext
.
IsFlowSuppressed
()
?
null
:
(
AsyncFlowControl
?)
ExecutionContext
.
SuppressFlow
())
{
physical
.
BeginConnectAsync
(
log
);
}
...
...
StackExchange.Redis/PhysicalConnection.cs
View file @
2f46249d
...
...
@@ -1496,7 +1496,7 @@ private static RawResult ReadLineTerminatedString(ResultType type, ref BufferRea
internal
void
StartReading
()
{
using
(
ExecutionContext
.
SuppressFlow
())
using
(
ExecutionContext
.
IsFlowSuppressed
()
?
null
:
(
AsyncFlowControl
?)
ExecutionContext
.
SuppressFlow
())
{
ReadFromPipe
();
}
...
...
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