Undo leftover experimental AtomicBoolean
This commit is contained in:
@@ -40,7 +40,7 @@ public abstract class BasePluginCompatibility {
|
|||||||
/**
|
/**
|
||||||
* Whether the compatibility class has attempted to resolve the reflection references yet or not.
|
* Whether the compatibility class has attempted to resolve the reflection references yet or not.
|
||||||
*/
|
*/
|
||||||
private final AtomicBoolean reflectionResolutionAttempted = new AtomicBoolean(false);
|
private boolean reflectionResolutionAttempted = false;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Define a new compatibility class.
|
* Define a new compatibility class.
|
||||||
@@ -112,7 +112,7 @@ public abstract class BasePluginCompatibility {
|
|||||||
*/
|
*/
|
||||||
boolean completePluginCompatibilityCondition(BooleanSupplier conditionCallback) {
|
boolean completePluginCompatibilityCondition(BooleanSupplier conditionCallback) {
|
||||||
synchronized (this) { // compatibility classes are singletons so syncing on itself is safe
|
synchronized (this) { // compatibility classes are singletons so syncing on itself is safe
|
||||||
if (!this.reflectionResolutionAttempted.getAcquire()) {
|
if (!this.reflectionResolutionAttempted) {
|
||||||
var pluginClassLoaders = collectPluginClassLoaders();
|
var pluginClassLoaders = collectPluginClassLoaders();
|
||||||
if (pluginClassLoaders == null) {
|
if (pluginClassLoaders == null) {
|
||||||
return false;
|
return false;
|
||||||
@@ -125,7 +125,7 @@ public abstract class BasePluginCompatibility {
|
|||||||
onPluginClassesNotFound(e);
|
onPluginClassesNotFound(e);
|
||||||
return true;
|
return true;
|
||||||
} finally {
|
} finally {
|
||||||
this.reflectionResolutionAttempted.setRelease(true);
|
this.reflectionResolutionAttempted = true;
|
||||||
}
|
}
|
||||||
NitoriUtil.getPreferredLogger().info(NitoriUtil.makeLogMessage("Resolved reflection references for " + thisClassName + "."));
|
NitoriUtil.getPreferredLogger().info(NitoriUtil.makeLogMessage("Resolved reflection references for " + thisClassName + "."));
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user