[java-shib-shared] 01/03: JSSH-71 Remove the impact of the DestructableComponent Interface
Codeberg
noreply at shibboleth.net
Fri May 22 13:25:07 UTC 2026
This is an automated email from the git hooks/post-receive script.
codeberg pushed a commit to branch dev/JSSH-71
in repository java-shib-shared.
View the commit online:
https://codeberg.org/Shibboleth/java-shib-shared/commit/bf22a23e1de147388fbe9081aa2892f9cc535bba
commit bf22a23e1de147388fbe9081aa2892f9cc535bba
Author: Rod Widdowson <rdw at steadingsoftware.com>
AuthorDate: Thu May 21 13:25:18 2026 +0100
JSSH-71 Remove the impact of the DestructableComponent Interface
https://shibboleth.atlassian.net/browse/JSSH-71
Remove (run time) test on the on destroyed-state of a component.
---
.../component/AbstractIdentifiedInitializableComponent.java | 11 -----------
.../shared/component/AbstractInitializableComponent.java | 13 -------------
2 files changed, 24 deletions(-)
diff --git a/shib-support/src/main/java/net/shibboleth/shared/component/AbstractIdentifiedInitializableComponent.java b/shib-support/src/main/java/net/shibboleth/shared/component/AbstractIdentifiedInitializableComponent.java
index ce17bedb..57107628 100644
--- a/shib-support/src/main/java/net/shibboleth/shared/component/AbstractIdentifiedInitializableComponent.java
+++ b/shib-support/src/main/java/net/shibboleth/shared/component/AbstractIdentifiedInitializableComponent.java
@@ -57,17 +57,6 @@ public abstract class AbstractIdentifiedInitializableComponent extends AbstractI
return idCopy;
}
- /**
- * Checks if the component is destroyed and, if so, throws a {@link DestroyedComponentException}.
- */
- protected final void ifDestroyedThrowDestroyedComponentException() {
- if (isDestroyed()) {
- throw new DestroyedComponentException("Component '"
- + StringSupport.trimOrNull(getId())
- + "' has already been destroyed and can no longer be used.");
- }
- }
-
/**
* Checks if a component has not been initialized and, if so, throws a {@link UninitializedComponentException}.
*/
diff --git a/shib-support/src/main/java/net/shibboleth/shared/component/AbstractInitializableComponent.java b/shib-support/src/main/java/net/shibboleth/shared/component/AbstractInitializableComponent.java
index aeb9aef9..d6a8c7f2 100644
--- a/shib-support/src/main/java/net/shibboleth/shared/component/AbstractInitializableComponent.java
+++ b/shib-support/src/main/java/net/shibboleth/shared/component/AbstractInitializableComponent.java
@@ -54,7 +54,6 @@ public abstract class AbstractInitializableComponent implements DestructableComp
/** {@inheritDoc} */
@Override
public final synchronized void initialize() throws ComponentInitializationException {
- ifDestroyedThrowDestroyedComponentException();
if (isInitialized()) {
return;
}
@@ -63,16 +62,6 @@ public abstract class AbstractInitializableComponent implements DestructableComp
isInitialized = true;
}
- /**
- * Checks if the component is destroyed and, if so, throws a {@link DestroyedComponentException}.
- */
- protected void ifDestroyedThrowDestroyedComponentException() {
- if (isDestroyed()) {
- throw new DestroyedComponentException(
- "Unidentified Component has already been destroyed and can no longer be used.");
- }
- }
-
/**
* Checks if a component has not been initialized and, if so, throws a {@link UninitializedComponentException}.
*/
@@ -97,7 +86,6 @@ public abstract class AbstractInitializableComponent implements DestructableComp
* Helper for a setter method to check the standard preconditions.
*/
protected final void checkSetterPreconditions() {
- ifDestroyedThrowDestroyedComponentException();
ifInitializedThrowUnmodifiabledComponentException();
}
@@ -106,7 +94,6 @@ public abstract class AbstractInitializableComponent implements DestructableComp
* not initialized, or have been destroyed.
*/
protected final void checkComponentActive() {
- ifDestroyedThrowDestroyedComponentException();
ifNotInitializedThrowUninitializedComponentException();
}
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list