You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by ah...@apache.org on 2020/01/19 11:48:00 UTC
[isis] branch master updated: ISIS-2265: 'fail early' applies only
during bootstrapping
This is an automated email from the ASF dual-hosted git repository.
ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git
The following commit(s) were added to refs/heads/master by this push:
new 4b2c74c ISIS-2265: 'fail early' applies only during bootstrapping
4b2c74c is described below
commit 4b2c74cefb8377ad836ba935659ba296115bfc5f
Author: Andi Huber <ah...@apache.org>
AuthorDate: Sun Jan 19 12:47:52 2020 +0100
ISIS-2265: 'fail early' applies only during bootstrapping
never do this when the application is already fully initialized and
running
---
.../specloader/SpecificationLoaderDefault.java | 19 ++++++++++++++-----
1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/specloader/SpecificationLoaderDefault.java b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/specloader/SpecificationLoaderDefault.java
index a87e03b..21967cc 100644
--- a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/specloader/SpecificationLoaderDefault.java
+++ b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/specloader/SpecificationLoaderDefault.java
@@ -462,12 +462,21 @@ public class SpecificationLoaderDefault implements SpecificationLoader {
typeRegistry.ifToBeInspectedThen(cls, sort->{
- throw _Exceptions.illegalState(
- "Cannot introspect class '%s' of sort %s, because the metamodel has been fully introspected and is now locked. " +
- "One reason this can happen is if you are attempting to invoke an action through the WrapperFactory " +
- "on a service class incorrectly annotated with Spring's @Service annotation instead of " +
- "@DomainService.",
+ log.error("Introspecting class '%s' of sort %s, after the metamodel had been fully introspected and is now locked. " +
+ "One reason this can happen is if you are attempting to invoke an action through the WrapperFactory " +
+ "on a service class incorrectly annotated with Spring's @Service annotation instead of " +
+ "@DomainService.",
cls.getName(), sort);
+
+// ISIS-2256: 'fail early' applies only during bootstrapping
+// never do this when the application is already fully initialized and running
+//
+// throw _Exceptions.illegalState(
+// "Cannot introspect class '%s' of sort %s, because the metamodel has been fully introspected and is now locked. " +
+// "One reason this can happen is if you are attempting to invoke an action through the WrapperFactory " +
+// "on a service class incorrectly annotated with Spring's @Service annotation instead of " +
+// "@DomainService.",
+// cls.getName(), sort);
});
}