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
68af2f79
Commit
68af2f79
authored
Sep 28, 2018
by
Marc Gravell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
no need to keep generating guids
parent
61f7bff8
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
3 deletions
+3
-3
PhysicalBridge.cs
src/StackExchange.Redis/PhysicalBridge.cs
+1
-1
RedisSubscriber.cs
src/StackExchange.Redis/RedisSubscriber.cs
+1
-1
ServerEndPoint.cs
src/StackExchange.Redis/ServerEndPoint.cs
+1
-1
No files found.
src/StackExchange.Redis/PhysicalBridge.cs
View file @
68af2f79
...
...
@@ -255,7 +255,7 @@ internal void KeepAlive()
else
if
(
commandMap
.
IsAvailable
(
RedisCommand
.
UNSUBSCRIBE
))
{
msg
=
Message
.
Create
(-
1
,
CommandFlags
.
FireAndForget
,
RedisCommand
.
UNSUBSCRIBE
,
(
RedisChannel
)
Guid
.
NewGuid
().
ToByteArray
()
);
(
RedisChannel
)
Multiplexer
.
UniqueId
);
msg
.
SetSource
(
ResultProcessor
.
TrackSubscriptions
,
null
);
}
break
;
...
...
src/StackExchange.Redis/RedisSubscriber.cs
View file @
68af2f79
...
...
@@ -349,7 +349,7 @@ private Message CreatePingMessage(CommandFlags flags, out ServerEndPoint server)
else
{
// can't use regular PING, but we can unsubscribe from something random that we weren't even subscribed to...
RedisValue
channel
=
Guid
.
NewGuid
().
ToByteArray
()
;
RedisValue
channel
=
multiplexer
.
UniqueId
;
return
ResultProcessor
.
TimingProcessor
.
CreateMessage
(-
1
,
flags
,
RedisCommand
.
UNSUBSCRIBE
,
channel
);
}
}
...
...
src/StackExchange.Redis/ServerEndPoint.cs
View file @
68af2f79
...
...
@@ -300,7 +300,7 @@ internal void AutoConfigure(PhysicalConnection connection)
else
if
(
commandMap
.
IsAvailable
(
RedisCommand
.
SET
))
{
// this is a nasty way to find if we are a slave, and it will only work on up-level servers, but...
RedisKey
key
=
Guid
.
NewGuid
().
ToByteArray
()
;
RedisKey
key
=
Multiplexer
.
UniqueId
;
msg
=
Message
.
Create
(
0
,
flags
,
RedisCommand
.
SET
,
key
,
RedisLiterals
.
slave_read_only
,
RedisLiterals
.
PX
,
1
,
RedisLiterals
.
NX
);
msg
.
SetInternalCall
();
WriteDirectOrQueueFireAndForget
(
connection
,
msg
,
ResultProcessor
.
AutoConfigure
);
...
...
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