bug fix
This commit is contained in:
Родитель
fb6ab52e3b
Коммит
9f873d40eb
|
@ -712,7 +712,7 @@ namespace Microsoft.Azure.Cosmos.Query.Core.ExecutionContext
|
|||
bool is_gsi_enabled = ConfigurationManager.GetEnvironmentVariable<bool>("GSI_ENABLED", false);
|
||||
if (is_gsi_enabled)
|
||||
{
|
||||
await GSIFactory.FilterUsingCacheAsync(sqlQuerySpec, targetRanges);
|
||||
targetRanges = await GSIFactory.FilterUsingCacheAsync(sqlQuerySpec, targetRanges);
|
||||
}
|
||||
|
||||
return targetRanges;
|
||||
|
|
|
@ -29,8 +29,6 @@ namespace Microsoft.Azure.Cosmos
|
|||
|
||||
for (int i = 0; i < connectionPool.connections.Length; i++)
|
||||
{
|
||||
Console.WriteLine($" - Creating Connection #{i}");
|
||||
|
||||
ConnectionMultiplexer con = Connection.CreateConnection(config);
|
||||
connectionPool.connections[i] = con;
|
||||
}
|
||||
|
|
|
@ -14,7 +14,7 @@ namespace Microsoft.Azure.Cosmos
|
|||
{
|
||||
public static IGarnetReader cacheReader = new GarnetReader();
|
||||
|
||||
public static async Task FilterUsingCacheAsync(SqlQuerySpec querySpec, List<Documents.PartitionKeyRange> keyRanges)
|
||||
public static async Task<List<Documents.PartitionKeyRange>> FilterUsingCacheAsync(SqlQuerySpec querySpec, List<Documents.PartitionKeyRange> keyRanges)
|
||||
{
|
||||
List<string> pkrangesIdsToKeep = new ();
|
||||
foreach (var parameter in querySpec.Parameters)
|
||||
|
@ -25,7 +25,7 @@ namespace Microsoft.Azure.Cosmos
|
|||
}
|
||||
}
|
||||
|
||||
keyRanges = keyRanges.Where(obj => pkrangesIdsToKeep.Contains(obj.Id)).ToList();
|
||||
return keyRanges.Where(obj => pkrangesIdsToKeep.Contains(obj.Id)).ToList();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче