Skip to content

Commit 6908fec

Browse files
authored
Merge pull request #227 from MoienTajik/moien/redis-acl-support
Redis acl support
2 parents 35023a7 + 668dd8e commit 6908fec

File tree

6 files changed

+13
-2
lines changed

6 files changed

+13
-2
lines changed

src/EasyCaching.Bus.Redis/Configurations/EasyCachingOptionsExtensions.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ void configure(RedisBusOptions x)
5151
x.ConnectionTimeout = redisOptions.ConnectionTimeout;
5252
x.Database = redisOptions.Database;
5353
x.IsSsl = redisOptions.IsSsl;
54+
x.Username = redisOptions.Username;
5455
x.Password = redisOptions.Password;
5556
x.SslHost = redisOptions.SslHost;
5657

src/EasyCaching.Bus.Redis/Configurations/RedisSubscriberProvider.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ private ConnectionMultiplexer CreateConnectionMultiplexer()
4848
var configurationOptions = new ConfigurationOptions
4949
{
5050
ConnectTimeout = _options.ConnectionTimeout,
51+
User = _options.Username,
5152
Password = _options.Password,
5253
Ssl = _options.IsSsl,
5354
SslHost = _options.SslHost,

src/EasyCaching.Bus.Redis/EasyCaching.Bus.Redis.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
<None Include="../../media/nuget-icon.png" Pack="true" Visible="false" PackagePath="" />
3131
</ItemGroup>
3232
<ItemGroup>
33-
<PackageReference Include="StackExchange.Redis" Version="2.1.28" />
33+
<PackageReference Include="StackExchange.Redis" Version="2.1.58" />
3434
</ItemGroup>
3535
<ItemGroup>
3636
<ProjectReference Include="..\EasyCaching.Core\EasyCaching.Core.csproj" />

src/EasyCaching.Core/Configurations/BaseRedisOptions.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,14 @@
77
/// </summary>
88
public class BaseRedisOptions
99
{
10+
/// <summary>
11+
/// Gets or sets the username to be used to connect to the Redis server.
12+
/// </summary>
13+
/// <value>
14+
/// The username.
15+
/// </value>
16+
public string Username { get; set; } = null;
17+
1018
/// <summary>
1119
/// Gets or sets the password to be used to connect to the Redis server.
1220
/// </summary>

src/EasyCaching.Redis/Configurations/RedisDatabaseProvider.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ private ConnectionMultiplexer CreateConnectionMultiplexer()
6565
var configurationOptions = new ConfigurationOptions
6666
{
6767
ConnectTimeout = _options.ConnectionTimeout,
68+
User = _options.Username,
6869
Password = _options.Password,
6970
Ssl = _options.IsSsl,
7071
SslHost = _options.SslHost,

src/EasyCaching.Redis/EasyCaching.Redis.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
</ItemGroup>
3232

3333
<ItemGroup>
34-
<PackageReference Include="StackExchange.Redis" Version="2.1.28" />
34+
<PackageReference Include="StackExchange.Redis" Version="2.1.58" />
3535
</ItemGroup>
3636
<ItemGroup>
3737
<ProjectReference Include="..\EasyCaching.Core\EasyCaching.Core.csproj" />

0 commit comments

Comments
 (0)