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 2017/04/11 13:06:07 UTC

[3/3] isis git commit: ISIS-1521: sorts out top-level links; removes some TODOs in ugfun.adoc

ISIS-1521: sorts out top-level links; removes some TODOs in ugfun.adoc


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

Branch: refs/heads/master
Commit: cc0eadb2beb0e769a939d47b2cf971b4b64434fa
Parents: 4202292
Author: Dan Haywood <da...@haywood-associates.co.uk>
Authored: Tue Apr 11 14:05:47 2017 +0100
Committer: Dan Haywood <da...@haywood-associates.co.uk>
Committed: Tue Apr 11 14:05:47 2017 +0100

----------------------------------------------------------------------
 adocs/documentation/preview-pdf.sh              |   2 +-
 .../asciidoc/guides/dg/_images/ditaa-demo.png   | Bin 0 -> 5512 bytes
 .../guides/dg/_images/graphviz-demo.png         | Bin 0 -> 17255 bytes
 .../guides/dg/_images/plantuml-demo.png         | Bin 0 -> 6965 bytes
 .../guides/ugfun/_ugfun_core-concepts.adoc      |   9 +-
 .../ugfun/_ugfun_core-concepts_add-ons.adoc     |   5 +-
 .../_ugfun_core-concepts_apache-isis-vs.adoc    |  15 ++
 ...ugfun_core-concepts_apache-isis-vs_cqrs.adoc |  49 ++++
 ...-concepts_apache-isis-vs_event-sourcing.adoc |  29 +++
 ...core-concepts_apache-isis-vs_metawidget.adoc |  20 ++
 ...ache-isis-vs_mvc-server-side-frameworks.adoc |  29 +++
 .../_ugfun_core-concepts_building-blocks.adoc   | 230 ++++++++-----------
 ...re-concepts_framework-provided-services.adoc |  12 +-
 ..._core-concepts_other-deployment-options.adoc |   2 +-
 .../ugfun/_ugfun_core-concepts_philosophy.adoc  |   1 +
 .../_ugfun_core-concepts_philosophy_aop.adoc    |  63 +++--
 ...oncepts_philosophy_domain-driven-design.adoc |  83 +++++--
 ...cepts_philosophy_hexagonal-architecture.adoc |  27 ++-
 ..._core-concepts_philosophy_how-eases-ddd.adoc |  35 ++-
 ...ncepts_philosophy_naked-objects-pattern.adoc |  53 +++--
 ...bjects-pattern_object-interface-mapping.adoc |  13 +-
 .../ugfun/_ugfun_core-concepts_principles.adoc  |  17 +-
 ...core-concepts_principles_apache-isis-vs.adoc |  16 --
 ...concepts_principles_apache-isis-vs_cqrs.adoc |  28 ---
 ...rinciples_apache-isis-vs_event-sourcing.adoc |  19 --
 ...ts_principles_apache-isis-vs_metawidget.adoc |  16 --
 ...ache-isis-vs_mvc-server-side-frameworks.adoc |  19 --
 ..._core-concepts_principles_build-not-buy.adoc |  51 ++++
 ...e-concepts_principles_for-the-long-term.adoc |  66 ++++++
 ...un_core-concepts_principles_isis-itself.adoc |  39 +---
 ...inciples_isis-itself_focuses-on-its-usp.adoc |  39 ++++
 ...s_isis-itself_full-stack-but-extensible.adoc |  12 +
 ...un_core-concepts_principles_lego-blocks.adoc |  16 ++
 ...ugfun_core-concepts_principles_testable.adoc |   7 +
 ...gfun_core-concepts_principles_your-apps.adoc |  39 ----
 .../ugfun/_ugfun_faqs_enabling-logging.adoc     |   6 +-
 .../guides/ugfun/_ugfun_faqs_enhance-only.adoc  |  10 +-
 ...un_faqs_how-run-fixtures-on-app-startup.adoc |  12 +-
 ...aqs_how-to-handle-void-and-null-results.adoc |  19 +-
 ...un_faqs_how-to-implement-a-spellchecker.adoc |   3 +-
 ..._ugfun_faqs_i18n-label-in-wicket-viewer.adoc |  10 +-
 .../ugfun/_ugfun_faqs_per-user-themes.adoc      |  18 +-
 .../_ugfun_faqs_restful-image-property.adoc     |   4 +-
 ...faqs_subtype-entity-not-fully-populated.adoc |  42 ++--
 .../guides/ugfun/_ugfun_getting-started.adoc    |  21 +-
 .../core-concepts/philosophy/build-vs-buy.png   | Bin 0 -> 34337 bytes
 .../core-concepts/philosophy/build-vs-buy.pptx  | Bin 0 -> 63121 bytes
 .../philosophy/decoupled-applications.png       | Bin 0 -> 22512 bytes
 .../philosophy/decoupled-applications.pptx      | Bin 0 -> 63199 bytes
 .../guides/ugvro/_ugvro_hints-and-tips.adoc     |   6 +-
 adocs/documentation/src/main/asciidoc/js/app.js |   2 +-
 adocs/template/document.html.erb                |   8 +-
 52 files changed, 749 insertions(+), 473 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/preview-pdf.sh
----------------------------------------------------------------------
diff --git a/adocs/documentation/preview-pdf.sh b/adocs/documentation/preview-pdf.sh
index 618efcd..73ff28c 100644
--- a/adocs/documentation/preview-pdf.sh
+++ b/adocs/documentation/preview-pdf.sh
@@ -1,2 +1,2 @@
 #!/usr/bin/env bash
-mvn compile -f pom.xml && mvn compile -o && python -m webbrowser -t http://localhost:4000 && pushd target/site && python -m http.server 4000 && popd
+mvn compile -o -f pom-pdf.xml && mvn compile -o && python -m webbrowser -t http://localhost:4000 && pushd target/site && python -m http.server 4000 && popd

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/dg/_images/ditaa-demo.png
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/dg/_images/ditaa-demo.png b/adocs/documentation/src/main/asciidoc/guides/dg/_images/ditaa-demo.png
new file mode 100644
index 0000000..810c36a
Binary files /dev/null and b/adocs/documentation/src/main/asciidoc/guides/dg/_images/ditaa-demo.png differ

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/dg/_images/graphviz-demo.png
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/dg/_images/graphviz-demo.png b/adocs/documentation/src/main/asciidoc/guides/dg/_images/graphviz-demo.png
new file mode 100644
index 0000000..527839e
Binary files /dev/null and b/adocs/documentation/src/main/asciidoc/guides/dg/_images/graphviz-demo.png differ

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/dg/_images/plantuml-demo.png
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/dg/_images/plantuml-demo.png b/adocs/documentation/src/main/asciidoc/guides/dg/_images/plantuml-demo.png
new file mode 100644
index 0000000..e10ce69
Binary files /dev/null and b/adocs/documentation/src/main/asciidoc/guides/dg/_images/plantuml-demo.png differ

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts.adoc
index e0204ce..e9819a0 100644
--- a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts.adoc
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts.adoc
@@ -6,14 +6,15 @@
 
 This introductory chapter should give you a good about what Apache Isis actually *is*: the fundamental ideas and principles that it builds upon, how it compares with other frameworks, what the fundamental building blocks are for actually writing an Isis application, and what services and features the framework provides for you to leverage in your own apps.
 
