You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2015/11/04 12:15:08 UTC

[2/2] isis git commit: ISIS-830: improved error message

ISIS-830: improved error message


Project: http://git-wip-us.apache.org/repos/asf/isis/repo
Commit: http://git-wip-us.apache.org/repos/asf/isis/commit/f1c65d0e
Tree: http://git-wip-us.apache.org/repos/asf/isis/tree/f1c65d0e
Diff: http://git-wip-us.apache.org/repos/asf/isis/diff/f1c65d0e

Branch: refs/heads/master
Commit: f1c65d0e18b5d113a72e5f7527d22394aa57a808
Parents: 5d9f9af
Author: Dan Haywood <da...@haywood-associates.co.uk>
Authored: Wed Nov 4 11:14:24 2015 +0000
Committer: Dan Haywood <da...@haywood-associates.co.uk>
Committed: Wed Nov 4 11:14:24 2015 +0000

----------------------------------------------------------------------
 .../core/runtime/services/eventbus/EventBusServiceDefault.java     | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/isis/blob/f1c65d0e/core/runtime/src/main/java/org/apache/isis/core/runtime/services/eventbus/EventBusServiceDefault.java
----------------------------------------------------------------------
diff --git a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/eventbus/EventBusServiceDefault.java b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/eventbus/EventBusServiceDefault.java
index 71ca9c7..93aafc4 100644
--- a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/eventbus/EventBusServiceDefault.java
+++ b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/eventbus/EventBusServiceDefault.java
@@ -63,7 +63,7 @@ public abstract class EventBusServiceDefault extends EventBusService {
             // a singleton
             if (!allowLateRegistration && hasPosted()) {
                 // ... coming too late to the party.
-                throw new IllegalStateException("Events have already been posted; too late to register any further (singleton) subscribers");
+                throw new IllegalStateException("Events have already been posted; too late to register any further (singleton) subscribers.  Either use @DomainServiceLayout(menuOrder=...) to ensure that subscribers are initialized before any services that might post events, or alternatively use '" + KEY_ALLOW_LATE_REGISTRATION + "' configuration property to relax this check (meaning that some subscribers will miss some posted events)");
             }
         }
         super.register(domainService);