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/08/07 12:11:34 UTC

[07/17] isis git commit: ISIS-848: defined GlobSpec interface in applib, also started reworking simpleapp.

ISIS-848: defined GlobSpec interface in applib, also started reworking simpleapp.


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

Branch: refs/heads/master
Commit: 6ccf96c9addba9175b08ca99c4f80da8a8440c41
Parents: 1ed4eef
Author: Dan Haywood <da...@haywood-associates.co.uk>
Authored: Wed Aug 5 06:42:47 2015 +0100
Committer: Dan Haywood <da...@haywood-associates.co.uk>
Committed: Wed Aug 5 22:34:50 2015 +0100

----------------------------------------------------------------------
 .../java/org/apache/isis/applib/GlobSpec.java   | 134 +++++++++++++++++
 .../domainapp/dom/DomainAppDomainModule.java    |  24 +++
 .../dom/app/homepage/HomePageService.java       |  51 -------
 .../dom/app/homepage/HomePageViewModel.java     |  50 -------
 .../app/homepage/HomePageViewModel.layout.json  |  43 ------
 .../dom/app/homepage/HomePageViewModel.png      | Bin 456 -> 0 bytes
 .../dom/modules/simple/SimpleObject.java        | 149 -------------------
 .../dom/modules/simple/SimpleObject.layout.json |  56 -------
 .../dom/modules/simple/SimpleObject.png         | Bin 653 -> 0 bytes
 .../dom/modules/simple/SimpleObjects.java       | 107 -------------
 .../java/domainapp/dom/simple/SimpleObject.java | 149 +++++++++++++++++++
 .../dom/simple/SimpleObject.layout.json         |  56 +++++++
 .../java/domainapp/dom/simple/SimpleObject.png  | Bin 0 -> 653 bytes
 .../domainapp/dom/simple/SimpleObjects.java     | 107 +++++++++++++
 .../dom/modules/simple/SimpleObjectTest.java    |  49 ------
 .../dom/modules/simple/SimpleObjectsTest.java   | 104 -------------
 .../domainapp/dom/simple/SimpleObjectTest.java  |  49 ++++++
 .../domainapp/dom/simple/SimpleObjectsTest.java | 104 +++++++++++++
 .../modules/simple/SimpleObjectCreate.java      |   4 +-
 .../scenarios/RecreateSimpleObjects.java        |   2 +-
 example/application/simpleapp/glob/pom.xml      |  77 ++++++++++
 .../java/domainapp/glob/DomainAppGlobSpec.java  |  60 ++++++++
 .../glob/app/homepage/HomePageService.java      |  51 +++++++
 .../glob/app/homepage/HomePageViewModel.java    |  50 +++++++
 .../app/homepage/HomePageViewModel.layout.json  |  43 ++++++
 .../glob/app/homepage/HomePageViewModel.png     | Bin 0 -> 456 bytes
 .../application/simpleapp/integtests/pom.xml    |   3 +-
 .../modules/simple/SimpleObjectGlue.java        |   4 +-
 .../modules/simple/SimpleObjectIntegTest.java   |   2 +-
 .../modules/simple/SimpleObjectsIntegTest.java  |   4 +-
 example/application/simpleapp/pom.xml           |   6 +
 example/application/simpleapp/webapp/pom.xml    |  21 +--
 .../src/main/webapp/WEB-INF/isis.properties     |   5 +-
 .../WEB-INF/persistor_datanucleus.properties    |   2 +-
 34 files changed, 923 insertions(+), 643 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/core/applib/src/main/java/org/apache/isis/applib/GlobSpec.java