-[TIP]
-====
-Parts of this chapter have been adapted from Dan Haywood's 2009 book, 'Domain Driven Design using Naked Objects'.  We've also added some new insights and made sure the material we've used is relevant to Apache Isis.
-====
+Parts of this chapter have been adapted from Dan Haywood's 2009 book, 'Domain Driven Design using Naked Objects'.
+We've also added some new insights and made sure the material we've used is relevant to Apache Isis.
 
 
 include::_ugfun_core-concepts_philosophy.adoc[leveloffset=+1]
 include::_ugfun_core-concepts_principles.adoc[leveloffset=+1]
+
+include::_ugfun_core-concepts_apache-isis-vs.adoc[leveloffset=+1]
+
 include::_ugfun_core-concepts_building-blocks.adoc[leveloffset=+1]
 include::_ugfun_core-concepts_framework-provided-services.adoc[leveloffset=+1]
 include::_ugfun_core-concepts_add-ons.adoc[leveloffset=+1]

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_add-ons.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_add-ons.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_add-ons.adoc
index a173af9..cfae890 100644
--- a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_add-ons.adoc
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_add-ons.adoc
@@ -5,11 +5,12 @@
 :_imagesdir: images/
 
 
-The link:http://www.isisaddons.org[Isis Addons] website provides a number of reusable modules and other extensions for Apache Isis.  This chapter focuses just on the modules, all of which have a name of the form `isis-module-xxx`.
+The link:http://www.isisaddons.org[Isis Addons] website provides a number of reusable modules and other extensions for Apache Isis.
+This chapter focuses just on the modules, all of which have a name of the form `isis-module-xxx`.
 
 [WARNING]
 ====
