Skip to content

Commit 48ae33a

Browse files
authored
BUG 35028949 - [35023368->14.1.1.0.13] CQC clients deadlock between O… (#21)
* BUG 35028949 - [35023368->14.1.1.0.13] CQC clients deadlock between ObservableHashMap and ContinuousQueryCache.ensureSynchronized [git-p4: depot-paths = "//dev/release.net/coherence-net-v14.1.1.0/": change = 98226] * Update workflow to use Java 17 * Attempt to fix .net issue
1 parent e4e4c46 commit 48ae33a

File tree

2 files changed

+31
-16
lines changed

2 files changed

+31
-16
lines changed

.github/workflows/build.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,16 @@ jobs:
6161
- name: Checkout
6262
uses: actions/checkout@v2
6363

64-
# Set up Java 11
65-
- name: Set up Java 11
64+
- name: Setup dotnet
65+
uses: actions/setup-dotnet@v3
66+
with:
67+
dotnet-version: '3.1.x'
68+
69+
# Set up Java 17
70+
- name: Set up Java 17
6671
uses: actions/setup-java@v1
6772
with:
68-
java-version: '11'
73+
java-version: '17'
6974

7075
# Install SSL certificates
7176
- name: Install SSL certificates

src/Coherence.Core/Net/Cache/ContinuousQueryCache.cs

Lines changed: 23 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
/*
2-
* Copyright (c) 2000, 2020, Oracle and/or its affiliates.
2+
* Copyright (c) 2000, 2023, Oracle and/or its affiliates.
33
*
44
* Licensed under the Universal Permissive License v 1.0 as shown at
5-
* http://oss.oracle.com/licenses/upl.
5+
* https://oss.oracle.com/licenses/upl.
66
*/
77
using System;
88
using System.Collections;
@@ -2557,11 +2557,18 @@ protected bool IsEventDeferred(object key)
25572557
{
25582558
if (State <= CacheState.Configuring)
25592559
{
2560-
// since the listeners are being configured and the local
2561-
// cache is being populated, assume that the event is
2562-
// being processed out-of-order and requires a subsequent
2563-
// synchronization of the corresponding value
2564-
cacheSyncReq[key] = null;
2560+
if (typeof(DeactivationListener).Name.Equals(key))
2561+
{
2562+
cacheSyncReq.Clear();
2563+
}
2564+
else
2565+
{
2566+
// since the listeners are being configured and the local
2567+
// cache is being populated, assume that the event is
2568+
// being processed out-of-order and requires a subsequent
2569+
// synchronization of the corresponding value
2570+
cacheSyncReq[key] = null;
2571+
}
25652572
isDeferred = true;
25662573
}
25672574
else
@@ -3056,13 +3063,16 @@ public override void EntryUpdated(CacheEventArgs evt)
30563063
// "truncate" event
30573064
ContinuousQueryCache queryCache = m_parentQueryCache;
30583065
IObservableCache internalCache = queryCache.InternalCache;
3059-
if (internalCache is LocalCache)
3066+
if (!queryCache.IsEventDeferred(typeof(DeactivationListener).Name))
30603067
{
3061-
((LocalCache) internalCache).Truncate();
3062-
}
3063-
else
3064-
{
3065-
internalCache.Clear();
3068+
if (internalCache is LocalCache)
3069+
{
3070+
((LocalCache) internalCache).Truncate();
3071+
}
3072+
else
3073+
{
3074+
internalCache.Clear();
3075+
}
30663076
}
30673077
}
30683078

0 commit comments

Comments
 (0)