----------------------------------------------------------------------
diff --git a/core/applib/src/main/java/org/apache/isis/applib/GlobSpec.java b/core/applib/src/main/java/org/apache/isis/applib/GlobSpec.java
new file mode 100644
index 0000000..c5ede73
--- /dev/null
+++ b/core/applib/src/main/java/org/apache/isis/applib/GlobSpec.java
@@ -0,0 +1,134 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+
+package org.apache.isis.applib;
+
+import java.util.List;
+import java.util.Map;
+
+import org.apache.isis.applib.fixturescripts.FixtureScript;
+
+/**
+ * Specifies the "glob", in other words the set of modules (containing domain services and possibly entities), that
+ * together make up the running application.
+ *
+ * <p>
+ * To use, implement this interface and then define as the <tt>isis.globspec</tt> key within the
+ * <tt>isis.properties</tt> configuration file, or programmatically.
+ * </p>
+ *
+ * <p>
+ * The intention is to centralize, so far as possible, the configuration that previously has been duplicated between
+ * the <tt>xxx-integtests</tt> (Maven) module and the <tt>xxx-webapp</tt> integtests.
+ * </p>
+ *
+ * <p>
+ * There are a number of subsidiary goals:
+ * <ul>
+ *     <li>
+ *         <p>
+ *             by having multiple classes implementing this interface, it allows separate "profiles" of the application
+ *             to be run.
+ *         </p>
+ *         <p>For example, a developer could define a globspec that</p>
+ *         <ul>
+ *             <li>uses the <tt>bypass</tt> security rather than the full-blown Shiro security</li>
+ *             <li>excludes some or all addon modules, eg auditing and security</li>
+ *             <li>for a large app whose domain has been broken out into multiple <tt>dom-xxx</tt> (Maven) modules, to
+ *                 run subsets of the application</li>
+ *         </ul>
+ *         <p>This applies to both running the main app and also the integration tests.</p>
+ *    </li>
+ *    <li>
+ *        <p>Allow different integration tests to run with different globspecs.  Normally the running application is
+ *           shared (on a thread-local) between integration tests.  What the framework could do is to be intelligent
+ *           enough to keep track of the globspec used for each integration test and tear down
+ *           the shared state if the "next" test uses a different globspec</p>
+ *    </li>
+ *    <li>
+ *        Speed up bootstrapping by only scanning for classes annotated by
+ *        {@link org.apache.isis.applib.annotation.DomainService} and {@link javax.jdo.annotations.PersistenceCapable}
+ *        once.
+ *    </li>
+ *    <li>
+ *        Provide a programmatic way to contribute elements of `web.xml`.  This is not yet implemented.
+ *    </li>
+ *    <li>
+ *        Provide a programmatic way to configure Shiro security.  This is not yet implemented.
+ *    </li>
+ *    <li>
+ *        <p>Anticipate the module changes forthcoming in Java 9.  Eventually we see that the globspec class will
+ *        become an application manifest, while the list of modules will become Java 9 modules each advertising the
+ *        types that they export.</p>
+ *    </li>
+ * </ul>
+ * </p>
+ * <p>
+ *     <b>Note:</b> at this time the integration tests do not keep track of different globspecs; rather the
+ *     globspec used for the first test is used for all subsequent tests.
+ * </p>
+ */
+public interface GlobSpec {
+
+    /**
+     * A list of classes, each of which representing the root of one of the modules containing services and possibly
+     * entities, which together makes up the running application.
+     *
+     * <p>
+     *     The package of each such class is used as the basis for searching for domain services and registered
+     *     entities.  As such it replaces and overrides both the
+     *     <tt>isis.services.ServicesInstallerFromAnnotation.packagePrefix</tt> key (usually found in the
+     *     <tt>isis.properties</tt> file) and the
+     *     <tt>isis.persistor.datanucleus.RegisterEntities.packagePrefix</tt> key (usually found in the
+     *     <tt>persistor_datanucleus.properties</tt> file).
+     * </p>
+     *
+     * <p>
+     *     If a globspec has been provided then the value of <tt>isis.services-installer</tt> configuration property
+     *     will be ignored and the <tt>isis.services</tt> configuration property will also be ignored.
+     * </p>
+     *
+     * <p>
+     *     Note: the class implementing this interface will typically include itself in the list of classes, so that any
+     *     "global" services (for example an application home page) are also picked up.
+     * </p>
+     */
+    public List<Class<?>> getModules();
+
+    /**
+     * If non-null, overrides the value of <tt>isis.authentication</tt> configuration property.
+     */
+    public String getAuthenticationMechanism();
+
+    /**
+     * If non-null, overrides the value of <tt>isis.authorization</tt> configuration property.
+     */
+    public String getAuthorizationMechanism();
+
+    /**
+     * If non-null, overrides the value of <tt>isis.fixtures</tt> configuration property.
+     */
+    public List<FixtureScript> getFixtures();
+
+    /**
+     * Overrides for any other configuration properties.
+     */
+    public Map<String,String> getConfiguration();
+
+}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/DomainAppDomainModule.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/DomainAppDomainModule.java b/example/application/simpleapp/dom/src/main/java/domainapp/dom/DomainAppDomainModule.java
new file mode 100644
index 0000000..1818053
--- /dev/null
+++ b/example/application/simpleapp/dom/src/main/java/domainapp/dom/DomainAppDomainModule.java
@@ -0,0 +1,24 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+package domainapp.dom;
+
+public final class DomainAppDomainModule {
+
+
+}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageService.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageService.java b/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageService.java
deleted file mode 100644
index 641c39a..0000000
--- a/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageService.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- */
-package domainapp.dom.app.homepage;
-
-import org.apache.isis.applib.DomainObjectContainer;
-import org.apache.isis.applib.annotation.Action;
-import org.apache.isis.applib.annotation.DomainService;
-import org.apache.isis.applib.annotation.HomePage;
-import org.apache.isis.applib.annotation.NatureOfService;
-import org.apache.isis.applib.annotation.SemanticsOf;
-
-@DomainService(
-        nature = NatureOfService.VIEW_CONTRIBUTIONS_ONLY // trick to suppress the actions from the top-level menu
-)
-public class HomePageService {
-
-    //region > homePage (action)
-
-    @Action(
-            semantics = SemanticsOf.SAFE
-    )
-    @HomePage
-    public HomePageViewModel homePage() {
-        return container.injectServicesInto(new HomePageViewModel());
-    }
-
-    //endregion
-
-    //region > injected services
-
-    @javax.inject.Inject
-    DomainObjectContainer container;
-
-    //endregion
-}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.java b/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.java
deleted file mode 100644
index 83015d0..0000000
--- a/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- */
-package domainapp.dom.app.homepage;
-
-import java.util.List;
-
-import org.apache.isis.applib.annotation.ViewModel;
-
-import domainapp.dom.modules.simple.SimpleObject;
-import domainapp.dom.modules.simple.SimpleObjects;
-
-@ViewModel
-public class HomePageViewModel {
-
-    //region > title
-    public String title() {
-        return getObjects().size() + " objects";
-    }
-    //endregion
-
-    //region > object (collection)
-    @org.apache.isis.applib.annotation.HomePage
-    public List<SimpleObject> getObjects() {
-        return simpleObjects.listAll();
-    }
-    //endregion
-
-    //region > injected services
-
-    @javax.inject.Inject
-    SimpleObjects simpleObjects;
-
-    //endregion
-}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.layout.json
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.layout.json b/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.layout.json
deleted file mode 100644
index 34f78e0..0000000
--- a/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.layout.json
+++ /dev/null
@@ -1,43 +0,0 @@
-/**
- *  Licensed to the Apache Software Foundation (ASF) under one or more
- *  contributor license agreements.  See the NOTICE file distributed with
- *  this work for additional information regarding copyright ownership.
- *  The ASF licenses this file to You under the Apache License, Version 2.0
- *  (the "License"); you may not use this file except in compliance with
- *  the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-{
-    "columns": [
-        {
-            "span": 0,
-            "memberGroups": {}
-        },
-        {
-            "span": 0,
-            "memberGroups": {}
-        },
-        {
-            "span": 0,
-            "memberGroups": {}
-        },
-        {
-            "span": 12,
-            "collections": {
-                "objects": {
-                    "collectionLayout": {
-                        "render": "EAGERLY"
-                    }
-                }
-            }
-        }
-    ],
-    "actions": {}
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.png
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.png b/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.png
deleted file mode 100644
index cb03785..0000000
Binary files a/example/application/simpleapp/dom/src/main/java/domainapp/dom/app/homepage/HomePageViewModel.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.java b/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.java
deleted file mode 100644
index a4fba6d..0000000
--- a/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- */
-package domainapp.dom.modules.simple;
-
-import javax.jdo.JDOHelper;
-import javax.jdo.annotations.IdentityType;
-import javax.jdo.annotations.VersionStrategy;
-
-import org.apache.isis.applib.DomainObjectContainer;
-import org.apache.isis.applib.Identifier;
-import org.apache.isis.applib.annotation.Action;
-import org.apache.isis.applib.annotation.BookmarkPolicy;
-import org.apache.isis.applib.annotation.DomainObject;
-import org.apache.isis.applib.annotation.DomainObjectLayout;
-import org.apache.isis.applib.annotation.Editing;
-import org.apache.isis.applib.annotation.Parameter;
-import org.apache.isis.applib.annotation.ParameterLayout;
-import org.apache.isis.applib.annotation.Property;
-import org.apache.isis.applib.annotation.Title;
-import org.apache.isis.applib.services.eventbus.ActionDomainEvent;
-import org.apache.isis.applib.services.i18n.TranslatableString;
-import org.apache.isis.applib.util.ObjectContracts;
-
-@javax.jdo.annotations.PersistenceCapable(
-        identityType=IdentityType.DATASTORE,
-        schema = "simple",
-        table = "SimpleObject"
-)
-@javax.jdo.annotations.DatastoreIdentity(
-        strategy=javax.jdo.annotations.IdGeneratorStrategy.IDENTITY,
-         column="id")
-@javax.jdo.annotations.Version(
-        strategy=VersionStrategy.VERSION_NUMBER, 
-        column="version")
-@javax.jdo.annotations.Queries({
-        @javax.jdo.annotations.Query(
-                name = "find", language = "JDOQL",
-                value = "SELECT "
-                        + "FROM domainapp.dom.modules.simple.SimpleObject "),
-        @javax.jdo.annotations.Query(
-                name = "findByName", language = "JDOQL",
-                value = "SELECT "
-                        + "FROM domainapp.dom.modules.simple.SimpleObject "
-                        + "WHERE name.indexOf(:name) >= 0 ")
-})
-@javax.jdo.annotations.Unique(name="SimpleObject_name_UNQ", members = {"name"})
-@DomainObject
-@DomainObjectLayout(
-        bookmarking = BookmarkPolicy.AS_ROOT,
-        cssClassFa = "fa-flag"
-)
-public class SimpleObject implements Comparable<SimpleObject> {
-
-
-    //region > identificatiom
-    public TranslatableString title() {
-        return TranslatableString.tr("Object: {name}", "name", getName());
-    }
-    //endregion
-
-    //region > name (property)
-
-    private String name;
-
-    @javax.jdo.annotations.Column(allowsNull="false", length = 40)
-    @Title(sequence="1")
-    @Property(
-            editing = Editing.DISABLED
-    )
-    public String getName() {
-        return name;
-    }
-
-    public void setName(final String name) {
-        this.name = name;
-    }
-
-    // endregion
-
-    //region > updateName (action)
-
-    public static class UpdateNameDomainEvent extends ActionDomainEvent<SimpleObject> {
-        public UpdateNameDomainEvent(final SimpleObject source, final Identifier identifier, final Object... arguments) {
-            super(source, identifier, arguments);
-        }
-    }
-
-    @Action(
-            domainEvent = UpdateNameDomainEvent.class
-    )
-    public SimpleObject updateName(
-            @Parameter(maxLength = 40)
-            @ParameterLayout(named = "New name")
-            final String name) {
-        setName(name);
-        return this;
-    }
-
-    public String default0UpdateName() {
-        return getName();
-    }
-
-    public TranslatableString validateUpdateName(final String name) {
-        return name.contains("!")? TranslatableString.tr("Exclamation mark is not allowed"): null;
-    }
-
-    //endregion
-
-    //region > version (derived property)
-    public Long getVersionSequence() {
-        return (Long) JDOHelper.getVersion(this);
-    }
-    //endregion
-
-    //region > compareTo
-
-    @Override
-    public int compareTo(final SimpleObject other) {
-        return ObjectContracts.compare(this, other, "name");
-    }
-
-    //endregion
-
-    //region > injected services
-
-    @javax.inject.Inject
-    @SuppressWarnings("unused")
-    private DomainObjectContainer container;
-
-    //endregion
-
-
-}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.layout.json
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.layout.json b/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.layout.json
deleted file mode 100644
index 3d5e23f..0000000
--- a/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.layout.json
+++ /dev/null
@@ -1,56 +0,0 @@
-/**
- *  Licensed to the Apache Software Foundation (ASF) under one or more
- *  contributor license agreements.  See the NOTICE file distributed with
- *  this work for additional information regarding copyright ownership.
- *  The ASF licenses this file to You under the Apache License, Version 2.0
- *  (the "License"); you may not use this file except in compliance with
- *  the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-{
-    "columns": [
-        {
-            "span": 6,
-            "memberGroups": {
-                "General": {
-                    "members": {
-                        "name": {
-                            "actions": {
-                                "updateName": {
-                                    "actionLayout": {
-                                        "position": "BOTTOM"
-                                    }
-                                }
-                            }
-                        },
-                        "versionSequence": {
-                            "propertyLayout": {
-                                "name": "version"
-                            }
-                        }
-                    }
-                }
-            }
-        },
-        {
-            "span": 0,
-            "memberGroups": {}
-        },
-        {
-            "span": 0,
-            "memberGroups": {}
-        },
-        {
-            "span": 6,
-            "collections": {}
-        }
-    ],
-    "actions": {}
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.png
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.png b/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.png
deleted file mode 100644
index 0bd6f57..0000000
Binary files a/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObject.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObjects.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObjects.java b/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObjects.java
deleted file mode 100644
index 0634dd1..0000000
--- a/example/application/simpleapp/dom/src/main/java/domainapp/dom/modules/simple/SimpleObjects.java
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- */
-package domainapp.dom.modules.simple;
-
-import java.util.List;
-
-import org.apache.isis.applib.DomainObjectContainer;
-import org.apache.isis.applib.Identifier;
-import org.apache.isis.applib.annotation.Action;
-import org.apache.isis.applib.annotation.ActionLayout;
-import org.apache.isis.applib.annotation.BookmarkPolicy;
-import org.apache.isis.applib.annotation.DomainService;
-import org.apache.isis.applib.annotation.DomainServiceLayout;
-import org.apache.isis.applib.annotation.MemberOrder;
-import org.apache.isis.applib.annotation.ParameterLayout;
-import org.apache.isis.applib.annotation.SemanticsOf;
-import org.apache.isis.applib.query.QueryDefault;
-import org.apache.isis.applib.services.eventbus.ActionDomainEvent;
-import org.apache.isis.applib.services.i18n.TranslatableString;
-
-@DomainService(repositoryFor = SimpleObject.class)
-@DomainServiceLayout(menuOrder = "10")
-public class SimpleObjects {
-
-    //region > title
-    public TranslatableString title() {
-        return TranslatableString.tr("Simple Objects");
-    }
-    //endregion
-
-    //region > listAll (action)
-    @Action(
-            semantics = SemanticsOf.SAFE
-    )
-    @ActionLayout(
-            bookmarking = BookmarkPolicy.AS_ROOT
-    )
-    @MemberOrder(sequence = "1")
-    public List<SimpleObject> listAll() {
-        return container.allInstances(SimpleObject.class);
-    }
-    //endregion
-
-    //region > findByName (action)
-    @Action(
-            semantics = SemanticsOf.SAFE
-    )
-    @ActionLayout(
-            bookmarking = BookmarkPolicy.AS_ROOT
-    )
-    @MemberOrder(sequence = "2")
-    public List<SimpleObject> findByName(
-            @ParameterLayout(named="Name")
-            final String name
-    ) {
-        return container.allMatches(
-                new QueryDefault<>(
-                        SimpleObject.class,
-                        "findByName",
-                        "name", name));
-    }
-    //endregion
-
-    //region > create (action)
-    public static class CreateDomainEvent extends ActionDomainEvent<SimpleObjects> {
-        public CreateDomainEvent(final SimpleObjects source, final Identifier identifier, final Object... arguments) {
-            super(source, identifier, arguments);
-        }
-    }
-
-    @Action(
-            domainEvent = CreateDomainEvent.class
-    )
-    @MemberOrder(sequence = "3")
-    public SimpleObject create(
-            final @ParameterLayout(named="Name") String name) {
-        final SimpleObject obj = container.newTransientInstance(SimpleObject.class);
-        obj.setName(name);
-        container.persistIfNotAlready(obj);
-        return obj;
-    }
-
-    //endregion
-
-    //region > injected services
-
-    @javax.inject.Inject 
-    DomainObjectContainer container;
-
-    //endregion
-}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.java b/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.java
new file mode 100644
index 0000000..1bd9c35
--- /dev/null
+++ b/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.java
@@ -0,0 +1,149 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+package domainapp.dom.simple;
+
+import javax.jdo.JDOHelper;
+import javax.jdo.annotations.IdentityType;
+import javax.jdo.annotations.VersionStrategy;
+
+import org.apache.isis.applib.DomainObjectContainer;
+import org.apache.isis.applib.Identifier;
+import org.apache.isis.applib.annotation.Action;
+import org.apache.isis.applib.annotation.BookmarkPolicy;
+import org.apache.isis.applib.annotation.DomainObject;
+import org.apache.isis.applib.annotation.DomainObjectLayout;
+import org.apache.isis.applib.annotation.Editing;
+import org.apache.isis.applib.annotation.Parameter;
+import org.apache.isis.applib.annotation.ParameterLayout;
+import org.apache.isis.applib.annotation.Property;
+import org.apache.isis.applib.annotation.Title;
+import org.apache.isis.applib.services.eventbus.ActionDomainEvent;
+import org.apache.isis.applib.services.i18n.TranslatableString;
+import org.apache.isis.applib.util.ObjectContracts;
+
+@javax.jdo.annotations.PersistenceCapable(
+        identityType=IdentityType.DATASTORE,
+        schema = "simple",
+        table = "SimpleObject"
+)
+@javax.jdo.annotations.DatastoreIdentity(
+        strategy=javax.jdo.annotations.IdGeneratorStrategy.IDENTITY,
+         column="id")
+@javax.jdo.annotations.Version(
+        strategy=VersionStrategy.VERSION_NUMBER, 
+        column="version")
+@javax.jdo.annotations.Queries({
+        @javax.jdo.annotations.Query(
+                name = "find", language = "JDOQL",
+                value = "SELECT "
+                        + "FROM domainapp.dom.modules.simple.SimpleObject "),
+        @javax.jdo.annotations.Query(
+                name = "findByName", language = "JDOQL",
+                value = "SELECT "
+                        + "FROM domainapp.dom.modules.simple.SimpleObject "
+                        + "WHERE name.indexOf(:name) >= 0 ")
+})
+@javax.jdo.annotations.Unique(name="SimpleObject_name_UNQ", members = {"name"})
+@DomainObject
+@DomainObjectLayout(
+        bookmarking = BookmarkPolicy.AS_ROOT,
+        cssClassFa = "fa-flag"
+)
+public class SimpleObject implements Comparable<SimpleObject> {
+
+
+    //region > identificatiom
+    public TranslatableString title() {
+        return TranslatableString.tr("Object: {name}", "name", getName());
+    }
+    //endregion
+
+    //region > name (property)
+
+    private String name;
+
+    @javax.jdo.annotations.Column(allowsNull="false", length = 40)
+    @Title(sequence="1")
+    @Property(
+            editing = Editing.DISABLED
+    )
+    public String getName() {
+        return name;
+    }
+
+    public void setName(final String name) {
+        this.name = name;
+    }
+
+    // endregion
+
+    //region > updateName (action)
+
+    public static class UpdateNameDomainEvent extends ActionDomainEvent<SimpleObject> {
+        public UpdateNameDomainEvent(final SimpleObject source, final Identifier identifier, final Object... arguments) {
+            super(source, identifier, arguments);
+        }
+    }
+
+    @Action(
+            domainEvent = UpdateNameDomainEvent.class
+    )
+    public SimpleObject updateName(
+            @Parameter(maxLength = 40)
+            @ParameterLayout(named = "New name")
+            final String name) {
+        setName(name);
+        return this;
+    }
+
+    public String default0UpdateName() {
+        return getName();
+    }
+
+    public TranslatableString validateUpdateName(final String name) {
+        return name.contains("!")? TranslatableString.tr("Exclamation mark is not allowed"): null;
+    }
+
+    //endregion
+
+    //region > version (derived property)
+    public Long getVersionSequence() {
+        return (Long) JDOHelper.getVersion(this);
+    }
+    //endregion
+
+    //region > compareTo
+
+    @Override
+    public int compareTo(final SimpleObject other) {
+        return ObjectContracts.compare(this, other, "name");
+    }
+
+    //endregion
+
+    //region > injected services
+
+    @javax.inject.Inject
+    @SuppressWarnings("unused")
+    private DomainObjectContainer container;
+
+    //endregion
+
+
+}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.layout.json
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.layout.json b/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.layout.json
new file mode 100644
index 0000000..3d5e23f
--- /dev/null
+++ b/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.layout.json
@@ -0,0 +1,56 @@
+/**
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+{
+    "columns": [
+        {
+            "span": 6,
+            "memberGroups": {
+                "General": {
+                    "members": {
+                        "name": {
+                            "actions": {
+                                "updateName": {
+                                    "actionLayout": {
+                                        "position": "BOTTOM"
+                                    }
+                                }
+                            }
+                        },
+                        "versionSequence": {
+                            "propertyLayout": {
+                                "name": "version"
+                            }
+                        }
+                    }
+                }
+            }
+        },
+        {
+            "span": 0,
+            "memberGroups": {}
+        },
+        {
+            "span": 0,
+            "memberGroups": {}
+        },
+        {
+            "span": 6,
+            "collections": {}
+        }
+    ],
+    "actions": {}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.png
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.png b/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.png
new file mode 100644
index 0000000..0bd6f57
Binary files /dev/null and b/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObject.png differ

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObjects.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObjects.java b/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObjects.java
new file mode 100644
index 0000000..ea629d5
--- /dev/null
+++ b/example/application/simpleapp/dom/src/main/java/domainapp/dom/simple/SimpleObjects.java
@@ -0,0 +1,107 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+package domainapp.dom.simple;
+
+import java.util.List;
+
+import org.apache.isis.applib.DomainObjectContainer;
+import org.apache.isis.applib.Identifier;
+import org.apache.isis.applib.annotation.Action;
+import org.apache.isis.applib.annotation.ActionLayout;
+import org.apache.isis.applib.annotation.BookmarkPolicy;
+import org.apache.isis.applib.annotation.DomainService;
+import org.apache.isis.applib.annotation.DomainServiceLayout;
+import org.apache.isis.applib.annotation.MemberOrder;
+import org.apache.isis.applib.annotation.ParameterLayout;
+import org.apache.isis.applib.annotation.SemanticsOf;
+import org.apache.isis.applib.query.QueryDefault;
+import org.apache.isis.applib.services.eventbus.ActionDomainEvent;
+import org.apache.isis.applib.services.i18n.TranslatableString;
+
+@DomainService(repositoryFor = SimpleObject.class)
+@DomainServiceLayout(menuOrder = "10")
+public class SimpleObjects {
+
+    //region > title
+    public TranslatableString title() {
+        return TranslatableString.tr("Simple Objects");
+    }
+    //endregion
+
+    //region > listAll (action)
+    @Action(
+            semantics = SemanticsOf.SAFE
+    )
+    @ActionLayout(
+            bookmarking = BookmarkPolicy.AS_ROOT
+    )
+    @MemberOrder(sequence = "1")
+    public List<SimpleObject> listAll() {
+        return container.allInstances(SimpleObject.class);
+    }
+    //endregion
+
+    //region > findByName (action)
+    @Action(
+            semantics = SemanticsOf.SAFE
+    )
+    @ActionLayout(
+            bookmarking = BookmarkPolicy.AS_ROOT
+    )
+    @MemberOrder(sequence = "2")
+    public List<SimpleObject> findByName(
+            @ParameterLayout(named="Name")
+            final String name
+    ) {
+        return container.allMatches(
+                new QueryDefault<>(
+                        SimpleObject.class,
+                        "findByName",
+                        "name", name));
+    }
+    //endregion
+
+    //region > create (action)
+    public static class CreateDomainEvent extends ActionDomainEvent<SimpleObjects> {
+        public CreateDomainEvent(final SimpleObjects source, final Identifier identifier, final Object... arguments) {
+            super(source, identifier, arguments);
+        }
+    }
+
+    @Action(
+            domainEvent = CreateDomainEvent.class
+    )
+    @MemberOrder(sequence = "3")
+    public SimpleObject create(
+            final @ParameterLayout(named="Name") String name) {
+        final SimpleObject obj = container.newTransientInstance(SimpleObject.class);
+        obj.setName(name);
+        container.persistIfNotAlready(obj);
+        return obj;
+    }
+
+    //endregion
+
+    //region > injected services
+
+    @javax.inject.Inject 
+    DomainObjectContainer container;
+
+    //endregion
+}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/test/java/domainapp/dom/modules/simple/SimpleObjectTest.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/test/java/domainapp/dom/modules/simple/SimpleObjectTest.java b/example/application/simpleapp/dom/src/test/java/domainapp/dom/modules/simple/SimpleObjectTest.java
deleted file mode 100644
index e29b3f2..0000000
--- a/example/application/simpleapp/dom/src/test/java/domainapp/dom/modules/simple/SimpleObjectTest.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/**
- *  Licensed to the Apache Software Foundation (ASF) under one or more
- *  contributor license agreements.  See the NOTICE file distributed with
- *  this work for additional information regarding copyright ownership.
- *  The ASF licenses this file to You under the Apache License, Version 2.0
- *  (the "License"); you may not use this file except in compliance with
- *  the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package domainapp.dom.modules.simple;
-
-import org.junit.Before;
-import org.junit.Test;
-
-import static org.assertj.core.api.Assertions.assertThat;
-
-public class SimpleObjectTest {
-
-    SimpleObject simpleObject;
-
-    @Before
-    public void setUp() throws Exception {
-        simpleObject = new SimpleObject();
-    }
-
-    public static class Name extends SimpleObjectTest {
-
-        @Test
-        public void happyCase() throws Exception {
-            // given
-            String name = "Foobar";
-            assertThat(simpleObject.getName()).isNull();
-
-            // when
-            simpleObject.setName(name);
-
-            // then
-            assertThat(simpleObject.getName()).isEqualTo(name);
-        }
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/test/java/domainapp/dom/modules/simple/SimpleObjectsTest.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/test/java/domainapp/dom/modules/simple/SimpleObjectsTest.java b/example/application/simpleapp/dom/src/test/java/domainapp/dom/modules/simple/SimpleObjectsTest.java
deleted file mode 100644
index a41d25a..0000000
--- a/example/application/simpleapp/dom/src/test/java/domainapp/dom/modules/simple/SimpleObjectsTest.java
+++ /dev/null
@@ -1,104 +0,0 @@
-/**
- *  Licensed to the Apache Software Foundation (ASF) under one or more
- *  contributor license agreements.  See the NOTICE file distributed with
- *  this work for additional information regarding copyright ownership.
- *  The ASF licenses this file to You under the Apache License, Version 2.0
- *  (the "License"); you may not use this file except in compliance with
- *  the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package domainapp.dom.modules.simple;
-
-import java.util.List;
-
-import com.google.common.collect.Lists;
-
-import org.jmock.Expectations;
-import org.jmock.Sequence;
-import org.jmock.auto.Mock;
-import org.junit.Before;
-import org.junit.Rule;
-import org.junit.Test;
-
-import org.apache.isis.applib.DomainObjectContainer;
-import org.apache.isis.core.unittestsupport.jmocking.JUnitRuleMockery2;
-import org.apache.isis.core.unittestsupport.jmocking.JUnitRuleMockery2.Mode;
-
-import static org.assertj.core.api.Assertions.assertThat;
-
-public class SimpleObjectsTest {
-
-    @Rule
-    public JUnitRuleMockery2 context = JUnitRuleMockery2.createFor(Mode.INTERFACES_AND_CLASSES);
-
-    @Mock
-    DomainObjectContainer mockContainer;
-    
-    SimpleObjects simpleObjects;
-
-    @Before
-    public void setUp() throws Exception {
-        simpleObjects = new SimpleObjects();
-        simpleObjects.container = mockContainer;
-    }
-
-    public static class Create extends SimpleObjectsTest {
-
-        @Test
-        public void happyCase() throws Exception {
-
-            // given
-            final SimpleObject simpleObject = new SimpleObject();
-
-            final Sequence seq = context.sequence("create");
-            context.checking(new Expectations() {
-                {
-                    oneOf(mockContainer).newTransientInstance(SimpleObject.class);
-                    inSequence(seq);
-                    will(returnValue(simpleObject));
-
-                    oneOf(mockContainer).persistIfNotAlready(simpleObject);
-                    inSequence(seq);
-                }
-            });
-
-            // when
-            final SimpleObject obj = simpleObjects.create("Foobar");
-
-            // then
-            assertThat(obj).isEqualTo(simpleObject);
-            assertThat(obj.getName()).isEqualTo("Foobar");
-        }
-
-    }
-
-    public static class ListAll extends SimpleObjectsTest {
-
-        @Test
-        public void happyCase() throws Exception {
-
-            // given
-            final List<SimpleObject> all = Lists.newArrayList();
-
-            context.checking(new Expectations() {
-                {
-                    oneOf(mockContainer).allInstances(SimpleObject.class);
-                    will(returnValue(all));
-                }
-            });
-
-            // when
-            final List<SimpleObject> list = simpleObjects.listAll();
-
-            // then
-            assertThat(list).isEqualTo(all);
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/test/java/domainapp/dom/simple/SimpleObjectTest.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/test/java/domainapp/dom/simple/SimpleObjectTest.java b/example/application/simpleapp/dom/src/test/java/domainapp/dom/simple/SimpleObjectTest.java
new file mode 100644
index 0000000..b9dbcb4
--- /dev/null
+++ b/example/application/simpleapp/dom/src/test/java/domainapp/dom/simple/SimpleObjectTest.java
@@ -0,0 +1,49 @@
+/**
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package domainapp.dom.simple;
+
+import org.junit.Before;
+import org.junit.Test;
+
+import static org.assertj.core.api.Assertions.assertThat;
+
+public class SimpleObjectTest {
+
+    SimpleObject simpleObject;
+
+    @Before
+    public void setUp() throws Exception {
+        simpleObject = new SimpleObject();
+    }
+
+    public static class Name extends SimpleObjectTest {
+
+        @Test
+        public void happyCase() throws Exception {
+            // given
+            String name = "Foobar";
+            assertThat(simpleObject.getName()).isNull();
+
+            // when
+            simpleObject.setName(name);
+
+            // then
+            assertThat(simpleObject.getName()).isEqualTo(name);
+        }
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/dom/src/test/java/domainapp/dom/simple/SimpleObjectsTest.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/dom/src/test/java/domainapp/dom/simple/SimpleObjectsTest.java b/example/application/simpleapp/dom/src/test/java/domainapp/dom/simple/SimpleObjectsTest.java
new file mode 100644
index 0000000..13dce0b
--- /dev/null
+++ b/example/application/simpleapp/dom/src/test/java/domainapp/dom/simple/SimpleObjectsTest.java
@@ -0,0 +1,104 @@
+/**
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package domainapp.dom.simple;
+
+import java.util.List;
+
+import com.google.common.collect.Lists;
+
+import org.jmock.Expectations;
+import org.jmock.Sequence;
+import org.jmock.auto.Mock;
+import org.junit.Before;
+import org.junit.Rule;
+import org.junit.Test;
+
+import org.apache.isis.applib.DomainObjectContainer;
+import org.apache.isis.core.unittestsupport.jmocking.JUnitRuleMockery2;
+import org.apache.isis.core.unittestsupport.jmocking.JUnitRuleMockery2.Mode;
+
+import static org.assertj.core.api.Assertions.assertThat;
+
+public class SimpleObjectsTest {
+
+    @Rule
+    public JUnitRuleMockery2 context = JUnitRuleMockery2.createFor(Mode.INTERFACES_AND_CLASSES);
+
+    @Mock
+    DomainObjectContainer mockContainer;
+    
+    SimpleObjects simpleObjects;
+
+    @Before
+    public void setUp() throws Exception {
+        simpleObjects = new SimpleObjects();
+        simpleObjects.container = mockContainer;
+    }
+
+    public static class Create extends SimpleObjectsTest {
+
+        @Test
+        public void happyCase() throws Exception {
+
+            // given
+            final SimpleObject simpleObject = new SimpleObject();
+
+            final Sequence seq = context.sequence("create");
+            context.checking(new Expectations() {
+                {
+                    oneOf(mockContainer).newTransientInstance(SimpleObject.class);
+                    inSequence(seq);
+                    will(returnValue(simpleObject));
+
+                    oneOf(mockContainer).persistIfNotAlready(simpleObject);
+                    inSequence(seq);
+                }
+            });
+
+            // when
+            final SimpleObject obj = simpleObjects.create("Foobar");
+
+            // then
+            assertThat(obj).isEqualTo(simpleObject);
+            assertThat(obj.getName()).isEqualTo("Foobar");
+        }
+
+    }
+
+    public static class ListAll extends SimpleObjectsTest {
+
+        @Test
+        public void happyCase() throws Exception {
+
+            // given
+            final List<SimpleObject> all = Lists.newArrayList();
+
+            context.checking(new Expectations() {
+                {
+                    oneOf(mockContainer).allInstances(SimpleObject.class);
+                    will(returnValue(all));
+                }
+            });
+
+            // when
+            final List<SimpleObject> list = simpleObjects.listAll();
+
+            // then
+            assertThat(list).isEqualTo(all);
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/fixture/src/main/java/domainapp/fixture/modules/simple/SimpleObjectCreate.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/fixture/src/main/java/domainapp/fixture/modules/simple/SimpleObjectCreate.java b/example/application/simpleapp/fixture/src/main/java/domainapp/fixture/modules/simple/SimpleObjectCreate.java
index 926217d..b23f2be 100644
--- a/example/application/simpleapp/fixture/src/main/java/domainapp/fixture/modules/simple/SimpleObjectCreate.java
+++ b/example/application/simpleapp/fixture/src/main/java/domainapp/fixture/modules/simple/SimpleObjectCreate.java
@@ -21,8 +21,8 @@ package domainapp.fixture.modules.simple;
 
 import org.apache.isis.applib.fixturescripts.FixtureScript;
 
-import domainapp.dom.modules.simple.SimpleObject;
-import domainapp.dom.modules.simple.SimpleObjects;
+import domainapp.dom.simple.SimpleObject;
+import domainapp.dom.simple.SimpleObjects;
 
 public class SimpleObjectCreate extends FixtureScript {
 

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/fixture/src/main/java/domainapp/fixture/scenarios/RecreateSimpleObjects.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/fixture/src/main/java/domainapp/fixture/scenarios/RecreateSimpleObjects.java b/example/application/simpleapp/fixture/src/main/java/domainapp/fixture/scenarios/RecreateSimpleObjects.java
index 072769e..6b8943b 100644
--- a/example/application/simpleapp/fixture/src/main/java/domainapp/fixture/scenarios/RecreateSimpleObjects.java
+++ b/example/application/simpleapp/fixture/src/main/java/domainapp/fixture/scenarios/RecreateSimpleObjects.java
@@ -27,7 +27,7 @@ import com.google.common.collect.Lists;
 
 import org.apache.isis.applib.fixturescripts.FixtureScript;
 
-import domainapp.dom.modules.simple.SimpleObject;
+import domainapp.dom.simple.SimpleObject;
 import domainapp.fixture.modules.simple.SimpleObjectCreate;
 import domainapp.fixture.modules.simple.SimpleObjectsTearDown;
 

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/glob/pom.xml
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/glob/pom.xml b/example/application/simpleapp/glob/pom.xml
new file mode 100644
index 0000000..0281d43
--- /dev/null
+++ b/example/application/simpleapp/glob/pom.xml
@@ -0,0 +1,77 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+  
+         http://www.apache.org/licenses/LICENSE-2.0
+         
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.isis.example.application</groupId>
+        <artifactId>simpleapp</artifactId>
+        <version>1.9.0-SNAPSHOT</version>
+    </parent>
+
+    <artifactId>simpleapp-glob</artifactId>
+    <name>Simple App Glob</name>
+
+    <build>
+        <resources>
+            <resource>
+                <filtering>false</filtering>
+                <directory>src/main/resources</directory>
+            </resource>
+            <resource>
+                <filtering>false</filtering>
+                <directory>src/main/java</directory>
+                <includes>
+                    <include>**</include>
+                </includes>
+                <excludes>
+                    <exclude>**/*.java</exclude>
+                </excludes>
+            </resource>
+        </resources>
+    </build>
+
+    <dependencies>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>simpleapp-dom</artifactId>
+            <exclusions>
+                <exclusion>
+                    <!-- so don't pick up transitive dependency to asm 4.0.0 -->
+                    <groupId>org.datanucleus</groupId>
+                    <artifactId>datanucleus-enhancer</artifactId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>simpleapp-fixture</artifactId>
+            <exclusions>
+                <exclusion>
+                    <!-- so don't pick up transitive dependency to asm 4.0.0 -->
+                    <groupId>org.datanucleus</groupId>
+                    <artifactId>datanucleus-enhancer</artifactId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+
+    </dependencies>
+
+</project>

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/glob/src/main/java/domainapp/glob/DomainAppGlobSpec.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/glob/src/main/java/domainapp/glob/DomainAppGlobSpec.java b/example/application/simpleapp/glob/src/main/java/domainapp/glob/DomainAppGlobSpec.java
new file mode 100644
index 0000000..552cd32
--- /dev/null
+++ b/example/application/simpleapp/glob/src/main/java/domainapp/glob/DomainAppGlobSpec.java
@@ -0,0 +1,60 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+package domainapp.glob;
+
+import java.util.Arrays;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.isis.applib.GlobSpec;
+import org.apache.isis.applib.fixturescripts.FixtureScript;
+
+import domainapp.dom.DomainAppDomainModule;
+
+public final class DomainAppGlobSpec implements GlobSpec {
+
+    @Override
+    public List<Class<?>> getModules() {
+        return Arrays.asList(
+                DomainAppDomainModule.class,
+                DomainAppGlobSpec.class
+        );
+    }
+
+    @Override
+    public String getAuthenticationMechanism() {
+        return null;
+    }
+
+    @Override
+    public String getAuthorizationMechanism() {
+        return null;
+    }
+
+    @Override
+    public List<FixtureScript> getFixtures() {
+        return null;
+    }
+
+    @Override
+    public Map<String, String> getConfiguration() {
+        return null;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageService.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageService.java b/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageService.java
new file mode 100644
index 0000000..3870c27
--- /dev/null
+++ b/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageService.java
@@ -0,0 +1,51 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+package domainapp.glob.app.homepage;
+
+import org.apache.isis.applib.DomainObjectContainer;
+import org.apache.isis.applib.annotation.Action;
+import org.apache.isis.applib.annotation.DomainService;
+import org.apache.isis.applib.annotation.HomePage;
+import org.apache.isis.applib.annotation.NatureOfService;
+import org.apache.isis.applib.annotation.SemanticsOf;
+
+@DomainService(
+        nature = NatureOfService.VIEW_CONTRIBUTIONS_ONLY // trick to suppress the actions from the top-level menu
+)
+public class HomePageService {
+
+    //region > homePage (action)
+
+    @Action(
+            semantics = SemanticsOf.SAFE
+    )
+    @HomePage
+    public HomePageViewModel homePage() {
+        return container.injectServicesInto(new HomePageViewModel());
+    }
+
+    //endregion
+
+    //region > injected services
+
+    @javax.inject.Inject
+    DomainObjectContainer container;
+
+    //endregion
+}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.java b/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.java
new file mode 100644
index 0000000..c7c584c
--- /dev/null
+++ b/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.java
@@ -0,0 +1,50 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+package domainapp.glob.app.homepage;
+
+import java.util.List;
+
+import org.apache.isis.applib.annotation.ViewModel;
+
+import domainapp.dom.simple.SimpleObject;
+import domainapp.dom.simple.SimpleObjects;
+
+@ViewModel
+public class HomePageViewModel {
+
+    //region > title
+    public String title() {
+        return getObjects().size() + " objects";
+    }
+    //endregion
+
+    //region > object (collection)
+    @org.apache.isis.applib.annotation.HomePage
+    public List<SimpleObject> getObjects() {
+        return simpleObjects.listAll();
+    }
+    //endregion
+
+    //region > injected services
+
+    @javax.inject.Inject
+    SimpleObjects simpleObjects;
+
+    //endregion
+}

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.layout.json
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.layout.json b/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.layout.json
new file mode 100644
index 0000000..34f78e0
--- /dev/null
+++ b/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.layout.json
@@ -0,0 +1,43 @@
+/**
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+{
+    "columns": [
+        {
+            "span": 0,
+            "memberGroups": {}
+        },
+        {
+            "span": 0,
+            "memberGroups": {}
+        },
+        {
+            "span": 0,
+            "memberGroups": {}
+        },
+        {
+            "span": 12,
+            "collections": {
+                "objects": {
+                    "collectionLayout": {
+                        "render": "EAGERLY"
+                    }
+                }
+            }
+        }
+    ],
+    "actions": {}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.png
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.png b/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.png
new file mode 100644
index 0000000..cb03785
Binary files /dev/null and b/example/application/simpleapp/glob/src/main/java/domainapp/glob/app/homepage/HomePageViewModel.png differ

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/integtests/pom.xml
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/integtests/pom.xml b/example/application/simpleapp/integtests/pom.xml
index cc7ad71..d40db1d 100644
--- a/example/application/simpleapp/integtests/pom.xml
+++ b/example/application/simpleapp/integtests/pom.xml
@@ -83,10 +83,9 @@
     </build>
     <dependencies>
 
-        <!-- other modules in this project -->
         <dependency>
             <groupId>${project.groupId}</groupId>
-            <artifactId>simpleapp-fixture</artifactId>
+            <artifactId>simpleapp-glob</artifactId>
         </dependency>
 
         <dependency>

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/specglue/modules/simple/SimpleObjectGlue.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/specglue/modules/simple/SimpleObjectGlue.java b/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/specglue/modules/simple/SimpleObjectGlue.java
index 63d96bd..8263915 100644
--- a/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/specglue/modules/simple/SimpleObjectGlue.java
+++ b/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/specglue/modules/simple/SimpleObjectGlue.java
@@ -23,8 +23,8 @@ import org.apache.isis.core.specsupport.specs.CukeGlueAbstract;
 
 import cucumber.api.java.en.Given;
 import cucumber.api.java.en.When;
-import domainapp.dom.modules.simple.SimpleObject;
-import domainapp.dom.modules.simple.SimpleObjects;
+import domainapp.dom.simple.SimpleObject;
+import domainapp.dom.simple.SimpleObjects;
 import static org.hamcrest.CoreMatchers.is;
 import static org.junit.Assert.assertThat;
 

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/tests/modules/simple/SimpleObjectIntegTest.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/tests/modules/simple/SimpleObjectIntegTest.java b/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/tests/modules/simple/SimpleObjectIntegTest.java
index 610136b..5abc8cd 100644
--- a/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/tests/modules/simple/SimpleObjectIntegTest.java
+++ b/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/tests/modules/simple/SimpleObjectIntegTest.java
@@ -28,7 +28,7 @@ import org.apache.isis.applib.fixturescripts.FixtureScripts;
 import org.apache.isis.applib.services.wrapper.DisabledException;
 import org.apache.isis.applib.services.wrapper.InvalidException;
 
-import domainapp.dom.modules.simple.SimpleObject;
+import domainapp.dom.simple.SimpleObject;
 import domainapp.fixture.scenarios.RecreateSimpleObjects;
 import domainapp.integtests.tests.SimpleAppIntegTest;
 import static org.assertj.core.api.Assertions.assertThat;

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/tests/modules/simple/SimpleObjectsIntegTest.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/tests/modules/simple/SimpleObjectsIntegTest.java b/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/tests/modules/simple/SimpleObjectsIntegTest.java
index fd3b0ff..db6e3c1 100644
--- a/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/tests/modules/simple/SimpleObjectsIntegTest.java
+++ b/example/application/simpleapp/integtests/src/test/java/domainapp/integtests/tests/modules/simple/SimpleObjectsIntegTest.java
@@ -33,8 +33,8 @@ import org.junit.Test;
 import org.apache.isis.applib.fixturescripts.FixtureScript;
 import org.apache.isis.applib.fixturescripts.FixtureScripts;
 
-import domainapp.dom.modules.simple.SimpleObject;
-import domainapp.dom.modules.simple.SimpleObjects;
+import domainapp.dom.simple.SimpleObject;
+import domainapp.dom.simple.SimpleObjects;
 import domainapp.fixture.modules.simple.SimpleObjectsTearDown;
 import domainapp.fixture.scenarios.RecreateSimpleObjects;
 import domainapp.integtests.tests.SimpleAppIntegTest;

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/pom.xml
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/pom.xml b/example/application/simpleapp/pom.xml
index 9c2442d..9ac4077 100644
--- a/example/application/simpleapp/pom.xml
+++ b/example/application/simpleapp/pom.xml
@@ -334,6 +334,7 @@
     <modules>
         <module>dom</module>
         <module>fixture</module>
+        <module>glob</module>
         <module>integtests</module>
         <module>webapp</module>
     </modules>
@@ -377,6 +378,11 @@
             </dependency>
             <dependency>
                 <groupId>${project.groupId}</groupId>
+                <artifactId>simpleapp-glob</artifactId>
+                <version>${project.version}</version>
+            </dependency>
+            <dependency>
+                <groupId>${project.groupId}</groupId>
                 <artifactId>simpleapp-webapp</artifactId>
                 <version>${project.version}</version>
             </dependency>

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/webapp/pom.xml
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/webapp/pom.xml b/example/application/simpleapp/webapp/pom.xml
index 1112924..006583c 100644
--- a/example/application/simpleapp/webapp/pom.xml
+++ b/example/application/simpleapp/webapp/pom.xml
@@ -143,28 +143,9 @@
 
     <dependencies>
     
-        <!-- other modules in this project -->
         <dependency>
             <groupId>${project.groupId}</groupId>
-            <artifactId>simpleapp-dom</artifactId>
-            <exclusions>
-                <exclusion>
-                    <!-- so don't pick up transitive dependency to asm 4.0.0 -->
-                    <groupId>org.datanucleus</groupId>
-                    <artifactId>datanucleus-enhancer</artifactId>
-                </exclusion>
-            </exclusions>
-        </dependency>
-        <dependency>
-            <groupId>${project.groupId}</groupId>
-            <artifactId>simpleapp-fixture</artifactId>
-            <exclusions>
-                <exclusion>
-                    <!-- so don't pick up transitive dependency to asm 4.0.0 -->
-                    <groupId>org.datanucleus</groupId>
-                    <artifactId>datanucleus-enhancer</artifactId>
-                </exclusion>
-            </exclusions>
+            <artifactId>simpleapp-glob</artifactId>
         </dependency>
         
         <!-- other isis components -->

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/isis.properties
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/isis.properties b/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/isis.properties
index 929d177..0ec356a 100644
--- a/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/isis.properties
+++ b/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/isis.properties
@@ -38,11 +38,10 @@
 
 
 #
-# configure the persistor (object store) to use
 #
+#
+isis.globspec=domainapp.glob.DomainAppGlobSpec
 
-# JDO/DataNucleus objectstore
-isis.persistor=datanucleus
 
 
 

http://git-wip-us.apache.org/repos/asf/isis/blob/6ccf96c9/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/persistor_datanucleus.properties
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/persistor_datanucleus.properties b/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/persistor_datanucleus.properties
index 675ced3..f27533c 100644
--- a/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/persistor_datanucleus.properties
+++ b/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/persistor_datanucleus.properties
@@ -21,7 +21,7 @@
 
 # identifies @PersistenceCapable entities to be eagerly registered
 # if move class to other package (eg com.mycompany.myapp.dom) then update 
-isis.persistor.datanucleus.RegisterEntities.packagePrefix=domainapp.dom.modules
+isis.persistor.datanucleus.RegisterEntities.packagePrefix=domainapp.dom
 
 #
 # hook to perform additional initialization when JDO class metadata is loaded