-Note that Isis addons, while maintained by Apache Isis committers, are not part of the ASF.
+Note that Isis Addons, although maintained by Apache Isis committers, are not part of the ASF.
 ====
 
 

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs.adoc
new file mode 100644
index 0000000..8dea746
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs.adoc
@@ -0,0 +1,15 @@
+[[_ugfun_core-concepts_apache-isis-vs]]
+= Apache Isis vs ...
+:Notice: 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.
+:_basedir: ../../
+:_imagesdir: images/
+
+Many other frameworks promise rapid application development and provide automatically generated user interfaces, so how do they compare to Apache Isis?
+
+
+include::_ugfun_core-concepts_apache-isis-vs_mvc-server-side-frameworks.adoc[leveloffset=+1]
+include::_ugfun_core-concepts_apache-isis-vs_cqrs.adoc[leveloffset=+1]
+include::_ugfun_core-concepts_apache-isis-vs_event-sourcing.adoc[leveloffset=+1]
+include::_ugfun_core-concepts_apache-isis-vs_metawidget.adoc[leveloffset=+1]
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_cqrs.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_cqrs.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_cqrs.adoc
new file mode 100644
index 0000000..ea526e0
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_cqrs.adoc
@@ -0,0 +1,49 @@
+[[_ugfun_core-concepts_apache-isis-vs_cqrs]]
+= vs CQRS
+:Notice: 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.
+:_basedir: ../../
+:_imagesdir: images/
+
+
+The CQRS architectural pattern (it stands for "Command Query Responsbility Separation") is the idea that the domain objects that mutate the state of the system - to which commands are sent and which then execute - should be separated from the mechanism by which the state of the system is queried (rendered).
+The former are sometimes called the "write (domain) model", the latter the "read model".
+
+In the canonical version of this pattern there are separate datastores.
+The commands act upon a command/write datastore.
+The data in this datastore is then replicated in some way to the query/read datastore, usually denormalized or otherwise such that it is easy to query.
+
+CQRS advocates recommend using very simple (almost naive) technology for the query/read model; it should be a simple projection of the query datastore.
+Complexity instead lives elsewhere: business logic in the command/write model, and in the transformation logic betweeen the command/write and read/query datastores.
+In particular, there is no requirement for the two datastores to use the same technology: one might be an RDBMS while the other a NoSQL datastore or even datawarehouse.
+
+In most implementations the command and query datastores are _not_ updated in the same transaction; instead there is some sort of replication mechanism.
+This also means that the query datastore is eventually consistent rather than always consistent; there could be a lag of a few seconds before it is updated.
+This means in turn that CQRS implementations require mechanisms to cater for offline query datastores; usually some sort of event bus.
+
+The CQRS architecture's extreme separation of responsibilities can result in a lot of boilerplate.
+Any given domain concept, eg `Customer`, must be represented both in the command/write model and also in the query/read model.
+Each business operation upon the command model is reified as a command object, for example `PlaceOrderCommand`.
+
+Comparing CQRS to Apache Isis, the most obvious difference is that Apache Isis does not separate out a command/write model from a query/read model, and there is usually just a single datastore.
+But then again, having a separate read model just so that the querying is very straightforward is pointless with Apache Isis because, of course, Isis provides the UI "for free".
+
+There are other reasons though why a separate read model might make sense, such as to precompute particular queries, or against denormalized data.
+In these cases Apache Isis can often provide a reasonable alternative, namely to map domain entities against RDBMS views, either materialized views or dynamic.
+In such cases there is still only a single physical datastore, and so transactional integrity is retained.
+
+Or, the CQRS architecture can be more fully implemented with Apache Isis by introducing a separate read model, synchronized using the xref:rgsvc.adoc#_rgsvc_api_PublishingService[`PublishingService`], or using xref:rgcms.adoc#_rgcms_classes_super_AbstractSubscriber[subscribers]  on the xref:rgsvc.adoc#_rgsvc_api_EventBusService[`EventBusService`].
+One can then use xref:ugbtb.adoc#_ugbtb_view-models[view models] to surface the data in the external read datastore.
+
+With respect to commands, Apache Isis does of course support the xref:rgsvc.adoc#_rgsvc_spi_CommandService[`CommandService`] which allows each business action to be reified into a `Command`.
+However, names are misleading here: Apache Isis' commands are relatively passive, merely recording the intent of the user to invoke some operation.
+In a CQRS architecture, though, commands take a more active role, locating and acting upon the domain objects.
+More significantly, in CQRS each command has its own class, such as `PlaceOrderCommand`, instantiated by the client and then executed.
+With Apache Isis, though, the end-user merely invokes the `placeOrder(...)` action upon the domain object; the framework itself creates the `Command` as a side-effect of this.
+
+In CQRS the commands correspond to the business logic that mutates the system.
+Whether this logic is part of the command class (`PlaceOrderCommand`) or whether that command delegates to methods on the domain object is an implementation detail; but it certainly is common for the business logic to be wholly within the command object and for the domain object to be merely a data holder of the data within the command/write datastore.
+
+In Apache Isis this same separation of business logic from the underlying data can be accomplished most straightforwardly using xref:ugbtb.adoc#_ugbtb_decoupling_mixins[mixins] or xref:ugfun.adoc#_ugfun_how-tos_contributed-members[contributions].
+In the UI (surfaced by the xref:ugvw.adoc#[Wicket viewer]) or in the REST API (surfaced by the xref:ugvro.adoc#[RestfulObjects viewer]) the behaviour appears to reside on the domain object; however the behaviour actually resides on separate classes and is mixed in (like a trait) only at runtime.
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_event-sourcing.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_event-sourcing.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_event-sourcing.adoc
new file mode 100644
index 0000000..4b7fd58
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_event-sourcing.adoc
@@ -0,0 +1,29 @@
+[[_ugfun_core-concepts_apache-isis-vs_event-sourcing]]
+= vs Event Sourcing
+:Notice: 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.
+:_basedir: ../../
+:_imagesdir: images/
+
+
+
+The link:_ugfun_core-concepts_principles_apache-isis-vs_cqrs[CQRS architecture], discussed above, is often combined with _Event Sourcing_ pattern, though they are separate ideas.
+
+With event sourcing, each business operation emits a domain event (or possibly events) that allow other objects in the system to act accordingly.
+For example, if a customer places an order then this might emit the `OrderPlacedEvent`.
+Most significantly, the subscribers to these events can include the datastore itself; the state of the system is in effect a transaction log of every event that has occurred since "the beginning of time": it is sometimes called an event store.
+With CQRS, this event datastore corresponds to the command/write datastore (the query/read datastore is of course derived from the command datastore).
+
+Although it might seem counter-intuitive to be able store persistent state in this way (as a souped up "transaction log"), the reality is that with modern compute capabilities make it quite feasible to replay many 10s/100s of thousands of events in a second.
+And the architecture supports some interesting use cases; for example it becomes quite trivial to rewind the system back to some previous point in time.
+
+When combined with CQRS we see a command that triggers a business operation, and an event that results from it.
+So, a `PlaceOrderCommand` command can result in an `OrderPlacedEvent` event.  A subscriber to this event might then generate a further command to act upon some other system (eg to dispatch the system).
+Note that the event might be dispatched and consumed in-process or alternatively this might occur out-of-process.
+If the latter, then the subscriber will operate within a separate transaction, meaning the usual eventual consistency concerns and also compensating actions if a rollback is required.
+CQRS/event sourcing advocates point out -- correctly -- that this is just how things are in the "real world" too.
+
+In Apache Isis every business action (and indeed, property and collection) emits domain events through the xref:rgsvc.adoc#_rgsvc_api_EventBusService[`EventBusService`], and can optionally also be published through the xref:rgsvc.adoc#_rgsvc_spi_PublishingService[`PublishingService`].
+The former are dispatched and consumed in-process and within the same transaction, and for this reason the xref:rgcms.adoc#_rgcms_classes_super_AbstractSubscriber[subscribers] can also veto the events.
+The latter are intended for out-of-process consumption; the (non-ASF) http://github.com/isisaddons/isis-module-publishing[Isis addons' publishing] and http://github.com/isisaddons/isis-module-publishmq[Isis addons' publishmq] modules provide implementations for dispatching either through a RDBMS database table, or directly through to an link:http://camel.apache.org[ActiveMQ] message queue (eg wired up to link:http://camel.apache.org[Apache Camel] event bus).
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_metawidget.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_metawidget.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_metawidget.adoc
new file mode 100644
index 0000000..02fa963
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_metawidget.adoc
@@ -0,0 +1,20 @@
+[[_ugfun_core-concepts_apache-isis-vs_metawidget]]
+= vs MetaWidget
+:Notice: 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.
+:_basedir: ../../
+:_imagesdir: images/
+
+
+MetaWidget (mentioned xref:ugfun.adoc#_ugfun_core-concepts_philosophy_naked-objects-pattern_object-interface-mapping[earlier] has a number of ideas in common with Apache Isis, specifically the runtime generation of a UI for domain objects.
+And like Apache Isis, MetaWidget builds its own metamodel of the domain objects and uses this to render the object.
+
+However, there is a difference in philosophy in that MW is not a full-stack framework and does not (in their words) try to "own the UI".
+Rather they support a huge variety of UI technologies and allow the domain object to be rendered in any of them.
+
+In contrast, Apache Isis is full-stack and does generate a complete UI; we then allow you to customize or extend this UI (as per the various link:http://www.isisaddons.org[Isis Addons] (non-ASF), and we also provide a full REST API through the xref:ugvro.adoc#[Restful Objects viewer]
+
+Also, it's worth noting that MetaWidget does have an elegant pipeline architecture, with APIs to allow even its metamodel to be replaced.
+It would be feasible and probably quite straightforward to use Apache Isis' own metamodel as an implementation of the MetaWidget API.
+This would allow MetaWidget to be able to render an Apache Isis domain application.
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_mvc-server-side-frameworks.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_mvc-server-side-frameworks.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_mvc-server-side-frameworks.adoc
new file mode 100644
index 0000000..81933df
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_apache-isis-vs_mvc-server-side-frameworks.adoc
@@ -0,0 +1,29 @@
+[[_ugfun_core-concepts_apache-isis-vs_mvc-server-side-frameworks]]
+= vs MVC server-side frameworks
+:Notice: 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.
+:_basedir: ../../
+:_imagesdir: images/
+
+
+
+Some of most commonly used frameworks today are link:http://www.spring.io/[Spring MVC], link:http://rubyonrails.org/[Ruby on Rails] and link:http://www.grails.org[Grails], all of which implement one flavour or another of the server-side MVC pattern.
+The MVC 1.0 specification (originally scheduled for JavaEE 8 though since removed) is also similar.
+
+These frameworks all use the classic  *model-view-controller* ( _MVC_) pattern for web applications, with scaffolding, code-generation, and/or metaprogramming tools for the controllers and views, as well as convention over configuration to define how these components interact.
+The views provided out of the box by these frameworks tend to be simple  _CRUD_-style interfaces.
+More sophisticated behavior is accomplished by customizing the generated controllers.
+
+The most obvious difference when developing an Apache Isis application is its deliberate lack of an explicit controller layer; non- _CRUD_ behavior is automatically made available in its generic object-oriented  _UI_s.
+More sophisticated UIs can be built either by xref:ugvw.adoc#_ugvw_extending[extending Apache Isis' Wicket viewer] or by writing a bespoke UI leveraging the REST (hypermedia) API automatically exposed by xref:ugvro.adoc#[Isis' Restful Objects viewer].
+Other frameworks can also be used to implement REST APIs, of course, but generally they require a significant amount of development to get anywhere near the level of sophistication provided automatically by Apache Isis' REST API.
+
+Although these frameworks all provide their own ecosystems of extensions, Apache Isis' equivalent link:http://www.isisaddons.org[Isis Addons] (non-ASF) tend to work at a higher-level of abstraction.
+For example, each of these frameworks will integrate with various security mechanism, but the http://github.com/isisaddons/isis-module-security[Isis addons' security module] provides a full subdomain of users, roles, features and permissions that can be plugged into any Isis application.
+Similarly, the http://github.com/isisaddons/isis-module-command[Isis addons' command] and http://github.com/isisaddons/isis-module-audit[Isis addons' audit] modules in combination provide a support for auditing and traceability that can also be used for out of the box profiling.
+Again, these addons can be plugged into any Isis app.
+
+In terms of testing support, each of these other frameworks provide mechanisms to allow the webapp to be tested from within a JUnit test harness.
+Apache Isis' support is similar.
+Where Apache Isis differs though is that it enables end-to-end testing without the need for slow and fragile Selenium tests.
+Instead, Apache Isis provides a "xref:ugtst.adoc#_ugtst_integ-test-support_wrapper-factory[WrapperFactory]" domain service that allows the generic UI provided to in essence be simulated.
+On a more pragmatic level, the http://github.com/isisaddons/isis-module-fakedata[Isis addons' fakedata] module does "what it says on the tin", allowing both unit- and integration-tests to focus on the salient data and fake out the rest.

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_building-blocks.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_building-blocks.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_building-blocks.adoc
index 7c0d7f2..a3680ad 100644
--- a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_building-blocks.adoc
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_building-blocks.adoc
@@ -9,79 +9,67 @@ In this section we run through the main building blocks that make up an Apache I
 [[__ugfun_core-concepts_building-blocks_metamodel]]
 == A MetaModel
 
-At its core, Apache Isis is a metamodel that is built at runtime from the domain classes (eg `Customer.java`), along
-with optional supporting metadata (eg `Customer.layout.json`).
+At its core, Apache Isis is a metamodel that is built at runtime from the domain classes (eg `Customer.java`), along with optional supporting metadata (eg `Customer.layout.xml`).
 
-The contents of this metamodel is inferred from the Java classes discovered on the classpath: the entities and
-supporting services, as well the members of those classes.  The detail of the metamodel is generally explicit, usually
-represented by Java annotations such as `@Title` or `@Action`.  Notably the metamodel is
-xref:ugbtb.adoc#_ugbtb_programming-model[extensible]; it is possible to teach Apache Isis new programming
-conventions/rules (and conversely to remove those that are built in).
+The contents of this metamodel is inferred from the Java classes discovered on the classpath: the entities and supporting services, as well the members of those classes.
+The detail of the metamodel is generally explicit, usually represented by Java annotations such as `@Title` or `@Action`.
+Notably the metamodel is xref:ugbtb.adoc#_ugbtb_programming-model[extensible]; it is possible to teach Apache Isis new programming conventions/rules (and conversely to remove those that are built in).
 
-Most of the annotations recognized by the framework are defined by the Apache Isis framework itself.  For example the
-`@Title` annotation - which identifies how the framework should derive a human-readable label for each rendered
-domain object - is part of the `org.apache.isis.applib.annotations` package.  However the framework also recognizes
-certain other JEE annotations such as `@javax.inject.Inject` (used for dependency injection).
+Most of the annotations recognized by the framework are defined by the Apache Isis framework itself.
+For example the `@Title` annotation -- which identifies how the framework should derive a human-readable label for each rendered domain object -- is part of the `org.apache.isis.applib.annotations` package.
+However the framework also recognizes certain other JEE annotations such as `@javax.inject.Inject` (used for dependency injection).
 
-The framework uses DataNucleus for its persistence mechanism.  This is an ORM that implements the JDO and JPA APIs, and
-which can map domain objects either to an RDBMS or to various NoSQL objectstores such as MongoDB or Neo4J.  Apache Isis
-recognizes a number of the JDO annotations such as `@javax.jdo.annotations.Column(allowsNull=...)`.
+The framework uses DataNucleus for its persistence mechanism.
+This is an ORM that implements the JDO and JPA APIs, and which can map domain objects either to an RDBMS or to various NoSQL objectstores such as MongoDB or Neo4J.
+Apache Isis recognizes a number of the JDO annotations such as `@javax.jdo.annotations.Column(allowsNull=...)`.
 
 In addition, the framework builds up the metamodel for each domain object using
-xref:ugfun.adoc#_ugfun_object-layout[layout hints], such as `Customer.layout.json`.  These provide metadata such as
-grouping elements of the UI together, using multi-column layouts, and so on.  The layout file can be modified while the
-application is still running, and are picked up automatically; a useful way to speed up feedback.
+xref:ugfun.adoc#_ugfun_object-layout[layout hints], such as `Customer.layout.xml`.
+These provide metadata such as grouping elements of the UI together, using multi-column layouts, and so on.
+The layout file can be modified while the application is still running, and are picked up automatically; a useful way to speed up feedback.
 
 [TIP]
 ====
-At the time of writing Apache Isis only recognizes and supports the JDO API, though we expect JPA to be supported
-in the future.  We also expect to generalize support for `.layout.json` to be able to read such metadata from other
-sources.
+At the time of writing Apache Isis only recognizes and supports the JDO API, though we expect JPA to be supported in the future.
 ====
 
 
+
 [[__ugfun_core-concepts_building-blocks_types-of-domain-objects]]
 == Type of Domain Objects
 
-Most domain objects that the end-user interacts with are *domain entities*, such as `Customer`, `Order`, `Product` and
-so on.  These are persistent objects and which are mapped to a database (usually relational), using JDO/DataNucleus
-annotations.  From the end-user's perspective the UI displays a single domain object per page; they can then inspect
-and modify its state, and navigate to related objects.
-
-The next type of domain object to discuss is *domain services*.  These are (usually) singleton stateless services
-that provide additional functionality.  The behaviour of these services is rendered in various ways, though the most
-obvious is as the menu actions on the top-level menu bars in the xref:ugvw.adoc#[Wicket viewer]'s UI.
-
-Domain objects can also delegate to domain services; domain services are automatically injected into every other domain
-object; this includes domain entities as well as other services.  This injection of domain services into entities is
-significant: it allows business logic to be implemented in the domain entities, rather than have it "leach away" into
-supporting service layers.  Said another way: it is the means by which Apache Isis helps you avoid the anaemic
-domain model anti-pattern.
-
-As well as domain entities - mapped to a datastore - Apache Isis also supports *view models*.  End users interact with
-view models in the same way as a domain entity, indeed they are unlikely to distinguish one from the other.  However
-view models are _not_ mapped to the underlying database, rather they represent some aggregation of state from one or
-more underlying entities.  Their state is serialized and recreated from their internal identifier; this identifier is
-visible as the object's URL in the xref:ugvw.adoc#[Wicket viewer] or
-xref:ugvro.adoc#[RestfulObjects viewer].
-
-There's no need though for the view model to aggregate the state of regular domain entities.  A view model could also
-be used as a proxy for some externally managed entity, accessed over a web service or REST API; it could even be a
-representation of state held in-memory (such as user preferences, for example).
-
-There are also several types of domain services.  Most easily described are those domain services (discussed above)
-that are represented as the menu actions on top-level menu bars.  Another variation are *contributed services* - domain
-services that contribute behaviour or (derived) state to entities/view models.  Finally domain services may also
-simply provide additional non-UI functionality; an example being to perform an address geocoding lookup against the
-google-maps API.
-
-Also worth mentioning: domain services can also be either singletons (discussed above) or request-scoped; the latter
-being annotated with `@javax.enterprise.context.RequestScoped`.  An example of the request-scoped service is the
-xref:rgsvc.adoc#_rgsvc_api_Scratchpad[`Scratchpad`] service, for sharing arbitrary data between multiple objects.
-
-The final type of domain object is the *mixin*.  These are similar to contributed services in that they also contribute (or rather,
-mixin) both behaviour or (derived) state to entities/view models.  However, they provide a more control over contributed services,
-with a cleaner programming model similar to traits found in other languages.
+Most domain objects that the end-user interacts with are *domain entities*, such as `Customer`, `Order`, `Product` and so on.
+These are persistent objects and which are mapped to a database (usually relational), using JDO/DataNucleus annotations.
+From the end-user's perspective the UI displays a single domain object per page; they can then inspect and modify its state, and navigate to related objects.
+
+The next type of domain object to discuss is *domain services*.
+These are (usually) singleton stateless services that provide additional functionality.
+The behaviour of these services is rendered in various ways, though the most obvious is as the menu actions on the top-level menu bars in the xref:ugvw.adoc#[Wicket viewer]'s UI.
+
+Domain objects can also delegate to domain services; domain services are automatically injected into every other domain object; this includes domain entities as well as other services.
+This injection of domain services into entities is significant: it allows business logic to be implemented in the domain entities, rather than have it "leach away" into
+supporting service layers.
+Said another way: it is the means by which Apache Isis helps you avoid the anaemic domain model anti-pattern.
+
+As well as domain entities -- mapped to a datastore -- Apache Isis also supports *view models*.
+End users interact with view models in the same way as a domain entity, indeed they are unlikely to distinguish one from the other.
+However view models are _not_ mapped to the underlying database, rather they represent some aggregation of state from one or more underlying entities.
+Their state is serialized and recreated from their internal identifier; this identifier is visible as the object's URL in the xref:ugvw.adoc#[Wicket viewer] or xref:ugvro.adoc#[RestfulObjects viewer].
+
+There's no need though for the view model to aggregate the state of regular domain entities.
+A view model could also be used as a proxy for some externally managed entity, accessed over a web service or REST API; it could even be a representation of state held in-memory (such as user preferences, for example).
+
+There are also several types of domain services.
+Most easily described are those domain services (discussed above) that are represented as the menu actions on top-level menu bars.
+Another variation are *contributed services*: domain services that contribute behaviour or (derived) state to entities/view models.
+Finally domain services may also simply provide additional non-UI functionality; an example being to perform an address geocoding lookup against the google-maps API.
+
+Also worth mentioning: domain services can also be either singletons (discussed above) or request-scoped; the latter being annotated with `@javax.enterprise.context.RequestScoped`.
+An example of the request-scoped service is the xref:rgsvc.adoc#_rgsvc_api_Scratchpad[`Scratchpad`] service, for sharing arbitrary data between multiple objects.
+
+The final type of domain object is the *mixin*.
+These are similar to contributed services in that they also contribute (or rather, mixin) both behaviour or (derived) state to entities/view models.
+However, they provide a more control over contributed services, with a cleaner programming model similar to traits found in other languages.
 
 The diagram below summarizes the various types of domain object:
 
@@ -90,33 +78,29 @@ image::{_imagesdir}core-concepts/building-blocks/types-of-domain-object.png[widt
 
 The Apache Isis programming model uses annotations to distinguish these object types:
 
-* *view models* are annotated either with `@DomainObject(nature=VIEW_MODEL)` or using `@ViewModel`.  Which is used is
-a matter of personal preference.  +
+* *view models* are annotated either with `@DomainObject(nature=VIEW_MODEL)` or using `@ViewModel`.
+Which is used is a matter of personal preference.  +
 +
 It is also possible to implement the `ViewModel` interface, for finer-grained control.
 
-* *domain entities* that are persisted to the database (as the vast majority will) are annotated with
-`@DomainObject(nature=ENTITY)`. In addition such domain entities are annotated with the JDO/DataNucleus annotation of
+* *domain entities* that are persisted to the database (as the vast majority will) are annotated with `@DomainObject(nature=ENTITY)`.
+In addition such domain entities are annotated with the JDO/DataNucleus annotation of
 `@javax.jdo.annotations.PersistenceCapable`. +
 +
-In addition, if a domain entity is a proxy for state managed in an external system, or merely for some state held
-in-memory, then `@DomainObject(nature=EXTERNAL_ENTITY)` or `@DomainObject(nature=INMEMORY_ENTITY)` can be used.
+In addition, if a domain entity is a proxy for state managed in an external system, or merely for some state held in-memory, then `@DomainObject(nature=EXTERNAL_ENTITY)` or `@DomainObject(nature=INMEMORY_ENTITY)` can be used.
 
-* *mixins* are annotated either with `@DomainObject(nature=MIXIN)` or using `@Mixin`.  As for view models, which is
-used is a matter of personal preference.
+* *mixins* are annotated either with `@DomainObject(nature=MIXIN)` or using `@Mixin`.
+As for view models, which is used is a matter of personal preference.
 
-* finally, *domain services*` are annotated with `@DomainService(nature=...)` where the nature is either
-`VIEW_MENU_ONLY` (for domain services whose actions appear on the top-level menu bars), or `VIEW_CONTRIBUTIONS_ONLY`
-(for domain services whose actions are contributed to entities or view models), or `DOMAIN` (for domain services whose
+* finally, *domain services*` are annotated with `@DomainService(nature=...)` where the nature is either `VIEW_MENU_ONLY` (for domain services whose actions appear on the top-level menu bars), or `VIEW_CONTRIBUTIONS_ONLY` (for domain services whose actions are contributed to entities or view models), or `DOMAIN` (for domain services whose
 functionality is simply for other domain objects to invoke programmatically).
 +
 It is also possible to specify a nature of simply `VIEW`, this combining `VIEW_MENU_ONLY` and `VIEW_CONTRIBUTIONS_ONLY`.
-This is in fact the default, useful for initial prototyping.  A final nature is `VIEW_REST_ONLY` which is for domain
-services whose functionality is surfaced only by the xref:ugvro.adoc#[RestfulObjects viewer].
+This is in fact the default, useful for initial prototyping.
+A final nature is `VIEW_REST_ONLY` which is for domain services whose functionality is surfaced only by the xref:ugvro.adoc#[RestfulObjects viewer].
 
-Worth emphasising is that domain entities and view models hold state, whereas domain services are generally
-stateless.  If a domain service does hold state (eg the `Scratchpad` service noted above) then it should be
-`@RequestScoped` so that this state is short-lived and usable only within a single request.
+Worth emphasising is that domain entities and view models hold state, whereas domain services are generally stateless.
+If a domain service does hold state (eg the `Scratchpad` service noted above) then it should be `@RequestScoped` so that this state is short-lived and usable only within a single request.
 
 
 
@@ -131,15 +115,13 @@ Every domain object in Apache Isis consists of (at most) three types of members:
 
 * actions, such as a `Customer'`s `placeOrder(...)` method.
 
-Some domain objects - specifically domain services and mixins - only have actions.  In the case of contributing services
-and mixins these actions can (depending upon their semantics and signatures) be represented as derived properties or
-collections on the entity/view model to which they contribute/mix-in.
+Some domain objects -- specifically domain services and mixins -- only have actions.
+In the case of contributing services and mixins these actions can (depending upon their semantics and signatures) be represented as derived properties or collections on the entity/view model to which they contribute/mix-in.
 
 
 === Properties
 
-Properties follow the standard getter/setter pattern, with the return type being a scalar (a value object or another
-entity or view model).
+Properties follow the standard getter/setter pattern, with the return type being a scalar (a value object or another entity or view model).
 
 For example, with:
 
@@ -176,16 +158,14 @@ the framework infers the `orders` _collection_.
 
 [TIP]
 ====
-The most commonly used collection type is `java.util.SortedSet`; entities are most commonly mapped to a relational
-database (ie a datastore with set semantics) and we recommend that all entities define a natural ordering so that when
-rendered in the UI they will be ordered "meaningfully" to the end-user.
+The most commonly used collection type is `java.util.SortedSet`; entities are most commonly mapped to a relational database (ie a datastore with set semantics) and we recommend that all entities define a natural ordering so that when rendered in the UI they will be ordered "meaningfully" to the end-user.
 ====
 
 
 === Actions
 
-The third type of object member is actions.  (To a first approximation), actions are all public methods that do not
-represent properties or collections.
+The third type of object member is actions.
+(To a first approximation), actions are all public methods that do not represent properties or collections.
 
 For example:
 
@@ -201,33 +181,28 @@ corresponds to the `placeOrder` _action_.
 
 [NOTE]
 ====
-The above _is_ a simplification; the Apache Isis programming model also recognizes a number of other supporting methods
-each of which has its own prefix such as `hide`, `disable` or `validate`.  These can be considered as "reserved words"
-in Apache Isis, and do _not_ correspond to actions even though they have public visibility.
+The above _is_ a simplification; the Apache Isis programming model also recognizes a number of other supporting methods each of which has its own prefix such as `hide`, `disable` or `validate`.
+These can be considered as "reserved words" in Apache Isis, and do _not_ correspond to actions even though they have public visibility.
 ====
 
 
 
 == Entities vs View Models
 
-When developing an Apache Isis application you will most likely start off with the persistent domain entities:
-`Customer`, `Order`, `Product`, and so on.  For some applications this may well suffice.  However, if the application
-needs to integrate with other systems, or if the application needs to support reasonably complex business processes,
-then you may need to look beyond just domain entities.
+When developing an Apache Isis application you will most likely start off with the persistent domain entities: `Customer`, `Order`, `Product`, and so on.
+For some applications this may well suffice.
+However, if the application needs to integrate with other systems, or if the application needs to support reasonably complex business processes, then you may need to look beyond just domain entities.
 
-To support these use cases we support view models.  In the same way that an (RDBMS) database view can aggregate and
-abstract from multiple underlying database tables, so a view model sits on top of one or many underlying entities.
+To support these use cases we support view models.
+In the same way that an (RDBMS) database view can aggregate and abstract from multiple underlying database tables, so a view model sits on top of one or many underlying entities.
 
-View models are not persisted, but nevertheless they can have behaviour (and titles, and icons) just like domain
-entities.  Indeed, to a user of the system there is no particular distinction (again, in the same way that when using
-an RDBMS one can use database views and database tables pretty much interchangeably).
+View models are not persisted, but nevertheless they can have behaviour (and titles, and icons) just like domain entities.
+Indeed, to a user of the system there is no particular distinction (again, in the same way that when using an RDBMS one can use database views and database tables pretty much interchangeably).
 
-View models generally tend to be associated with supporting a particular use case; logically they are part of the
-application layer, not part of the domain layer (where entities live).
+View models generally tend to be associated with supporting a particular use case; logically they are part of the application layer, not part of the domain layer (where entities live).
 
-We introduce view models here because they do get mentioned quite often within the users and reference guide.  However,
-we do consider them a more advanced topic; we generally recommend that you build your applications from the domain
-layer up, rather than from the view model down.
+We introduce view models here because they do get mentioned quite often within the users and reference guide.
+However, we do consider them a more advanced topic; we generally recommend that you build your applications from the domain layer up, rather than from the view model down.
 
 For further discussion on view models, see xref:ugbtb.adoc#_ugbtb_view-models[this topic].
 
@@ -237,9 +212,11 @@ For further discussion on view models, see xref:ugbtb.adoc#_ugbtb_view-models[th
 [[__ugfun_core-concepts_building-blocks_domain-services]]
 == Domain Services
 
-Domain services consist of a set of logically grouped actions, and as such follow the same conventions as for entities. However, a service cannot have (persisted) properties, nor can it have (persisted) collections.
+Domain services consist of a set of logically grouped actions, and as such follow the same conventions as for entities.
+However, a service cannot have (persisted) properties, nor can it have (persisted) collections.
 
-Domain services are instantiated once and once only by the framework, and are used to centralize any domain logic that does not logically belong in a domain entity or value. Apache Isis will automatically inject services into every domain entity that requests them, and into each other.
+Domain services are instantiated once and once only by the framework, and are used to centralize any domain logic that does not logically belong in a domain entity or value.
+Apache Isis will automatically inject services into every domain entity that requests them, and into each other.
 
 For convenience you can inherit from AbstractService or one of its subclasses, but this is not mandatory.
 
@@ -252,9 +229,11 @@ NOTE: TODO
 
 .Factories, Repositories and Services
 ****
-A distinction is sometimes made between a factory (that creates object) and a repository (that is used to find existing objects).  You will find them discussed separately in Evans' link:http://books.google.com/books/about/Domain_Driven_Design.html?id=hHBf4YxMnWMC[Domain Driven Design], for example.
+A distinction is sometimes made between a factory (that creates object) and a repository (that is used to find existing objects).
+You will find them discussed separately in Evans' link:http://books.google.com/books/about/Domain_Driven_Design.html?id=hHBf4YxMnWMC[Domain Driven Design], for example.
 
-In Apache Isis these are all implemented as domain services.  Indeed, it is quite common to have a domain service that acts as both a factory and a repository.
+In Apache Isis these are all implemented as domain services.
+Indeed, it is quite common to have a domain service that acts as both a factory and a repository.
 ****
 
 
@@ -265,8 +244,7 @@ In Apache Isis these are all implemented as domain services.  Indeed, it is quit
 NOTE: TODO
 
 
-For more information, see xref:ugbtb.adoc#_ugbtb_decoupling_contributions[this topic on contribution]s, and
-xref:ugbtb.adoc#_ugbtb_decoupling_mixins[this topic on mixin]s.
+For more information, see xref:ugbtb.adoc#_ugbtb_decoupling_contributions[this topic on contribution]s, and xref:ugbtb.adoc#_ugbtb_decoupling_mixins[this topic on mixin]s.
 
 
 
@@ -287,26 +265,25 @@ NOTE: TODO; see xref:rgcms.adoc#_rgcms_classes_uievent[UI event] classes.
 [[__ugfun_core-concepts_building-blocks_oid]]
 == OIDs
 
-As well as defining a xref:ugfun.adoc#__ugfun_core-concepts_building-blocks_metamodel[metamodel] of the structure (domain
-classes) of its domain objects, Apache Isis also manages the runtime instances of said domain objects.
+As well as defining a xref:ugfun.adoc#__ugfun_core-concepts_building-blocks_metamodel[metamodel] of the structure (domain classes) of its domain objects, Apache Isis also manages the runtime instances of said domain objects.
 
-When a domain entity is recreated from the database, the framework keeps track of its identity through an "OID": an
-object identifier.  Fundamentally this is a combination of its type (domain class), along with an identifier.  You can think
-of it as its "primary key", except across all domain entity types.
+When a domain entity is recreated from the database, the framework keeps track of its identity through an "OID": an object identifier.
+Fundamentally this is a combination of its type (domain class), along with an identifier.
+You can think of it as its "primary key", except across all domain entity types.
 
-For portability and resilience, though, the object type is generally an alias for the actual domain class: thus
-"customers.CUS", say, rather than "com.mycompany.myapp.customers.Customer".  This is derived from an annotation.  The
-identifier meanwhile is always converted to a string.
+For portability and resilience, though, the object type is generally an alias for the actual domain class: thus "customers.CUS", say, rather than "com.mycompany.myapp.customers.Customer".
+This is derived from an annotation.
+The identifier meanwhile is always converted to a string.
 
-Although simple, the OID is an enormously powerful concept: it represents a URI to any domain object managed by
-a given Apache Isis application.  With it, we have the ability to lookup any arbitrary domain objects.
+Although simple, the OID is an enormously powerful concept: it represents a URI to any domain object managed by a given Apache Isis application.
+With it, we have the ability to lookup any arbitrary domain objects.
 
 Some examples:
 
 * an OID allows sharing of information between users, eg as a deep link to be pasted into an email.
 
-* the information within an OID could be converted into a barcode, and stamped onto a PDF form.  When the PDF is
-scanned by the mail room, the barcode could be read to attach the correspondence to the relevant domain object.
+* the information within an OID could be converted into a barcode, and stamped onto a PDF form.
+When the PDF is scanned by the mail room, the barcode could be read to attach the correspondence to the relevant domain object.
 
 * as a handle to any object in an audit record, as used by xref:rgsvc.adoc#_rgsvc_spi_AuditerService[`AuditerService`] or xref:rgsvc.adoc#_rgsvc_spi_AuditingService[`AuditingService`] (the latter deprecated);
 
@@ -320,13 +297,12 @@ to persist published action invocations
 xref:ugvw.adoc#[Wicket viewer]
 use the oid tuple to look up, render and allow the user to interact with domain objects.
 
-Although the exact content of an OID should be considered opaque by domain objects, it is possible for domain objects
-to obtain OIDs.  These are represented as `Bookmark`s, obtained from the
-xref:rgsvc.adoc#_rgsvc_api_BookmarkService[`BookmarkService`].  Deep links meanwhile can be obtained from
-the xref:rgant.adoc#_rgant-DeepLinkService[`@DeepLinkService`].
+Although the exact content of an OID should be considered opaque by domain objects, it is possible for domain objects to obtain OIDs.
+These are represented as `Bookmark`s, obtained from the xref:rgsvc.adoc#_rgsvc_api_BookmarkService[`BookmarkService`].
+Deep links meanwhile can be obtained from the xref:rgant.adoc#_rgant-DeepLinkService[`@DeepLinkService`].
 
-OIDs can also be converted into XML format, useful for integration scenarios.  The
-xref:rgcms.adoc#_rgcms_schema-common[common schema] XSD defines the `oidDto` complex type for precisely this purpose.
+OIDs can also be converted into XML format, useful for integration scenarios.
+The xref:rgcms.adoc#_rgcms_schema-common[common schema] XSD defines the `oidDto` complex type for precisely this purpose.
 
 
 
@@ -336,5 +312,3 @@ xref:rgcms.adoc#_rgcms_schema-common[common schema] XSD defines the `oidDto` com
 NOTE: TODO
 
 
-
-

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_framework-provided-services.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_framework-provided-services.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_framework-provided-services.adoc
index 73258b6..f4558b8 100644
--- a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_framework-provided-services.adoc
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_framework-provided-services.adoc
@@ -5,11 +5,11 @@
 :_imagesdir: images/
 
 
-Most framework domain services are API: they exist to provide support functionality to the application's domain objects and services.  In this case an implementation of the service will be available, either by Apache Isis itself or by Isis Addons (non ASF).
+Most framework domain services are API: they exist to provide support functionality to the application's domain objects and services.
+In this case an implementation of the service will be available, either by Apache Isis itself or by Isis Addons (non ASF).
 
-Some framework domain services are SPI: they exist primarily so that the application can influence the framework's
-ehaviour.  In these cases there is (usually) no default implementation; it is up to the application to provide an
-implementation.
+Some framework domain services are SPI: they exist primarily so that the application can influence the framework's behaviour.
+In these cases there is (usually) no default implementation; it is up to the application to provide an implementation.
 
 
 General purpose:
@@ -63,12 +63,12 @@ Bookmarks and Mementos:
 
 Layout and UI Management:
 
-* xref:rgsvc.adoc#_rgsvc_api_HomePageProviderService[`HomePageProviderService`]
-* xref:rgsvc.adoc#_rgsvc_api_LayoutService[`LayoutService`]
 * xref:rgsvc.adoc#_rgsvc_spi_GridLoaderService[`GridLoaderService`] (SPI)
 * xref:rgsvc.adoc#_rgsvc_spi_GridService[`GridService`] (SPI)
 * xref:rgsvc.adoc#_rgsvc_spi_GridSystemService[`GridSystemService`] (SPI)
+* xref:rgsvc.adoc#_rgsvc_api_HomePageProviderService[`HomePageProviderService`]
 * xref:rgsvc.adoc#_rgsvc_spi_HintStore[`HintStore`] (SPI)
+* xref:rgsvc.adoc#_rgsvc_api_LayoutService[`LayoutService`]
 * xref:rgsvc.adoc#_rgsvc_spi_RoutingService[`RoutingService`] (SPI)
 * xref:rgsvc.adoc#_rgsvc_spi_UrlEncodingService[`UrlEncodingService`] (SPI)
 

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_other-deployment-options.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_other-deployment-options.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_other-deployment-options.adoc
index d9d96b6..3aef8d4 100644
--- a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_other-deployment-options.adoc
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_other-deployment-options.adoc
@@ -57,7 +57,7 @@ There are a number of use cases for deploying Isis as a REST API, including:
 
 * to allow a custom UI to be built against the RESTful API +
 +
-For example, using AngularJS or some other RIA technology such as Flex, JavaFX, Silverlight
+For example, using Angular or some other RIA technology such as Flex, JavaFX, Silverlight
 
 * to enable integration between systems +
 +

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_philosophy.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_philosophy.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_philosophy.adoc
index 23a3224..d0bdf52 100644
--- a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_philosophy.adoc
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_philosophy.adoc
@@ -14,6 +14,7 @@ include::_ugfun_core-concepts_philosophy_hexagonal-architecture.adoc[leveloffset
 
 include::_ugfun_core-concepts_philosophy_aop.adoc[leveloffset=+1]
 
+// TODO
 // include::_ugfun_core-concepts_philosophy_dci.adoc[leveloffset=+1]
 
 include::_ugfun_core-concepts_philosophy_how-eases-ddd.adoc[leveloffset=+1]

http://git-wip-us.apache.org/repos/asf/isis/blob/cc0eadb2/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_philosophy_aop.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_philosophy_aop.adoc b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_philosophy_aop.adoc
index 9c85456..db37fec 100644
--- a/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_philosophy_aop.adoc
+++ b/adocs/documentation/src/main/asciidoc/guides/ugfun/_ugfun_core-concepts_philosophy_aop.adoc
@@ -5,32 +5,61 @@
 :_imagesdir: images/
 
 
-Although not a book about object modelling, Evans' "Domain Driven Design" does use object orientation as its primary modelling tool; while xref:ugfun.adoc#_ugfun_core-concepts_philosophy_naked-objects-pattern[naked objects pattern] very much comes from an OO background (it even has 'object' in its name); Richard Pawson lists Alan Kay as a key influence.
+Although not a book about object modelling, Evans' "Domain Driven Design" does use object orientation as its primary modelling tool; while xref:ugfun.adoc#_ugfun_core-concepts_philosophy_naked-objects-pattern[naked objects pattern] very much comes from an OO background (it even has 'object' in its name).
+Richard Pawson -- the originator of Naked Objects pattern -- lists Alan Kay as a key influence.
 
-It's certainly true that to develop an Apache Isis application you will need to have good object oriented modelling skills.  But given that all the mainstream languages for developing business systems are object oriented (Java, C#, Ruby), that's not such a stretch.
+It's certainly true that to develop an Apache Isis application you will need to have good object oriented modelling skills.
+But given that all the mainstream languages for developing business systems are object oriented (Java, C#, Ruby), that's not such a stretch.
+
+However, what you'll also find as you write your applications is that in some ways an Isis application is more aspect-oriented than it is object oriented.
+Given that aspect-orientation -- as a programming paradigm at least -- hasn't caught on, that statement probably needs unpacking a little.
 
-However, what you'll also find as you write your applications is that in some ways an Isis application is more aspect-oriented than it is object oriented.  Given that aspect-orientation -- as a programming paradigm at least -- hasn't caught on, that statement probably needs unpacking a little.
 
 == AOP Concepts
 
-Aspect-orientation, then, is a different way of decomposing your application, by treating _cross-cutting concerns_ as a first-class citizen.  The canonical (also rather boring) example of a cross-cutting concern is that of logging (or tracing) all method calls.  An aspect can be written that will weave in some code (a logging statement) at specified points in the code).
+Aspect-orientation, then, is a different way of decomposing your application, by treating _cross-cutting concerns_ as a first-class citizen.
+The canonical (also rather boring) example of a cross-cutting concern is that of logging (or tracing) all method calls.
+An aspect can be written that will weave in some code (a logging statement) at specified points in the code).
+
+This idea sounds rather abstract, but what it really amounts to is the idea of interceptors.
+When one method calls another the AOP code is called in first.
+This is actually then one bit of AOP that is quite mainstream; DI containers such as Spring provide aspect orientation in supporting annotations such as `@Transactional` or `@Secured` to java beans.
 
-This idea sounds rather abstract, but what it really amounts to is the idea of interceptors.  When one method calls another the AOP code is called in first.  This is actually then one bit of AOP that is quite mainstream; DI containers such as Spring provide aspect orientation in supporting annotations such as `@Transactional` or `@Secured` to java beans.
+Another aspect (so to speak!) of aspect-oriented programming has found its way into other programming languages, that of a mix-in or trait.
+In languages such as Scala these mix-ins are specified statically as part of the inheritance hierarchy, whereas with AOP the binding of a trait to some other class/type is done without the class "knowing" that additional behaviour is being mixed-in to it.
 
-Another aspect (ahem!) of aspect-oriented programming has found its way into other programming languages, that of a mix-in or trait.  In languages such as Scala these mix-ins are specified statically as part of the inheritance hierarchy, whereas with AOP the binding of a trait to some other class/type is done without the class "knowing" that additional behaviour is being mixed-in to it.
 
 == Realization within Apache Isis
 
 What has all this to do with Apache Isis, then?
 
-Well, a different way to think of the naked objects pattern is that the visualization of a domain object within a UI is a cross-cutting concern.  By following certain very standard programming conventions that represent the _Apache Isis Programming Model_ (POJOs plus annotations), the framework is able to build a metamodel and from this can render your domain objects in a standard generic fashion.  That's a rather more interesting cross-cutting concern than boring old logging!
-
-Isis also draws heavily on the AOP concept of interceptors.  Whenever an object is rendered in the UI, it is filtered with respect to the user's permissions.  That is, if a user is not authorized to either view or perhaps modify an object, then this is applied transparently by the framework.  The http://github.com/isisaddons/isis-module-security[Isis addons' security] module, mentioned previously, provides a rich user/role/permissions subdomain to use out of the box; but you can integrate with a different security mechanism if you have one already.
-
-Another example of interceptors are the http://github.com/isisaddons/isis-module-command[Isis addons' command] and http://github.com/isisaddons/isis-module-audit[Isis addons' audit] modules.  The command module captures every user interaction that modifies the state of the system (the "cause" of a change) while the audit module captures every change to every object (the "effect" of a change).  Again, this is all transparent to the user.
-
-Apache Isis also has an internal event bus (you can switch between an underlying implementation of Gauva or Axon).  A domain event is fired whenever an object is interacted with, and this allows any subscribers to influence the operation (or even veto it).  This is a key mechanism in ensuring that Isis applications are maintainable, and we discuss it in depth in the section on  xref:ugbtb.adoc#_ugbtb_decoupling[Decoupling].  But fundamentally its relying on this AOP concept of interceptors.
-
-Finally, Isis also a feature that is akin to AOP mix-ins.  A "contributed action" is one that is implemented on a domain service but that appears to be a behaviour of rendered domain object.  In other words, we can dissociate behaviour from data.  That's not always the right thing to do of course.  In Richard Pawson's description of the xref:ugfun.adoc#_ugfun_core-concepts_philosophy_naked-objects-pattern[naked objects pattern] he talks about "behaviourally rich" objects, in other words where the business functionality encapsulated the data.   But on the other hand sometimes the behaviour and data structures change at different rates.  The link:http://en.wikipedia.org/wiki/Single_responsibility_principle[single responsibility principle] says we should only lump code together that changes at the same rate.  Apache Isis' support for contributions (not only contributed actions, but also contributed properties and contributed collections) enables this.  And again, to loop back to the to
 pic of this section, it's an AOP concept that being implemented by the framework.
-
-The nice thing about aspect orientation is that for the most part you can ignore these cross-cutting concerns and - at least initially at least - just focus on implementing your domain object.  Later when your app starts to grow and you start to break it out into smaller modules, you can leverage Apache Isis' AOP support for (xref:ugbtb.adoc#_ugbtb_decoupling_mixins[mixins]), (xref:ugbtb.adoc#_ugbtb_decoupling_contributions[contributions]) and interceptors (the xref:ugbtb.adoc#_ugbtb_decoupling_event-bus[event bus]) to ensure that your codebase remains maintainable.
\ No newline at end of file
+Well, a different way to think of the naked objects pattern is that the visualization of a domain object within a UI is a cross-cutting concern.
+By following certain very standard programming conventions that represent the _Apache Isis Programming Model_ (POJOs plus annotations), the framework is able to build a metamodel and from this can render your domain objects in a standard generic fashion.
+That's a rather more interesting cross-cutting concern than boring old logging!
+
+Apache Isis also draws heavily on the AOP concept of interceptors.
+Whenever an object is rendered in the UI, it is filtered with respect to the user's permissions.
+That is, if a user is not authorized to either view or perhaps modify an object, then this is applied transparently by the framework.
+The link:http://github.com/isisaddons/isis-module-security[Isis addons' security] module, mentioned previously, provides a rich user/role/permissions subdomain to use out of the box; but you can integrate with a different security mechanism if you have one already.
+
+Another example of interceptors are the http://github.com/isisaddons/isis-module-command[Isis addons' command] and http://github.com/isisaddons/isis-module-audit[Isis addons' audit] modules.
+The command module captures every user interaction that modifies the state of the system (the "cause" of a change) while the audit module captures every change to every object (the "effect" of a change).
+Again, this is all transparent to the user.
+
+Apache Isis also has an internal event bus (you can switch between an underlying implementation of Gauva or Axon).
+A domain event is fired whenever an object is interacted with, and this allows any subscribers to influence the operation (or even veto it).
+This is a key mechanism in ensuring that Isis applications are maintainable, and we discuss it in depth in the section on  xref:ugbtb.adoc#_ugbtb_decoupling[Decoupling].
+But fundamentally its relying on this AOP concept of interceptors.
+
+Finally, Isis also a feature that is akin to AOP mix-ins.
+A "contributed action" is one that is implemented on a domain service but that appears to be a behaviour of rendered domain object.
+In other words, we can dissociate behaviour from data.
+That's not always the right thing to do of course.
+In Richard Pawson's description of the xref:ugfun.adoc#_ugfun_core-concepts_philosophy_naked-objects-pattern[naked objects pattern] he talks about "behaviourally rich" objects, in other words where the business functionality encapsulated the data.
+But on the other hand sometimes the behaviour and data structures change at different rates.
+The link:http://en.wikipedia.org/wiki/Single_responsibility_principle[single responsibility principle] says we should only lump code together that changes at the same rate.
+Apache Isis' support for contributions (not only contributed actions, but also contributed properties and contributed collections) enables this.
+And again, to loop back to the topic of this section, it's an AOP concept that being implemented by the framework.
+
+The nice thing about aspect orientation is that for the most part you can ignore these cross-cutting concerns and - at least initially at least - just focus on implementing your domain object.
+Later when your app starts to grow and you start to break it out into smaller modules, you can leverage Apache Isis' AOP support for (xref:ugbtb.adoc#_ugbtb_decoupling_mixins[mixins]), (xref:ugbtb.adoc#_ugbtb_decoupling_contributions[contributions]) and interceptors (the xref:ugbtb.adoc#_ugbtb_decoupling_event-bus[event bus]) to ensure that your codebase remains maintainable.
\ No newline at end of file