[isis] branch master updated: ISIS-1841: update relative parent paths in moved -legacy modules

2018-05-26 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 3a3fad0  ISIS-1841: update relative parent paths in moved -legacy 
modules
3a3fad0 is described below

commit 3a3fad075a5d1b1b9352dca2758f986e6dd93e63
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Sat May 26 10:30:26 2018 +0200

ISIS-1841: update relative parent paths in moved -legacy modules

Task-Url: https://issues.apache.org/jira/browse/ISIS-1841
---
 core/legacy/applib-legacy/pom.xml   | 1 +
 core/legacy/metamodel-legacy/pom.xml| 1 +
 core/legacy/runtime-legacy/pom.xml  | 1 +
 core/legacy/unittestsupport-legacy/pom.xml  | 1 +
 core/legacy/viewer-wicket-ui-legacy/pom.xml | 1 +
 5 files changed, 5 insertions(+)

diff --git a/core/legacy/applib-legacy/pom.xml 
b/core/legacy/applib-legacy/pom.xml
index 898728a..e09bd52 100644
--- a/core/legacy/applib-legacy/pom.xml
+++ b/core/legacy/applib-legacy/pom.xml
@@ -17,6 +17,7 @@
org.apache.isis.core
isis
${revision}
+   ../../pom.xml

 
isis-core-applib-legacy
diff --git a/core/legacy/metamodel-legacy/pom.xml 
b/core/legacy/metamodel-legacy/pom.xml
index a7e6823..cb050db 100644
--- a/core/legacy/metamodel-legacy/pom.xml
+++ b/core/legacy/metamodel-legacy/pom.xml
@@ -24,6 +24,7 @@
 org.apache.isis.core
 isis
 ${revision}
+../../pom.xml
 
 
 isis-core-metamodel-legacy
diff --git a/core/legacy/runtime-legacy/pom.xml 
b/core/legacy/runtime-legacy/pom.xml
index 8135274..2270c9c 100644
--- a/core/legacy/runtime-legacy/pom.xml
+++ b/core/legacy/runtime-legacy/pom.xml
@@ -24,6 +24,7 @@
org.apache.isis.core
isis
 ${revision}
+../../pom.xml

 
isis-core-runtime-legacy
diff --git a/core/legacy/unittestsupport-legacy/pom.xml 
b/core/legacy/unittestsupport-legacy/pom.xml
index 5a2f572..08c1494 100644
--- a/core/legacy/unittestsupport-legacy/pom.xml
+++ b/core/legacy/unittestsupport-legacy/pom.xml
@@ -18,6 +18,7 @@
org.apache.isis.core
isis
${revision}
+   ../../pom.xml

 
isis-core-unittestsupport-legacy
diff --git a/core/legacy/viewer-wicket-ui-legacy/pom.xml 
b/core/legacy/viewer-wicket-ui-legacy/pom.xml
index d125170..3771f6b7 100644
--- a/core/legacy/viewer-wicket-ui-legacy/pom.xml
+++ b/core/legacy/viewer-wicket-ui-legacy/pom.xml
@@ -25,6 +25,7 @@
org.apache.isis.core
isis
${revision}
+   ../../pom.xml

 
isis-core-viewer-wicket-ui-legacy

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1841 fixes java-doc

2018-05-24 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 5320e92  ISIS-1841 fixes java-doc
5320e92 is described below

commit 5320e92ab1b6b4dea1e973696f31979d59c533fb
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Thu May 24 13:28:55 2018 +0200

ISIS-1841 fixes java-doc
---
 .../java/org/apache/isis/commons/internal/functions/_Functions.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/functions/_Functions.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/functions/_Functions.java
index d595f85..e05a726 100644
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/functions/_Functions.java
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/functions/_Functions.java
@@ -150,7 +150,7 @@ public class _Functions {

/**
 * 
-* Similar to {@link Function}, but allows checked exceptions to be 
thrown.
+* Similar to {@link Supplier}, but allows checked exceptions to be 
thrown.
 *
 * @param 
 * @param 

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1841 fixes java-doc

2018-05-24 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 179cbd7  ISIS-1841 fixes java-doc
179cbd7 is described below

commit 179cbd7a90b7efde26e1f9af7437ff5d75978db3
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Thu May 24 13:31:42 2018 +0200

ISIS-1841 fixes java-doc
---
 .../main/java/org/apache/isis/commons/internal/functions/_Functions.java | 1 -
 1 file changed, 1 deletion(-)

diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/functions/_Functions.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/functions/_Functions.java
index e05a726..2b3468c 100644
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/functions/_Functions.java
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/functions/_Functions.java
@@ -153,7 +153,6 @@ public class _Functions {
 * Similar to {@link Supplier}, but allows checked exceptions to be 
thrown.
 *
 * @param 
-* @param 
 */
@FunctionalInterface
public interface CheckedSupplier {

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1948: fixes plugin class not found issues after having renamed plugins

2018-05-21 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new d4fd2c8  ISIS-1948: fixes plugin class not found issues after having 
renamed plugins
d4fd2c8 is described below

commit d4fd2c8297c8cd48206a907b51e78afa9cf34c9f
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Mon May 21 10:40:49 2018 +0200

ISIS-1948: fixes plugin class not found issues after having renamed
plugins

Task-Url: https://issues.apache.org/jira/browse/ISIS-1948
---
 .../services/org.apache.isis.core.plugins.codegen.ProxyFactoryPlugin  | 2 +-
 .../isis/core/runtime/services/eventbus/EventBusServiceDefault.java   | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git 
a/core/plugins/codegen-javassist/src/main/resources/META-INF/services/org.apache.isis.core.plugins.codegen.ProxyFactoryPlugin
 
b/core/plugins/codegen-javassist/src/main/resources/META-INF/services/org.apache.isis.core.plugins.codegen.ProxyFactoryPlugin
index a2d4b84..a9c3339 100644
--- 
a/core/plugins/codegen-javassist/src/main/resources/META-INF/services/org.apache.isis.core.plugins.codegen.ProxyFactoryPlugin
+++ 
b/core/plugins/codegen-javassist/src/main/resources/META-INF/services/org.apache.isis.core.plugins.codegen.ProxyFactoryPlugin
@@ -1 +1 @@
-org.apache.isis.core.runtime.plugins.codegen.ProxyFactoryPluginUsingJavassist
\ No newline at end of file
+org.apache.isis.core.plugins.codegen.ProxyFactoryPluginUsingJavassist
\ No newline at end of file
diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/eventbus/EventBusServiceDefault.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/eventbus/EventBusServiceDefault.java
index 07de6b9..47b33b4 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/eventbus/EventBusServiceDefault.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/eventbus/EventBusServiceDefault.java
@@ -138,10 +138,10 @@ public abstract class EventBusServiceDefault extends 
EventBusService {

} else if("guava".equals(implementation)) {
 // legacy of return new EventBusImplementationForGuava();
-   fqImplementationName = 
"org.apache.isis.core.runtime.services.eventbus.adapter.EventBusImplementationForGuava";
+   fqImplementationName = 
"org.apache.isis.core.plugins.eventbus.EventBusPluginForGuava";
 } else if("axon".equals(implementation)) {
// legacy of return new EventBusImplementationForAxonSimple();
-   fqImplementationName = 
"org.apache.isis.core.runtime.services.eventbus.adapter.EventBusImplementationForAxonSimple";
+   fqImplementationName = 
"org.apache.isis.core.plugins.eventbus.EventBusPluginForAxon";
 }
 
 final Class aClass = ClassUtil.forName(fqImplementationName);

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1948: fixes meta-model validation failure on UrlEncodingService

2018-05-21 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 0026fe1  ISIS-1948: fixes meta-model validation failure on 
UrlEncodingService
0026fe1 is described below

commit 0026fe1e766000685f073b73dff743dbbad284d8
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Mon May 21 10:49:22 2018 +0200

ISIS-1948: fixes meta-model validation failure on UrlEncodingService

Task-Url: https://issues.apache.org/jira/browse/ISIS-1948
---
 .../apache/isis/applib/services/urlencoding/UrlEncodingService.java | 6 ++
 1 file changed, 6 insertions(+)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/urlencoding/UrlEncodingService.java
 
b/core/applib/src/main/java/org/apache/isis/applib/services/urlencoding/UrlEncodingService.java
index b526d0b..d8699a6 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/urlencoding/UrlEncodingService.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/services/urlencoding/UrlEncodingService.java
@@ -24,6 +24,12 @@ import 
org.apache.isis.commons.internal.memento._Mementos.EncoderDecoder;
 
 public interface UrlEncodingService extends EncoderDecoder {
 
+   // -- INHERITED from EncoderDecoder (make explicitly programmatic, in 
order to avoid meta-model validation)
+   @Programmatic public String encode(final byte[] bytes);
+   @Programmatic public byte[] decode(String str);
+   
+// -- EXTENSIONS
+
 @Programmatic
 public default String encodeString(final String str) {
return encode(_Strings.toBytes(str, StandardCharsets.UTF_8));

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1841 Internal API: introduces _With ...

2018-05-22 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new fbf71fb  ISIS-1841 Internal API: introduces _With ...
fbf71fb is described below

commit fbf71fb976aebb24873e781a8e3088388869189f
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Tue May 22 10:48:15 2018 +0200

ISIS-1841 Internal API: introduces _With ...

Provides fluent replacements for common accept/apply/supply idioms.
---
 .../isis/commons/internal/base/_NullSafe.java  |  23 +--
 .../apache/isis/commons/internal/base/_With.java   | 201 +
 .../core/metamodel/facets/CollectionUtils.java |   7 +-
 3 files changed, 208 insertions(+), 23 deletions(-)

diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/base/_NullSafe.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/base/_NullSafe.java
index 3bd6c63..634897a 100644
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/base/_NullSafe.java
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/base/_NullSafe.java
@@ -23,7 +23,6 @@ import java.util.Comparator;
 import java.util.Iterator;
 import java.util.Map;
 import java.util.Objects;
-import java.util.function.Consumer;
 import java.util.stream.Stream;
 import java.util.stream.StreamSupport;
 
@@ -99,7 +98,8 @@ public final class _NullSafe {
// -- ABSENCE/PRESENCE PREDICATES

/**
-* Allows to replace a lambda expression {@code x->x!=null} with {@code 
NullSafe::isPresent}
+* Allows to replace a lambda expression {@code x->x!=null} with {@code 
NullSafe::isPresent}.
+* Equivalent to {@link java.util.Objects#nonNull(Object)}.
 * @param x
 * @return whether {@code x} is not null (present).
 */
@@ -108,7 +108,8 @@ public final class _NullSafe {
}
 
/**
-* Allows to replace a lambda expression {@code x->x==null} with {@code 
NullSafe::isAbsent}
+* Allows to replace a lambda expression {@code x->x==null} with {@code 
NullSafe::isAbsent}.
+* Equivalent to {@link java.util.Objects#isNull(Object)}.
 * @param x
 * @return whether {@code x} is null (absent).
 */
@@ -116,21 +117,6 @@ public final class _NullSafe {
return x==null;
}

-   // -- PEEK OPERATOR
-   
-   /**
-* Unary identity operator that passes {@code obj} to {@code ifPresent} 
if {@code obj} is present.   
-* @param obj
-* @param ifPresent
-* @return {@code obj}
-*/
-   public final static  T peek(T obj, Consumer ifPresent) {
-   if(obj!=null) {
-   ifPresent.accept(obj);
-   }
-   return obj;
-   }
-   
// -- EQUALS/COMPARE

/**
@@ -162,7 +148,6 @@ public final class _NullSafe {

}

-   
// -- EMTPY CHECKS

public static boolean isEmpty(String x) { return x==null || x.length() 
== 0; }
diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/base/_With.java 
b/core/commons/src/main/java/org/apache/isis/commons/internal/base/_With.java
new file mode 100644
index 000..c128a54
--- /dev/null
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/base/_With.java
@@ -0,0 +1,201 @@
+/*
+ *  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.commons.internal.base;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.TreeMap;
+import java.util.TreeSet;
+import java.util.function.Consumer;
+import java.util.function.Function;
+import java.util.function.Supplier;
+
+import javax.annotation.Nullable;
+
+/**
+ * - internal use only -
+ * 
+ * Provides fluent replacements for common accept/apply/supply idioms.
+ * 
+ * 
+ * WARNING: Do NOT use any of the classes provided by this 
package!  
+ * These ma

[isis] branch master updated: ISIS-1954: migrate simple-app tests to JUnit 5

2018-06-06 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new ee96209  ISIS-1954: migrate simple-app tests to JUnit 5
ee96209 is described below

commit ee96209b4a6d8e626afb1b843253cc9ede7339c3
Author: Andi Huber 
AuthorDate: Wed Jun 6 11:23:37 2018 +0200

ISIS-1954: migrate simple-app tests to JUnit 5

except for one test class which is still run with JUnit 4 because it
uses org.junit.Rule:
domainapp.modules.simple.dom.impl.SimpleObjects_Test

Task-Url: https://issues.apache.org/jira/browse/ISIS-1954
---
 .../modules/simple/dom/impl/SimpleObject_Test.java |  7 ++--
 .../simple/dom/impl/SimpleObjects_Test.java|  3 +-
 .../integtests/SimpleModuleIntegTestAbstract.java  |  6 ++--
 .../tests/SimpleObjectMenu_IntegTest.java  | 30 ++--
 .../integtests/tests/SimpleObject_IntegTest.java   | 42 ++
 5 files changed, 56 insertions(+), 32 deletions(-)

diff --git 
a/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/dom/impl/SimpleObject_Test.java
 
b/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/dom/impl/SimpleObject_Test.java
index d228676..2532eb1 100644
--- 
a/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/dom/impl/SimpleObject_Test.java
+++ 
b/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/dom/impl/SimpleObject_Test.java
@@ -16,16 +16,17 @@
  */
 package domainapp.modules.simple.dom.impl;
 
-import org.junit.Before;
-import org.junit.Test;
 
 import static org.assertj.core.api.Assertions.assertThat;
 
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
+
 public class SimpleObject_Test {
 
 SimpleObject simpleObject;
 
-@Before
+@BeforeEach
 public void setUp() throws Exception {
 simpleObject = new SimpleObject("Foobar");
 }
diff --git 
a/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/dom/impl/SimpleObjects_Test.java
 
b/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/dom/impl/SimpleObjects_Test.java
index 5f2b8c9..b6f90d9 100644
--- 
a/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/dom/impl/SimpleObjects_Test.java
+++ 
b/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/dom/impl/SimpleObjects_Test.java
@@ -28,7 +28,6 @@ import org.jmock.auto.Mock;
 import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
-
 import org.apache.isis.applib.services.repository.RepositoryService;
 import org.apache.isis.core.unittestsupport.jmocking.JMockActions;
 import org.apache.isis.core.unittestsupport.jmocking.JUnitRuleMockery2;
@@ -36,6 +35,8 @@ import 
org.apache.isis.core.unittestsupport.jmocking.JUnitRuleMockery2.Mode;
 
 import static org.assertj.core.api.Assertions.assertThat;
 
+//TODO [ahuber] this test is still on JUnit 4 because it uses org.junit.Rule, 
+//which no longer exists with JUnit 5
 public class SimpleObjects_Test {
 
 @Rule
diff --git 
a/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/integtests/SimpleModuleIntegTestAbstract.java
 
b/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/integtests/SimpleModuleIntegTestAbstract.java
index bf3cf52..3aab4e0 100644
--- 
a/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/integtests/SimpleModuleIntegTestAbstract.java
+++ 
b/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/integtests/SimpleModuleIntegTestAbstract.java
@@ -18,14 +18,14 @@
  */
 package domainapp.modules.simple.integtests;
 
-import org.apache.isis.core.integtestsupport.IntegrationTestAbstract3;
+import org.apache.isis.core.integtestsupport.IntegrationTestJupiter;
 
 import domainapp.modules.simple.SimpleModule;
 
-public abstract class SimpleModuleIntegTestAbstract extends 
IntegrationTestAbstract3 {
+public abstract class SimpleModuleIntegTestAbstract extends 
IntegrationTestJupiter {
 
 public SimpleModuleIntegTestAbstract() {
-super(new 
SimpleModule().withConfigurationProperty("isis.objects.editing","false"));
+super(new 
SimpleModule().withConfigurationProperty("isis.objects.editing", "false"));
 }
 
 
diff --git 
a/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/integtests/tests/SimpleObjectMenu_IntegTest.java
 
b/example/application/simpleapp/module-simple/src/test/java/domainapp/modules/simple/integtests/tests/SimpleObjectMenu_IntegTest.java
index 02ab891..158ae05 100644
--- 
a/example/application/simpleapp/module-simple/src/t

[isis] branch master updated: ISIS-1948: excluding transitive dependencies from 'discovery-reflections' plugin

2018-06-07 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 6ba1083  ISIS-1948: excluding transitive dependencies from 
'discovery-reflections' plugin
6ba1083 is described below

commit 6ba10832261be9d12694dadf15b12a00585ca8b0
Author: Andi Huber 
AuthorDate: Thu Jun 7 18:43:33 2018 +0200

ISIS-1948: excluding transitive dependencies from
'discovery-reflections' plugin

Task-Url: https://issues.apache.org/jira/browse/ISIS-1948
---
 core/plugins/discovery-reflections/pom.xml | 16 +++-
 1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/core/plugins/discovery-reflections/pom.xml 
b/core/plugins/discovery-reflections/pom.xml
index 5619401..02fcbf7 100644
--- a/core/plugins/discovery-reflections/pom.xml
+++ b/core/plugins/discovery-reflections/pom.xml
@@ -62,6 +62,12 @@
org.apache.isis.core
isis-core-commons
compile
+   
+   
+   
com.google.code.findbugs
+   annotations
+   
+   



 false
 
+   

-   
com.google.guava
guava

+   
+   com.google.code.findbugs
+   annotations
+   
+   
+   org.javassist
+   javassist
+   
 
 
 

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1948: reverting javassist dependency removal

2018-06-07 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 9cadffe  ISIS-1948: reverting javassist dependency removal
9cadffe is described below

commit 9cadffe23992c3dd5d7fd558c7729ab3991ce599
Author: Andi Huber 
AuthorDate: Thu Jun 7 21:40:00 2018 +0200

ISIS-1948: reverting javassist dependency removal

it breaks build and some tests

Task-Url: https://issues.apache.org/jira/browse/ISIS-1948
---
 core/plugins/discovery-reflections/pom.xml | 14 --
 1 file changed, 14 deletions(-)

diff --git a/core/plugins/discovery-reflections/pom.xml 
b/core/plugins/discovery-reflections/pom.xml
index 02fcbf7..2bbab83 100644
--- a/core/plugins/discovery-reflections/pom.xml
+++ b/core/plugins/discovery-reflections/pom.xml
@@ -62,12 +62,6 @@
org.apache.isis.core
isis-core-commons
compile
-   
-   
-   
com.google.code.findbugs
-   annotations
-   
-   



[isis] branch master updated: ISIS-1963: workaround the issue by selective exception suppression

2018-06-15 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new d7fefd3  ISIS-1963: workaround the issue by selective exception 
suppression
d7fefd3 is described below

commit d7fefd3edfcfb4c80032d46d29a132639db7bbd9
Author: Andi Huber 
AuthorDate: Fri Jun 15 15:29:25 2018 +0200

ISIS-1963: workaround the issue by selective exception suppression

Task-Url: https://issues.apache.org/jira/browse/ISIS-1963
---
 .../commons/internal/exceptions/_Exceptions.java   | 149 +
 .../core/webapp/content/ResourceCachingFilter.java |   7 +-
 .../wicket/ui/panels/PromptFormAbstract.java   |  45 ---
 3 files changed, 157 insertions(+), 44 deletions(-)

diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/exceptions/_Exceptions.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/exceptions/_Exceptions.java
index ceea19e..7200cc1 100644
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/exceptions/_Exceptions.java
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/exceptions/_Exceptions.java
@@ -19,11 +19,15 @@
 
 package org.apache.isis.commons.internal.exceptions;
 
+import static org.apache.isis.commons.internal.base._With.requires;
+
 import java.util.Collections;
 import java.util.List;
 import java.util.Objects;
+import java.util.Optional;
 import java.util.function.Consumer;
 import java.util.function.Function;
+import java.util.function.Predicate;
 import java.util.stream.Stream;
 
 import javax.annotation.Nullable;
@@ -47,9 +51,9 @@ import org.apache.isis.commons.internal.functions._Functions;
 public final class _Exceptions {
 
private _Exceptions(){}
-   
+
// -- FRAMEWORK INTERNAL ERRORS 
-   
+
/**
 * Most likely to be used in switch statements to handle the default 
case.  
 * @param _case the unmatched case to be reported
@@ -58,7 +62,7 @@ public final class _Exceptions {
public static final IllegalArgumentException unmatchedCase(@Nullable 
Object _case) {
return new IllegalArgumentException("internal error: unmatched 
case in switch statement: "+_case);
}
-   
+
/**
 * Most likely to be used in switch statements to handle the default 
case.
 * @param format like in {@link java.lang.String#format(String, 
Object...)}
@@ -69,15 +73,15 @@ public final class _Exceptions {
Objects.requireNonNull(format);
return new IllegalArgumentException(String.format(format, 
_case));
}
-   
+
public static final IllegalStateException unexpectedCodeReach() {
return new IllegalStateException("internal error: code was 
reached, that is expected unreachable");
}   
-   
+
public static IllegalStateException notImplemented() {
return new IllegalStateException("internal error: code was 
reached, that is not implemented yet");
}
-   
+
/**
 * Used to hide from the compiler the fact, that this call always 
throws.
 * 
@@ -98,10 +102,41 @@ public final class _Exceptions {
public static IllegalStateException throwNotImplemented() {
throw notImplemented();
}
+
+   // -- SELECTIVE ERROR SUPPRESSION
+
+// /**
+//  * Allows to selectively ignore unchecked exceptions. Most likely used 
framework internally
+//  * for workarounds, not properly dealing with the root cause. This way 
at least we know, where
+//  * we placed such workarounds. 
+//  * 
+//  * @param runnable that might throw an unchecked exception
+//  * @param suppress predicate that decides whether to suppress an 
exception
+//  */
+// public static void catchSilently(
+// Runnable runnable, 
+// Predicate suppress) {
+// 
+// try {
+// runnable.run();
+// } catch (RuntimeException cause) {
+// if(suppress.test(cause)) {
+// return;
+// }   
+// throw cause;
+// }
+// }

+   // -- SELECTIVE THROW

+   public static  void throwWhenTrue(E cause, 
Predicate test) throws E {
+   if(test.test(cause)) {
+   throw cause;
+   }
+   }
+
// -- STACKTRACE UTILITITIES
-   
+
public static final Stream streamStacktraceLines(@Nullable 
Throwable ex, int maxLines) {
if(ex==null) {
return Stream.empty();
@@ -110,7 +145,7 @@ public final class _Exceptions {
.m

[isis] branch master updated: ISIS-1950: codegen-bytebuddy plugin: first give-it-a-try implementation

2018-05-29 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 3008d7b  ISIS-1950: codegen-bytebuddy plugin: first give-it-a-try 
implementation
3008d7b is described below

commit 3008d7ba01afcb4274daab5257f14b054c088b40
Author: Andi Huber 
AuthorDate: Tue May 29 21:38:44 2018 +0200

ISIS-1950: codegen-bytebuddy plugin: first give-it-a-try implementation

Task-Url: https://issues.apache.org/jira/browse/ISIS-1950
---
 core/plugins/codegen-bytebuddy/pom.xml |   5 +
 .../codegen/ProxyFactoryPluginUsingByteBuddy.java  | 107 +++--
 2 files changed, 106 insertions(+), 6 deletions(-)

diff --git a/core/plugins/codegen-bytebuddy/pom.xml 
b/core/plugins/codegen-bytebuddy/pom.xml
index 0732c78..02c58e3 100644
--- a/core/plugins/codegen-bytebuddy/pom.xml
+++ b/core/plugins/codegen-bytebuddy/pom.xml
@@ -61,6 +61,11 @@
byte-buddy
${bytebuddy.version}

+   
+   
+   org.objenesis
+   objenesis
+   
 

org.apache.isis.core
diff --git 
a/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
 
b/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
index dbe3da7..e9fdf46 100644
--- 
a/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
+++ 
b/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
@@ -1,11 +1,24 @@
 package org.apache.isis.core.plugins.codegen;
 
+import java.lang.reflect.InvocationHandler;
+import java.lang.reflect.InvocationTargetException;
 import java.lang.reflect.Method;
+import java.util.function.Function;
 import java.util.function.Predicate;
 
-import org.apache.isis.commons.internal.exceptions._Exceptions;
-import org.apache.isis.core.plugins.codegen.ProxyFactory;
-import org.apache.isis.core.plugins.codegen.ProxyFactoryPlugin;
+import javax.annotation.Nullable;
+
+import org.apache.isis.commons.internal._Constants;
+import org.apache.isis.commons.internal.base._Casts;
+import org.apache.isis.commons.internal.base._NullSafe;
+import org.objenesis.Objenesis;
+import org.objenesis.ObjenesisStd;
+
+import net.bytebuddy.ByteBuddy;
+import net.bytebuddy.NamingStrategy;
+import 
net.bytebuddy.dynamic.DynamicType.Builder.MethodDefinition.ImplementationDefinition;
+import net.bytebuddy.implementation.InvocationHandlerAdapter;
+import net.bytebuddy.matcher.ElementMatchers;
 
 public class ProxyFactoryPluginUsingByteBuddy implements ProxyFactoryPlugin {
 
@@ -16,9 +29,91 @@ public class ProxyFactoryPluginUsingByteBuddy implements 
ProxyFactoryPlugin {
Predicate methodFilter,
Class[] constructorArgTypes) {

-   _Exceptions.throwNotImplemented();
-   // TODO Auto-generated method stub
-   return null;
+   final Objenesis objenesis = new ObjenesisStd();
+
+   final ImplementationDefinition proxyDef = new ByteBuddy()
+   .with(new NamingStrategy.SuffixingRandom("bb"))
+   .subclass(base)
+   .implement(interfaces)
+   .method(ElementMatchers.any());
+   
+   final Function> 
proxyClassFactory = handler->
+   
proxyDef.intercept(InvocationHandlerAdapter.of(handler))
+   .make()
+   .load(base.getClassLoader())
+   .getLoaded();
+
+   return new ProxyFactory() {
+
+   @Override
+   public T createInstance(InvocationHandler handler, 
boolean initialize) {
+
+   try {
+   
+   if(initialize) {
+   
ensureSameSize(constructorArgTypes, null);
+   return _Casts.uncheckedCast( 
createUsingConstructor(handler, null) );
+   } else {
+   return _Casts.uncheckedCast( 
createNotUsingConstructor(handler) );
+   }
+   
+   } catch (NoSuchMethodException | 
IllegalArgumentException | Instan

[isis] branch master updated: ISIS-1954: introduces IntegrationTestJupiter as base class for integration tests for the JUnit 5 Jupiter Engine

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new ddfc8cd  ISIS-1954: introduces IntegrationTestJupiter as base class 
for integration tests for the JUnit 5 Jupiter Engine
ddfc8cd is described below

commit ddfc8cd86b7d7d9eb52a1ec19936e838d9a895c8
Author: Andi Huber 
AuthorDate: Thu May 31 14:17:47 2018 +0200

ISIS-1954: introduces IntegrationTestJupiter as base class for
integration tests for the JUnit 5 Jupiter Engine

Task-Url: https://issues.apache.org/jira/browse/ISIS-1954
---
 .../integtestsupport/IntegrationTestAbstract3.java |  88 +---
 .../integtestsupport/IntegrationTestJupiter.java   |  96 +
 .../apache/isis/core/integtestsupport/Util.java| 116 +
 3 files changed, 215 insertions(+), 85 deletions(-)

diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
index 7bd30b3..2394f74 100644
--- 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
+++ 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
@@ -18,16 +18,8 @@
  */
 package org.apache.isis.core.integtestsupport;
 
-import java.util.List;
-
 import org.apache.isis.applib.AppManifest;
 import org.apache.isis.applib.Module;
-import org.apache.isis.applib.NonRecoverableException;
-import org.apache.isis.applib.RecoverableException;
-import org.apache.isis.applib.services.jdosupport.IsisJdoSupport;
-import org.apache.isis.applib.services.xactn.TransactionService;
-import org.apache.isis.commons.internal.exceptions._Exceptions;
-import 
org.apache.isis.core.integtestsupport.components.DefaultHeadlessTransactionSupport;
 import org.apache.isis.core.runtime.headless.HeadlessTransactionSupport;
 import org.apache.isis.core.runtime.headless.HeadlessWithBootstrappingAbstract;
 import org.apache.isis.core.runtime.headless.IsisSystem;
@@ -73,82 +65,15 @@ public abstract class IntegrationTestAbstract3 extends 
HeadlessWithBootstrapping
 base.evaluate();
 final IsisSystem isft = IsisSystem.get();
 
isft.getService(HeadlessTransactionSupport.class).endTransaction();
-} catch(final Throwable e) {
-// determine if underlying cause is an applib-defined 
exception,
-final RecoverableException recoverableException =
-determineIfRecoverableException(e);
-final NonRecoverableException nonRecoverableException =
-determineIfNonRecoverableException(e);
-
-if(recoverableException != null) {
-try {
-final IsisSystem isft = IsisSystem.get();
-
isft.getService(TransactionService.class).flushTransaction(); // don't care if 
npe
-
isft.getService(IsisJdoSupport.class).getJdoPersistenceManager().flush();
-} catch (Exception ignore) {
-// ignore
-}
-}
-// attempt to close this
-try {
-final IsisSystem isft = IsisSystem.getElseNull();
-isft.closeSession(); // don't care if npe
-} catch(Exception ignore) {
-// ignore
-}
-
-// attempt to start another
-try {
-final IsisSystem isft = IsisSystem.getElseNull();
-isft.openSession(); // don't care if npe
-} catch(Exception ignore) {
-// ignore
-}
-
-
-// if underlying cause is an applib-defined, then
-// throw that rather than Isis' wrapper exception
-if(recoverableException != null) {
-throw recoverableException;
-}
-if(nonRecoverableException != null) {
-throw nonRecoverableException;
-}
-
-// report on the error that caused
-// a problem for *this* test
-throw e;
-}
-}
-
-NonRecoverableException 
determineIfNonRecoverableException(final

[isis] 02/02: ISIS-1954: proposed fix for build error

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 046a8897529fa96e7396185a05d755eb706833fe
Author: Andi Huber 
AuthorDate: Thu May 31 14:33:01 2018 +0200

ISIS-1954: proposed fix for build error

Task-Url: https://issues.apache.org/jira/browse/ISIS-1954
---
 .../org/apache/isis/core/integtestsupport/IntegrationTestJupiter.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestJupiter.java
 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestJupiter.java
index 34314d4..342871c 100644
--- 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestJupiter.java
+++ 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestJupiter.java
@@ -39,7 +39,7 @@ import org.slf4j.event.Level;
 @ExtendWith(IntegrationTestJupiter.HeadlessTransactionRule.class)
 public abstract class IntegrationTestJupiter extends 
HeadlessWithBootstrappingAbstract {
 
-   private static class HeadlessTransactionRule implements 
AfterEachCallback, BeforeEachCallback {
+   public static class HeadlessTransactionRule implements 
AfterEachCallback, BeforeEachCallback {
 
@Override
public void beforeEach(ExtensionContext context) throws 
Exception {

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated (ddfc8cd -> 046a889)

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git.


from ddfc8cd  ISIS-1954: introduces IntegrationTestJupiter as base class 
for integration tests for the JUnit 5 Jupiter Engine
 new 6be7d65  ISIS-1954: enhance java-doc
 new 046a889  ISIS-1954: proposed fix for build error

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../org/apache/isis/core/integtestsupport/IntegrationTestJupiter.java   | 2 +-
 .../apache/isis/core/runtime/headless/HeadlessTransactionSupport.java   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] 01/02: ISIS-1954: enhance java-doc

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 6be7d654fefacc5f643106de2bc125edc343a926
Author: Andi Huber 
AuthorDate: Thu May 31 14:30:06 2018 +0200

ISIS-1954: enhance java-doc

Task-Url: https://issues.apache.org/jira/browse/ISIS-1954
---
 .../apache/isis/core/runtime/headless/HeadlessTransactionSupport.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/HeadlessTransactionSupport.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/HeadlessTransactionSupport.java
index 9b293f4..6e8e513 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/HeadlessTransactionSupport.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/HeadlessTransactionSupport.java
@@ -21,7 +21,7 @@ package org.apache.isis.core.runtime.headless;
 
 /**
  * Extends transaction management as required by integration tests.
- * 
+ * @since 2.0.0
  */
 public interface HeadlessTransactionSupport {
void beginTransaction();

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] 04/05: ISIS-1954: IsisSystem: refactoring deprecated methods out into a mixin

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 3e3f21de48058ceddced23b5253e8e94ee99db16
Author: Andi Huber 
AuthorDate: Thu May 31 11:18:59 2018 +0200

ISIS-1954: IsisSystem: refactoring deprecated methods out into a mixin

Task-Url: https://issues.apache.org/jira/browse/ISIS-1954
---
 .../integtestsupport/IntegrationTestAbstract3.java |   7 +-
 core/legacy/integtestsupport-legacy/pom.xml|  12 +-
 .../HeadlessWithBootstrappingAbstract.java |   3 +-
 .../isis/core/runtime/headless/IsisSystem.java | 187 +
 .../runtime/headless/IsisSystem_Transactions.java  | 178 
 .../headless/TransactionSupportInternal.java   |  30 
 6 files changed, 222 insertions(+), 195 deletions(-)

diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
index c48e37c..2bea7bd 100644
--- 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
+++ 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
@@ -37,8 +37,6 @@ import org.junit.rules.ExpectedException;
 import org.junit.rules.MethodRule;
 import org.junit.runners.model.FrameworkMethod;
 import org.junit.runners.model.Statement;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
 import org.slf4j.event.Level;
 
 /**
@@ -46,7 +44,7 @@ import org.slf4j.event.Level;
  */
 public abstract class IntegrationTestAbstract3 extends 
HeadlessWithBootstrappingAbstract {
 
-private static final Logger LOG = 
LoggerFactory.getLogger(IntegrationTestAbstract3.class);
+//private static final Logger LOG = 
LoggerFactory.getLogger(IntegrationTestAbstract3.class);
 
 @Rule
 public ExpectedException expectedExceptions = ExpectedException.none();
@@ -71,8 +69,7 @@ public abstract class IntegrationTestAbstract3 extends 
HeadlessWithBootstrapping
 // Instead we expect it to be bootstrapped via @Before
 try {
 base.evaluate();
-final IsisSystem isft = IsisSystem.get();
-isft.endTran();
+
IsisSystem.get().getTransactionSupportInternal().endTran();
 } catch(final Throwable e) {
 // determine if underlying cause is an applib-defined 
exception,
 final RecoverableException recoverableException =
diff --git a/core/legacy/integtestsupport-legacy/pom.xml 
b/core/legacy/integtestsupport-legacy/pom.xml
index 009a12e..0b7470c 100644
--- a/core/legacy/integtestsupport-legacy/pom.xml
+++ b/core/legacy/integtestsupport-legacy/pom.xml
@@ -45,12 +45,12 @@
isis-core-integtestsupport
compile

-   
-   org.apache.isis.core
-   isis-core-integtestsupport
-   test-jar
-   test
-   
+
+
+
+
+
+
 

 
diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/HeadlessWithBootstrappingAbstract.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/HeadlessWithBootstrappingAbstract.java
index 82acb3e..903599c 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/HeadlessWithBootstrappingAbstract.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/HeadlessWithBootstrappingAbstract.java
@@ -116,8 +116,7 @@ public abstract class HeadlessWithBootstrappingAbstract 
extends HeadlessAbstract
 }
 
 private void beginTransaction() {
-final IsisSystem isft = IsisSystem.get();
-isft.beginTran();
+IsisSystem.get().getTransactionSupportInternal().beginTran();
 }
 
 protected void tearDownAllModules() {
diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem.java
index 8892029..0317ea6 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem.java
@@ -25,9 +25,6 @@ import java.util.Set;
 
 import org.apache.isis.applib.AppManifest;
 import org.apache.isis.applib.fixtures.FixtureClock;
-import org.apache.isis.applib.fixtures.InstallableFixture;
-import org.apache.isis.applib.services.command.Command;
-import org.apache.isis.applib.services.command.CommandContext;
 import org.apache.isis.core.commons.authentication.AuthenticationSession;
 import

[isis] 01/05: ISIS-1841: add -legacy module for integtestsupport

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit f34a7608e1ad97a157a078d84719c8ee71b6d69d
Author: Andi Huber 
AuthorDate: Thu May 31 10:16:09 2018 +0200

ISIS-1841: add -legacy module for integtestsupport

Task-Url: https://issues.apache.org/jira/browse/ISIS-1841
---
 core/legacy/integtestsupport-legacy/pom.xml   | 121 ++
 core/legacy/integtestsupport-legacy/test.data |   5 ++
 2 files changed, 126 insertions(+)

diff --git a/core/legacy/integtestsupport-legacy/pom.xml 
b/core/legacy/integtestsupport-legacy/pom.xml
new file mode 100644
index 000..009a12e
--- /dev/null
+++ b/core/legacy/integtestsupport-legacy/pom.xml
@@ -0,0 +1,121 @@
+
+
+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;>
+   4.0.0
+
+   
+   org.apache.isis.core
+   isis
+${revision}
+   ../../pom.xml
+   
+
+   isis-core-integtestsupport-legacy
+   Apache Isis Integration Testing Support (Legacy)
+
+
+
org.apache.isis.core.integtestsupport-legacy
+
org/apache/isis/core/legacy/integtestsupport-legacy
+
+
+
+   
+   
+   
+
+   
+   org.apache.isis.core
+   isis-core-integtestsupport
+   compile
+   
+   
+   org.apache.isis.core
+   isis-core-integtestsupport
+   test-jar
+   test
+   
+
+   
+
+javax.jdo
+jdo-api
+${jdo-api.version}
+
+provided
+
+
+
+org.apache.isis.core
+isis-core-unittestsupport
+
+
+org.apache.isis.core
+isis-core-specsupport
+
+
+   
+   
+   
+   org.junit.jupiter
+   junit-jupiter-api
+   
+   
+   
+   org.junit.jupiter
+   junit-jupiter-engine
+   
+   
+   
+   org.junit.vintage
+   junit-vintage-engine
+   
+
+
+org.jmock
+jmock
+
+
+
+org.jmock
+jmock-junit4
+
+
+
+org.apache.isis.core
+isis-core-security
+
+
+
+org.apache.isis.core
+isis-core-runtime
+
+
+
+org.apache.isis.core
+isis-core-wrapper
+
+
+
+log4j
+log4j
+
+
+   
+
diff --git a/core/legacy/integtestsupport-legacy/test.data 
b/core/legacy/integtestsupport-legacy/test.data
new file mode 100644
index 000..78b3ff7
--- /dev/null
+++ b/core/legacy/integtestsupport-legacy/test.data
@@ -0,0 +1,5 @@
+org.apache.isis.core.tck.dom.refs.SimpleEntity#4
+  date: 08-Mar-2010 13:32
+  name: Fred Smith
+  nullable: 
+  size: 0

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] 03/05: ISIS-1954: fix some compiler warnings

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 6c34f96e89fd1329b4b46933c87654c3bf19a252
Author: Andi Huber 
AuthorDate: Thu May 31 10:33:47 2018 +0200

ISIS-1954: fix some compiler warnings

Task-Url: https://issues.apache.org/jira/browse/ISIS-1954
---
 .../isis/core/runtime/headless/IsisSystem.java   | 20 ++--
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem.java
index 7a873fa..8892029 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem.java
@@ -19,6 +19,8 @@
 
 package org.apache.isis.core.runtime.headless;
 
+import static org.apache.isis.commons.internal.base._Casts.uncheckedCast;
+
 import java.util.Set;
 
 import org.apache.isis.applib.AppManifest;
@@ -95,22 +97,22 @@ public class IsisSystem {
 
 public T with(IsisConfiguration configuration) {
 this.configuration = (IsisConfigurationDefault) configuration;
-return (T)this;
+return uncheckedCast(this);
 }
 
 public T with(AuthenticationRequest authenticationRequest) {
 this.authenticationRequest = authenticationRequest;
-return (T)this;
+return uncheckedCast(this);
 }
 
 public T with(AppManifest appManifest) {
 this.appManifestIfAny = appManifest;
-return (T)this;
+return uncheckedCast(this);
 }
 
 public T withLoggingAt(org.apache.log4j.Level level) {
 this.level = level;
-return (T)this;
+return uncheckedCast(this);
 }
 
 public S build() {
@@ -119,10 +121,10 @@ public class IsisSystem {
 appManifestIfAny,
 configuration,
 authenticationRequest);
-return (S)configure(isisSystem);
+return configure(uncheckedCast(isisSystem));
 }
 
-protected  T configure(final T isisSystem) {
+protected S configure(final S isisSystem) {
 if(level != null) {
 isisSystem.setLevel(level);
 }
@@ -151,12 +153,10 @@ public class IsisSystem {
 
 }
 
-public static Builder builder() {
-return new Builder();
+public static , S extends IsisSystem> Builder builder() {
+return new Builder<>();
 }
 
-
-
 // -- constructor, fields
 
 // these fields 'xxxForComponentProvider' are used to initialize the 
IsisComponentProvider, but shouldn't be used thereafter.

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated (dabee19 -> 2643fa0)

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git.


from dabee19  ISIS-1957: fixes ServiceInjector fails to handle Generic Types
 new f34a760  ISIS-1841: add -legacy module for integtestsupport
 new 5bbd42d  ISIS-1954: integtestsupport: moving deprecated classes to 
-legacy
 new 6c34f96  ISIS-1954: fix some compiler warnings
 new 3e3f21d  ISIS-1954: IsisSystem: refactoring deprecated methods out 
into a mixin
 new 2643fa0  ISIS-1954: introduces a HeadlessTransactionSupport service

The 5 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../integtestsupport/IntegrationTestAbstract3.java |  19 +-
 .../DefaultHeadlessTransactionSupport.java | 178 ++
 .../integtestsupport-legacy}/pom.xml   |  24 ++-
 .../integtestsupport/IntegrationTestAbstract.java  |   0
 .../integtestsupport/IntegrationTestAbstract2.java |   0
 .../core/integtestsupport/IsisSystemForTest.java   |   0
 .../scenarios/ScenarioExecutionForIntegration.java |   0
 .../integtestsupport-legacy}/test.data |   0
 .../headless/HeadlessTransactionSupport.java}  |   9 +-
 .../HeadlessWithBootstrappingAbstract.java |  18 +-
 .../isis/core/runtime/headless/IsisSystem.java | 208 +
 11 files changed, 234 insertions(+), 222 deletions(-)
 create mode 100644 
core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/components/DefaultHeadlessTransactionSupport.java
 copy core/{integtestsupport => legacy/integtestsupport-legacy}/pom.xml (81%)
 rename core/{integtestsupport => 
legacy/integtestsupport-legacy}/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract.java
 (100%)
 rename core/{integtestsupport => 
legacy/integtestsupport-legacy}/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract2.java
 (100%)
 rename core/{integtestsupport => 
legacy/integtestsupport-legacy}/src/main/java/org/apache/isis/core/integtestsupport/IsisSystemForTest.java
 (100%)
 rename core/{integtestsupport => 
legacy/integtestsupport-legacy}/src/main/java/org/apache/isis/core/integtestsupport/scenarios/ScenarioExecutionForIntegration.java
 (100%)
 copy core/{integtestsupport => legacy/integtestsupport-legacy}/test.data (100%)
 copy 
core/{metamodel/src/main/java/org/apache/isis/core/metamodel/spec/feature/OneToOneFeature.java
 => 
runtime/src/main/java/org/apache/isis/core/runtime/headless/HeadlessTransactionSupport.java}
 (79%)

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] 05/05: ISIS-1954: introduces a HeadlessTransactionSupport service

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 2643fa0f4a8038b7cf35a64830cf1535fcd4490d
Author: Andi Huber 
AuthorDate: Thu May 31 12:12:22 2018 +0200

ISIS-1954: introduces a HeadlessTransactionSupport service

available only for integration support

Task-Url: https://issues.apache.org/jira/browse/ISIS-1954
---
 .../integtestsupport/IntegrationTestAbstract3.java | 16 +---
 .../DefaultHeadlessTransactionSupport.java}| 22 +++---
 ...ternal.java => HeadlessTransactionSupport.java} | 11 +--
 .../HeadlessWithBootstrappingAbstract.java | 17 -
 .../isis/core/runtime/headless/IsisSystem.java | 11 ---
 5 files changed, 37 insertions(+), 40 deletions(-)

diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
index 2bea7bd..7bd30b3 100644
--- 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
+++ 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
@@ -27,6 +27,8 @@ import org.apache.isis.applib.RecoverableException;
 import org.apache.isis.applib.services.jdosupport.IsisJdoSupport;
 import org.apache.isis.applib.services.xactn.TransactionService;
 import org.apache.isis.commons.internal.exceptions._Exceptions;
+import 
org.apache.isis.core.integtestsupport.components.DefaultHeadlessTransactionSupport;
+import org.apache.isis.core.runtime.headless.HeadlessTransactionSupport;
 import org.apache.isis.core.runtime.headless.HeadlessWithBootstrappingAbstract;
 import org.apache.isis.core.runtime.headless.IsisSystem;
 import org.apache.isis.core.runtime.headless.logging.LogConfig;
@@ -69,7 +71,8 @@ public abstract class IntegrationTestAbstract3 extends 
HeadlessWithBootstrapping
 // Instead we expect it to be bootstrapped via @Before
 try {
 base.evaluate();
-
IsisSystem.get().getTransactionSupportInternal().endTran();
+final IsisSystem isft = IsisSystem.get();
+
isft.getService(HeadlessTransactionSupport.class).endTransaction();
 } catch(final Throwable e) {
 // determine if underlying cause is an applib-defined 
exception,
 final RecoverableException recoverableException =
@@ -153,10 +156,17 @@ public abstract class IntegrationTestAbstract3 extends 
HeadlessWithBootstrapping
 protected IntegrationTestAbstract3(
 final LogConfig logConfig,
 final Module module) {
-super(logConfig, module);
+super(logConfig, addHeadlessTransactionSupport(module));
 }
 
-@Override
+//[ahuber] hooks into the bootstrapping, such that the 
+// DefaultHeadlessTransactionSupport is registered as an additional service
+private static Module addHeadlessTransactionSupport(Module module) {
+   
module.getAdditionalServices().add(DefaultHeadlessTransactionSupport.class);
+   return module;
+   }
+
+   @Override
 @Before
 public void bootstrapAndSetupIfRequired() {
 
diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem_Transactions.java
 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/components/DefaultHeadlessTransactionSupport.java
similarity index 93%
rename from 
core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem_Transactions.java
rename to 
core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/components/DefaultHeadlessTransactionSupport.java
index cb931cd..9b81c05 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/headless/IsisSystem_Transactions.java
+++ 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/components/DefaultHeadlessTransactionSupport.java
@@ -17,25 +17,26 @@
  *  under the License.
  */
 
-package org.apache.isis.core.runtime.headless;
+package org.apache.isis.core.integtestsupport.components;
 
+import org.apache.isis.applib.annotation.DomainService;
+import org.apache.isis.applib.annotation.NatureOfService;
 import org.apache.isis.applib.services.command.Command;
 import org.apache.isis.applib.services.command.CommandContext;
 import org.apache.isis.core.metamodel.services.ServicesInjector;
+import org.apache.isis.core.runtime.headless.HeadlessTransactionSupport;
 import org.apache.isis.core.runtime.system.context.IsisContext;
 import org.apache.isis.core.runtime.system.persistence.PersistenceSession;
 import org.apache.isis.core.runtime.system.session.IsisSessionFact

[isis] 02/05: ISIS-1954: integtestsupport: moving deprecated classes to -legacy

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 5bbd42df20ba820add03e29fbe52180c9f7ee9e9
Author: Andi Huber 
AuthorDate: Thu May 31 10:22:01 2018 +0200

ISIS-1954: integtestsupport: moving deprecated classes to -legacy

Task-Url: https://issues.apache.org/jira/browse/ISIS-1954
---
 .../org/apache/isis/core/integtestsupport/IntegrationTestAbstract.java| 0
 .../org/apache/isis/core/integtestsupport/IntegrationTestAbstract2.java   | 0
 .../java/org/apache/isis/core/integtestsupport/IsisSystemForTest.java | 0
 .../core/integtestsupport/scenarios/ScenarioExecutionForIntegration.java  | 0
 4 files changed, 0 insertions(+), 0 deletions(-)

diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract.java
 
b/core/legacy/integtestsupport-legacy/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract.java
similarity index 100%
rename from 
core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract.java
rename to 
core/legacy/integtestsupport-legacy/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract.java
diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract2.java
 
b/core/legacy/integtestsupport-legacy/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract2.java
similarity index 100%
rename from 
core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract2.java
rename to 
core/legacy/integtestsupport-legacy/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract2.java
diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IsisSystemForTest.java
 
b/core/legacy/integtestsupport-legacy/src/main/java/org/apache/isis/core/integtestsupport/IsisSystemForTest.java
similarity index 100%
rename from 
core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IsisSystemForTest.java
rename to 
core/legacy/integtestsupport-legacy/src/main/java/org/apache/isis/core/integtestsupport/IsisSystemForTest.java
diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/scenarios/ScenarioExecutionForIntegration.java
 
b/core/legacy/integtestsupport-legacy/src/main/java/org/apache/isis/core/integtestsupport/scenarios/ScenarioExecutionForIntegration.java
similarity index 100%
rename from 
core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/scenarios/ScenarioExecutionForIntegration.java
rename to 
core/legacy/integtestsupport-legacy/src/main/java/org/apache/isis/core/integtestsupport/scenarios/ScenarioExecutionForIntegration.java

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1950: cleaning up dependencies

2018-05-29 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 07c5fcf  ISIS-1950: cleaning up dependencies
07c5fcf is described below

commit 07c5fcf2d9eea3b068c76c6b68fc0191aaea6231
Author: Andi Huber 
AuthorDate: Tue May 29 22:58:47 2018 +0200

ISIS-1950: cleaning up dependencies

Task-Url: https://issues.apache.org/jira/browse/ISIS-1950
---
 .../ClassDiscoveryServiceDefault.java  |  4 +-
 .../isis/commons/internal/discover/_Discover.java  | 76 --
 .../commons/internal/discover/package-info.java| 28 
 .../classdiscovery/ClassDiscoveryPlugin.java   | 69 +++-
 core/plugins/codegen-bytebuddy/pom.xml |  2 +-
 .../codegen/ProxyFactoryPluginUsingByteBuddy.java  |  3 +-
 core/plugins/discovery-reflections/pom.xml |  2 +-
 .../services/ServicesInstallerFromAnnotation.java  |  4 +-
 .../IsisComponentProvider.java |  4 +-
 core/unittestsupport/pom.xml   | 42 +++-
 .../AbstractApplyToAllContractTest.java| 16 ++---
 .../jmocking/DefaultImposteriserTest.java  | 15 +++--
 12 files changed, 93 insertions(+), 172 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/classdiscovery/ClassDiscoveryServiceDefault.java
 
b/core/applib/src/main/java/org/apache/isis/applib/services/classdiscovery/ClassDiscoveryServiceDefault.java
index 7be60fd..6516d14 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/classdiscovery/ClassDiscoveryServiceDefault.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/services/classdiscovery/ClassDiscoveryServiceDefault.java
@@ -28,7 +28,7 @@ import org.apache.isis.applib.annotation.NatureOfService;
 import org.apache.isis.applib.annotation.Programmatic;
 import org.apache.isis.applib.fixturescripts.FixtureScript;
 import org.apache.isis.commons.internal.base._Casts;
-import org.apache.isis.commons.internal.discover._Discover;
+import org.apache.isis.core.plugins.classdiscovery.ClassDiscoveryPlugin;
 
 /**
  * This utility service supports the dynamic discovery of classes from the 
classpath.  One service that uses this
@@ -57,7 +57,7 @@ implements ClassDiscoveryService {
}
 
// no appManifest or not asking for FixtureScripts
-   return 
_Discover.discoverFullscan(packageNamePrefix).getSubTypesOf(type);
+   return 
ClassDiscoveryPlugin.get().discoverFullscan(packageNamePrefix).getSubTypesOf(type);
}
 
// -- HELPER
diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/discover/_Discover.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/discover/_Discover.java
deleted file mode 100644
index a9e98bf..000
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/discover/_Discover.java
+++ /dev/null
@@ -1,76 +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 org.apache.isis.commons.internal.discover;
-
-import java.util.List;
-
-import org.apache.isis.commons.internal.context._Plugin;
-import org.apache.isis.core.plugins.classdiscovery.ClassDiscovery;
-import org.apache.isis.core.plugins.classdiscovery.ClassDiscoveryPlugin;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- * - internal use only -
- * 
- * Java reflective utilities.
- * 
- * 
- * WARNING: Do NOT use any of the classes provided by this 
package!  
- * These may be changed or removed without notice!
- * 
- * @since 2.0.0
- */
-public final class _Discover {
-
-   private _Discover(){}
-   
-   // -- CLASS DISCOVERY VIA PLUGIN
-
-   //TODO missing java-doc
-   public static ClassDiscovery discover(String packageNamePrefix) {
-   return getPlugin().discover(packageNamePrefix);
-   }
-   
-   //TODO missing java-doc
-   public static ClassDiscovery discover(List packageNamePrefixes) 
{
-   return getPlugin().discover

[isis] branch master updated: ISIS-1950: remove the codegen-javassist-test module and fix tests

2018-05-29 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new dcb6577  ISIS-1950: remove the codegen-javassist-test module and fix 
tests
dcb6577 is described below

commit dcb6577b6324de2f9b306d4610a5bf68de05439c
Author: Andi Huber 
AuthorDate: Wed May 30 00:09:30 2018 +0200

ISIS-1950: remove the codegen-javassist-test module and fix tests

Task-Url: https://issues.apache.org/jira/browse/ISIS-1950
---
 .../plugins-test/codegen-javassist-test/.gitignore |  1 -
 core/plugins-test/codegen-javassist-test/pom.xml   | 80 --
 core/pom.xml   |  1 -
 core/unittestsupport-test/pom.xml  |  6 ++
 ...ServiceInstantiatorTestUsingCodegenPlugin.java} |  2 +-
 ...ava => ImposteriserTestUsingCodegenPlugin.java} | 66 +-
 .../proxy/ProxyCreatorTestUsingCodegenPlugin.java} |  2 +-
 7 files changed, 10 insertions(+), 148 deletions(-)

diff --git a/core/plugins-test/codegen-javassist-test/.gitignore 
b/core/plugins-test/codegen-javassist-test/.gitignore
deleted file mode 100644
index a48e45b..000
--- a/core/plugins-test/codegen-javassist-test/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-/target-ide
diff --git a/core/plugins-test/codegen-javassist-test/pom.xml 
b/core/plugins-test/codegen-javassist-test/pom.xml
deleted file mode 100644
index eecc45d..000
--- a/core/plugins-test/codegen-javassist-test/pom.xml
+++ /dev/null
@@ -1,80 +0,0 @@
-
-
-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;>
-   4.0.0
-
-   
-   org.apache.isis.core
-   isis
-   ${revision}
-   ../../pom.xml
-   
-
-   isis-core-plugins-codegen-javassist-test
-
-   Tests for Apache Isis Plugin for Code Generation 
(Javassist)
-   
-To break cyclic dependencies some tests needed to be moved to their 
own module (this).
-
-
-   
-   
org.apache.isis.plugins.codegen-javassist-test
-   
org/apache/isis/plugins/codegen-javassist-test
-   
-
-   
-   
-   
-   false
-   src/main/resources
-   
-   
-   false
-   src/main/java
-   
-   **
-   
-   
-   **/*.java
-   
-   
-   
-   
-
-   
-   
-   
-   
-   
-   
-   org.apache.isis.core
-   
isis-core-plugins-codegen-javassist
-   test
-   
-   
-   
-   org.apache.isis.core
-   isis-core-wrapper
-   test
-   
-
-   
-   org.apache.isis.core
-   isis-core-unittestsupport
-   test
-   
-
-   
-
-
-
\ No newline at end of file
diff --git a/core/pom.xml b/core/pom.xml
index fb34e65..4926a93 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -2433,7 +2433,6 @@ ${license.additional-notes}
 

unittestsupport-test
-plugins-test/codegen-javassist-test
 
 
 
diff --git a/core/unittestsupport-test/pom.xml 
b/core/unittestsupport-test/pom.xml
index 58d6452..f05a9cd 100644
--- a/core/unittestsupport-test/pom.xml
+++ b/core/unittestsupport-test/pom.xml
@@ -47,6 +47,12 @@
 test
 
 
+
+   org.apache.isis.core
+   isis-core-wrapper
+   test
+   
+
 
 
 org.apache.isis.core
diff --git 
a/core/plugins-test/codegen-javassist-test/src/test/java/org/apache/isis/core/runtime/services/ServiceInstantiatorTestUsingJavassist.java
 
b/core/unittestsupport-test/src/test/java/org/apache/isis/core/runtime/services/ServiceInstantiatorTestUsingCodegenPlugin.java
similarity index 99%
rename from 
core/plugins-test/codegen-javassist-test/src/test/java/org/apache/isis/core/runtime/services/ServiceInstantiatorTestUsingJavassist.java
rename to 
core/unittestsupport-test/src/test/java/org/apache/isis/core/runtime/services/ServiceInstantiatorTestUsingCodegenPlugin.java
index 0b6a6f3..162ccb1 100644
--- 
a/core/plugins-test/codegen-javassist-test/src/test/java/org/apache/isis/core/

[isis] branch master updated: ISIS-1950: break out unittestsupport's own tests into a new module

2018-05-29 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new e2ed1ff  ISIS-1950: break out unittestsupport's own tests into a new 
module
e2ed1ff is described below

commit e2ed1ff5f2883b4a2f008299b7c29fdbd0fef620
Author: Andi Huber 
AuthorDate: Tue May 29 23:29:19 2018 +0200

ISIS-1950: break out unittestsupport's own tests into a new module

Task-Url: https://issues.apache.org/jira/browse/ISIS-1950
---
 core/pom.xml   |   1 +
 core/unittestsupport-test/.gitignore   |   1 +
 .../pom.xml|  18 +---
 .../BidirectionalRelationshipContractTestAll.java  |   0
 .../unittestsupport/bidir/ChildDomainObject.java   |   0
 .../bidir/InstantiatorForChildDomainObject.java|   0
 .../unittestsupport/bidir/ParentDomainObject.java  |   0
 .../unittestsupport/bidir/PeerDomainObject.java|   0
 .../bidir/PeerDomainObjectForTesting.java  |   0
 .../comparable/CategorizedDomainObject.java|   0
 ...mainObjectComparableContractTest_compareTo.java |   0
 .../files/FilesTest_deleteFiles.java   |   0
 ...ectServiceMethodMustBeFinalContractTestAll.java |   0
 .../unittestsupport/inject/SomeDomainObject.java   |   0
 .../core/unittestsupport/inject/SomeService.java   |   0
 .../CollaboratingUsingConstructorInjection.java|   0
 .../CollaboratingUsingSetterInjection.java |   0
 .../unittestsupport/jmocking/Collaborator.java |   0
 .../jmocking/DefaultImposteriserTest.java  |   0
 ...IsisActionsTest_returnNewTransientInstance.java |   0
 .../jmocking/JMockActionsTest_returnArgument.java  |   0
 .../jmocking/JMockActionsTest_returnEach.java  |   0
 .../jmocking/JUnitRuleMockery2Test.java|   0
 ..._autoWiring_constructorInjection_happyCase.java |   0
 ...y2Test_autoWiring_sadCase_noClassUnderTest.java |   0
 ...est_autoWiring_sadCase_twoClassesUnderTest.java |   0
 ...2Test_autoWiring_setterInjection_happyCase.java |   0
 ...RuleMockery2Test_mockAnnotatedWithAllowing.java |   0
 ...RuleMockery2Test_mockAnnotatedWithChecking.java |   0
 ...RuleMockery2Test_mockAnnotatedWithIgnoring.java |   0
 ...kery2Test_mockAnnotatedWithNever_happyCase.java |   0
 ...ockery2Test_mockAnnotatedWithNever_sadCase.java |   0
 ...ockery2Test_mockAnnotatedWithOne_happyCase.java |   0
 ...eMockery2Test_mockAnnotatedWithOne_sadCase.java |   0
 .../sortedsets/SomeDomainObject.java   |   0
 .../sortedsets/SortedSetsContractTestAll.java  |   0
 ...lueTypeContractTestAbstract_BigIntegerTest.java |   0
 .../ValueTypeContractTestAbstract_ColorTest.java   |   0
 .../ValueTypeContractTestAbstract_StringTest.java  |   0
 .../src/test/resources/signed.jar  | Bin
 core/unittestsupport/pom.xml   |  50 +++--
 41 files changed, 30 insertions(+), 40 deletions(-)

diff --git a/core/pom.xml b/core/pom.xml
index 655bb50..fb34e65 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -2432,6 +2432,7 @@ ${license.additional-notes}
 plugins/jdo-datanucleus-5
 

+   unittestsupport-test
 plugins-test/codegen-javassist-test
 
 
diff --git a/core/unittestsupport-test/.gitignore 
b/core/unittestsupport-test/.gitignore
new file mode 100644
index 000..a48e45b
--- /dev/null
+++ b/core/unittestsupport-test/.gitignore
@@ -0,0 +1 @@
+/target-ide
diff --git a/core/unittestsupport/pom.xml b/core/unittestsupport-test/pom.xml
similarity index 89%
copy from core/unittestsupport/pom.xml
copy to core/unittestsupport-test/pom.xml
index ac3b495..58d6452 100644
--- a/core/unittestsupport/pom.xml
+++ b/core/unittestsupport-test/pom.xml
@@ -20,17 +20,17 @@
${revision}

 
-   isis-core-unittestsupport
-   Apache Isis Unit Test Support
+   isis-core-unittestsupport-test
+   Apache Isis Unit Test Support (Tests)
 

-   
org.apache.isis.core.unittestsupport
-   
org/apache/isis/core/unittestsupport
+   
org.apache.isis.core.unittestsupport-test
+   
org/apache/isis/core/unittestsupport-test

 

-   Support for writing unit tests; should be added as a dependency
-   with scope=test only
+   This module is for testing the Unittestsupport module.
+   To break cyclic dependencies some tests needed to be moved to 
their own module (this).

 

@@ -41,6 +41,12 @@
 isis-core-commons
 
 
+
+org.apache.isis.core
+isis-core-unittestsupport
+test
+
+
 
 
 org.apache.isis.core
diff --git 
a/core/unittestsupport/src/test/java/org/apache/isis/core

[isis] branch master updated: ISIS-1950: switching to ByteBuddy as the new default

2018-05-29 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 94118a2  ISIS-1950: switching to ByteBuddy as the new default
94118a2 is described below

commit 94118a2a158368989298883de6d71febbfb27248
Author: Andi Huber 
AuthorDate: Tue May 29 23:44:19 2018 +0200

ISIS-1950: switching to ByteBuddy as the new default

Task-Url: https://issues.apache.org/jira/browse/ISIS-1950
---
 core/unittestsupport/pom.xml | 6 ++
 1 file changed, 6 insertions(+)

diff --git a/core/unittestsupport/pom.xml b/core/unittestsupport/pom.xml
index 94203c9..9096d5b 100644
--- a/core/unittestsupport/pom.xml
+++ b/core/unittestsupport/pom.xml
@@ -40,6 +40,12 @@
 org.apache.isis.core
 isis-core-commons
 
+
+
+
+org.apache.isis.core
+isis-core-plugins-codegen-bytebuddy
+
 



-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] 02/02: ISIS-1950: fixes unittestsupport's own tests

2018-05-29 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 0f98d7133ad98f0d5b37b5edd8218fe1d247beb2
Author: Andi Huber 
AuthorDate: Tue May 29 23:55:37 2018 +0200

ISIS-1950: fixes unittestsupport's own tests

Task-Url: https://issues.apache.org/jira/browse/ISIS-1950
---
 core/{unittestsupport => unittestsupport-test}/xml/objects/CUS.xml   | 0
 core/{unittestsupport => unittestsupport-test}/xml/objects/CUS/1.txt | 0
 core/{unittestsupport => unittestsupport-test}/xml/objects/CUS/1.xml | 0
 core/{unittestsupport => unittestsupport-test}/xml/objects/CUS/2.xml | 0
 4 files changed, 0 insertions(+), 0 deletions(-)

diff --git a/core/unittestsupport/xml/objects/CUS.xml 
b/core/unittestsupport-test/xml/objects/CUS.xml
similarity index 100%
rename from core/unittestsupport/xml/objects/CUS.xml
rename to core/unittestsupport-test/xml/objects/CUS.xml
diff --git a/core/unittestsupport/xml/objects/CUS/1.txt 
b/core/unittestsupport-test/xml/objects/CUS/1.txt
similarity index 100%
rename from core/unittestsupport/xml/objects/CUS/1.txt
rename to core/unittestsupport-test/xml/objects/CUS/1.txt
diff --git a/core/unittestsupport/xml/objects/CUS/1.xml 
b/core/unittestsupport-test/xml/objects/CUS/1.xml
similarity index 100%
rename from core/unittestsupport/xml/objects/CUS/1.xml
rename to core/unittestsupport-test/xml/objects/CUS/1.xml
diff --git a/core/unittestsupport/xml/objects/CUS/2.xml 
b/core/unittestsupport-test/xml/objects/CUS/2.xml
similarity index 100%
rename from core/unittestsupport/xml/objects/CUS/2.xml
rename to core/unittestsupport-test/xml/objects/CUS/2.xml

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated (94118a2 -> 0f98d71)

2018-05-29 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git.


from 94118a2  ISIS-1950: switching to ByteBuddy as the new default
 new ba636b8  ISIS-1950: simplify proxy-factory-plugin API
 new 0f98d71  ISIS-1950: fixes unittestsupport's own tests

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../org/apache/isis/core/plugins/codegen/ProxyFactory.java| 11 +--
 .../apache/isis/core/plugins/codegen/ProxyFactoryPlugin.java  |  4 
 .../plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java |  3 ---
 .../plugins/codegen/ProxyFactoryPluginUsingJavassist.java |  9 -
 .../xml/objects/CUS.xml   |  0
 .../xml/objects/CUS/1.txt |  0
 .../xml/objects/CUS/1.xml |  0
 .../xml/objects/CUS/2.xml |  0
 8 files changed, 5 insertions(+), 22 deletions(-)
 rename core/{unittestsupport => unittestsupport-test}/xml/objects/CUS.xml 
(100%)
 rename core/{unittestsupport => unittestsupport-test}/xml/objects/CUS/1.txt 
(100%)
 rename core/{unittestsupport => unittestsupport-test}/xml/objects/CUS/1.xml 
(100%)
 rename core/{unittestsupport => unittestsupport-test}/xml/objects/CUS/2.xml 
(100%)

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] 01/02: ISIS-1950: simplify proxy-factory-plugin API

2018-05-29 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit ba636b862fc2fb2267d9171a14d54cf9d2bb7c68
Author: Andi Huber 
AuthorDate: Tue May 29 23:51:09 2018 +0200

ISIS-1950: simplify proxy-factory-plugin API

Task-Url: https://issues.apache.org/jira/browse/ISIS-1950
---
 .../org/apache/isis/core/plugins/codegen/ProxyFactory.java| 11 +--
 .../apache/isis/core/plugins/codegen/ProxyFactoryPlugin.java  |  4 
 .../plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java |  3 ---
 .../plugins/codegen/ProxyFactoryPluginUsingJavassist.java |  9 -
 4 files changed, 5 insertions(+), 22 deletions(-)

diff --git 
a/core/commons/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactory.java
 
b/core/commons/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactory.java
index 616810e..6283586 100644
--- 
a/core/commons/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactory.java
+++ 
b/core/commons/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactory.java
@@ -19,8 +19,6 @@
 package org.apache.isis.core.plugins.codegen;
 
 import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Method;
-import java.util.function.Predicate;
 
 /**
  * Generates dynamic classes and corresponding instances by rebasing a given 
'base' class.
@@ -53,11 +51,8 @@ public interface ProxyFactory {
// -- BUILDER (uses plugin)

public static class ProxyFactoryBuilder {
-   private static final Predicate DEFAULT_METHOD_FILTER = 
-   m->!"finalize".equals(m.getName());
private final Class base;
private Class[] interfaces;
-   private Predicate methodFilter = DEFAULT_METHOD_FILTER;
private Class[] constructorArgTypes;
private ProxyFactoryBuilder(Class base) {
this.base = base;
@@ -66,16 +61,12 @@ public interface ProxyFactory {
this.interfaces = interfaces;
return this;
}   
-   public ProxyFactoryBuilder methodFilter(Predicate 
methodFilter) {
-   this.methodFilter = methodFilter;
-   return this;
-   }
public ProxyFactoryBuilder constructorArgTypes(Class[] 
constructorArgTypes) {
this.constructorArgTypes = constructorArgTypes;
return this;
}
public ProxyFactory build() {
-   return ProxyFactoryPlugin.get().factory(base, 
interfaces, methodFilter, constructorArgTypes);
+   return ProxyFactoryPlugin.get().factory(base, 
interfaces, constructorArgTypes);
}
}

diff --git 
a/core/commons/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPlugin.java
 
b/core/commons/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPlugin.java
index bb68ed9..f147060 100644
--- 
a/core/commons/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPlugin.java
+++ 
b/core/commons/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPlugin.java
@@ -18,9 +18,6 @@
  */
 package org.apache.isis.core.plugins.codegen;
 
-import java.lang.reflect.Method;
-import java.util.function.Predicate;
-
 import javax.annotation.Nullable;
 
 import org.apache.isis.commons.internal.context._Plugin;
@@ -32,7 +29,6 @@ public interface ProxyFactoryPlugin {
public  ProxyFactory factory(
Class base, 
@Nullable Class[] interfaces, 
-   @Nullable Predicate methodFilter,
@Nullable Class[] constructorArgTypes);


diff --git 
a/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
 
b/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
index 0a43c98..9bd3035 100644
--- 
a/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
+++ 
b/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
@@ -2,9 +2,7 @@ package org.apache.isis.core.plugins.codegen;
 
 import java.lang.reflect.InvocationHandler;
 import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
 import java.util.function.Function;
-import java.util.function.Predicate;
 
 import javax.annotation.Nullable;
 
@@ -27,7 +25,6 @@ public class ProxyFactoryPluginUsingByteBuddy implements 
ProxyFactoryPlugin {
public  ProxyFactory factory(
Class base, 
Class

[isis] branch master updated: ISIS-1841 simpleapp: bumping lombok and maven-compiler-plugin versions

2018-05-29 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 8d621268 ISIS-1841 simpleapp: bumping lombok and maven-compiler-plugin 
versions
8d621268 is described below

commit 8d6212689a3e609310e94c138a20a83a63b6054b
Author: Andi Huber 
AuthorDate: Tue May 29 10:34:17 2018 +0200

ISIS-1841 simpleapp: bumping lombok and maven-compiler-plugin versions
---
 example/application/simpleapp/application/pom.xml  |  2 --
 .../application/simpleapp/module-simple/pom.xml|  8 ---
 example/application/simpleapp/pom.xml  | 27 +-
 example/application/simpleapp/webapp/pom.xml   |  1 -
 4 files changed, 1 insertion(+), 37 deletions(-)

diff --git a/example/application/simpleapp/application/pom.xml 
b/example/application/simpleapp/application/pom.xml
index 7098f15..a3d3705 100644
--- a/example/application/simpleapp/application/pom.xml
+++ b/example/application/simpleapp/application/pom.xml
@@ -107,7 +107,6 @@
 
 org.apache.isis.core
 isis-core-wrapper
-${isis.version}
 
 
 
@@ -121,7 +120,6 @@
 
 org.apache.isis.mavendeps
 isis-mavendeps-testing
-${isis.version}
 pom
 test
 
diff --git a/example/application/simpleapp/module-simple/pom.xml 
b/example/application/simpleapp/module-simple/pom.xml
index 29f5121..09db1bc 100644
--- a/example/application/simpleapp/module-simple/pom.xml
+++ b/example/application/simpleapp/module-simple/pom.xml
@@ -144,7 +144,6 @@
 
 org.apache.isis.core
 isis-core-applib
-${isis.version}
 
 
 
@@ -152,31 +151,26 @@
 
org.apache.isis.core

isis-core-plugins-codegen-javassist
-   ${isis.version}

 
 
 org.apache.isis.core
 isis-core-plugins-discovery-reflections
-${isis.version}
 
 

 org.apache.isis.core
 isis-core-plugins-jdo-datanucleus-5
-${isis.version}
 
 
 
 org.apache.isis.core
 isis-core-plugins-eventbus-guava
-${isis.version}
 
 

 org.apache.isis.core
 isis-core-plugins-jaxrs-resteasy-3
-${isis.version}
 
 
 
@@ -184,7 +178,6 @@
 
 org.apache.isis.mavendeps
 isis-mavendeps-testing
-${isis.version}
 pom
 test
 
@@ -192,7 +185,6 @@
 
 org.hsqldb
 hsqldb
-${hsqldb.version}
 test
 
 
diff --git a/example/application/simpleapp/pom.xml 
b/example/application/simpleapp/pom.xml
index 9c95460..242ede8 100644
--- a/example/application/simpleapp/pom.xml
+++ b/example/application/simpleapp/pom.xml
@@ -39,7 +39,7 @@
 2.0.0-M1-SNAPSHOT
 2.0.0-M1-SNAPSHOT
 
-1.16.20
+[1.16,)
 
 1.8
 1.8
@@ -150,31 +150,6 @@
 
 
 
-
-
-m2e
-
-
-m2e.version
-
-
-
-target-ide
-
-
-
-maven-compiler-plugin
-
-${compiler-plugin.source}
-${compiler-plugin.target}
-
${compiler-plugin.compilerArgument}
-
-
-
-
-
-
-
 
 module-simple
 application
diff --git a/example/application/simpleapp/webapp/pom.xml 
b/example/application/simpleapp/webapp/pom.xml
index 498c24d..b7b6701 100644
--- a/example/application/simpleapp/webapp/pom.xml
+++ b/example/application/simpleapp/webapp/pom.xml
@@ -118,7 +118,6 @@
 
 org.apache.isis.mavendeps
 isis-mavendeps-webapp
-${isis.version}
 pom
 
 

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1956: introduces _Reflect (Internal API), removes org.reflections

2018-05-30 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new d119856  ISIS-1956: introduces _Reflect (Internal API), removes 
org.reflections
d119856 is described below

commit d1198565aa1381ca963141aa7f27a8ff170595e7
Author: Andi Huber 
AuthorDate: Wed May 30 09:21:43 2018 +0200

ISIS-1956: introduces _Reflect (Internal API), removes org.reflections

Task-Url: https://issues.apache.org/jira/browse/ISIS-1956
---
 .../apache/isis/commons/internal/_Constants.java   |  12 ++
 .../commons/internal/collections/_Collections.java |  10 ++
 .../isis/commons/internal/reflection/_Reflect.java | 164 +
 .../package-info.java} |  43 +-
 core/unittestsupport-test/pom.xml  |  19 ---
 core/unittestsupport/pom.xml   |  20 ---
 .../AbstractApplyToAllContractTest.java|   9 +-
 ...irectionalRelationshipContractTestAbstract.java | 104 +
 .../unittestsupport/bidir/InstantiatorMap.java |   8 +-
 .../ComparableContractTest_compareTo.java  |   3 +-
 .../comparable/ComparableContractTester.java   |   8 +-
 ...rviceMethodMustBeFinalContractTestAbstract.java |  11 +-
 .../core/unittestsupport/jaxb/JaxbMatchers.java|  18 +--
 .../core/unittestsupport/jmocking/IsisActions.java |   3 +-
 .../unittestsupport/jmocking/JMockActions.java |   6 +-
 .../jmocking/JUnitRuleMockery2.java|   6 +-
 .../unittestsupport/jmocking/MyMockomatic.java |  11 +-
 .../unittestsupport/soap/PublishedEndpoints.java   |   7 +-
 .../soap/SoapEndpointPublishingRule.java   |  24 +--
 .../unittestsupport/soap/SoapEndpointSpec.java |  14 +-
 .../sortedsets/SortedSetsContractTestAbstract.java |  13 +-
 .../core/unittestsupport/utils/CollectUtils.java   |   2 -
 .../core/unittestsupport/utils/ReflectUtils.java   |  52 +++
 23 files changed, 356 insertions(+), 211 deletions(-)

diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/_Constants.java 
b/core/commons/src/main/java/org/apache/isis/commons/internal/_Constants.java
index 85c86a4..fb789f6 100644
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/_Constants.java
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/_Constants.java
@@ -19,6 +19,9 @@
 
 package org.apache.isis.commons.internal;
 
+import java.io.IOException;
+import java.io.Writer;
+
 /**
  * - internal use only -
  * 
@@ -55,5 +58,14 @@ public final class _Constants {
 * empty array of byte
 */
public static final byte[] emptyBytes = new byte[0];
+
+   /**
+* writer that does nothing
+*/
+   public static final Writer nopWriter = new Writer() {
+   @Override public void write(char[] cbuf, int off, int 
len) throws IOException { }
+   @Override public void flush() throws IOException { }
+   @Override public void close() throws IOException { }
+   };

 }
diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/collections/_Collections.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/collections/_Collections.java
index 91dffda..38d0725 100644
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/collections/_Collections.java
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/collections/_Collections.java
@@ -143,6 +143,16 @@ public final class _Collections {
return _Collections_SortedSetOfList.of(list);
}
 
+   // -- STREAM TO COMMON COLLECTIONS
+   
+   public static  Collector> toHashSet() {
+   return Collectors.toCollection(HashSet::new);
+   }
+   
+   public static  Collector> toArrayList() {
+   return Collectors.toCollection(ArrayList::new);
+   }
+   
// -- STREAM TO UMODIFIABLE COLLECTION COLLECTORS

/**
diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
new file mode 100644
index 000..da1c3bc
--- /dev/null
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
@@ -0,0 +1,164 @@
+/*
+ *  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/lice

[isis] branch master updated: ISIS-1956: fixes java-doc

2018-05-30 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new a1fc33c  ISIS-1956: fixes java-doc
a1fc33c is described below

commit a1fc33c361cfd78dbdbaef2303ecaee33e4f1ffc
Author: Andi Huber 
AuthorDate: Wed May 30 09:53:29 2018 +0200

ISIS-1956: fixes java-doc
---
 .../isis/commons/internal/reflection/_Reflect.java | 158 ++---
 1 file changed, 79 insertions(+), 79 deletions(-)

diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
index da1c3bc..f7c4780 100644
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
@@ -46,118 +46,118 @@ import javax.annotation.Nullable;
  * @since 2.0.0
  */
 public final class _Reflect {
-   
+
private _Reflect() {}
-   
+
// -- PREDICATES
-   
+
/**
-* Whether member name equals given {@code prefix}
-* @param prefix
+* Whether member name equals given {@code memberName}
+* @param memberName
 * @return
 */
-public static  Predicate withName(final String 
memberName) {
-   return m -> m != null && memberName.equals(m.getName());
-}
-   
+   public static  Predicate withName(final String 
memberName) {
+   return m -> m != null && memberName.equals(m.getName());
+   }
+
/**
-* Whether member name startsWith given {@code prefix}
+* Whether member name starts with given {@code prefix}
 * @param prefix
 * @return
 */
-public static  Predicate withPrefix(final String 
prefix) {
-   return m -> m != null && m.getName().startsWith(prefix);
-}
-   
+   public static  Predicate withPrefix(final String 
prefix) {
+   return m -> m != null && m.getName().startsWith(prefix);
+   }
+
/**
 * Whether method parameters count equal to given {@code count}
 * @param count
 * @return
 */
-public static Predicate withMethodParametersCount(final int count) 
{
-   return (Method m) -> m != null && m.getParameterTypes().length == count;
-}
-
-/**
- * Whether field type is assignable to given {@code type}
- * @param type
- * @return
- */
-public static  Predicate withTypeAssignableTo(final Class 
type) {
-   return (Field f) -> f != null && type.isAssignableFrom(f.getType());
-}
-   
+   public static Predicate withMethodParametersCount(final int 
count) {
+   return (Method m) -> m != null && m.getParameterTypes().length 
== count;
+   }
+
+   /**
+* Whether field type is assignable to given {@code type}
+* @param type
+* @return
+*/
+   public static  Predicate withTypeAssignableTo(final Class 
type) {
+   return (Field f) -> f != null && 
type.isAssignableFrom(f.getType());
+   }
+
// -- FIELDS
-   
-/**
- * Stream fields of given {@code type} 
- * @param type (nullable)
- * @return
- */
-public static Stream streamFields(@Nullable Class type) {
-   return stream( mapIfPresentElse(type, Class::getDeclaredFields, 
(Field[])null) );
-}
-   
+
+   /**
+* Stream fields of given {@code type} 
+* @param type (nullable)
+* @return
+*/
+   public static Stream streamFields(@Nullable Class type) {
+   return stream( mapIfPresentElse(type, Class::getDeclaredFields, 
(Field[])null) );
+   }
+
/**
 * Stream all fields of given {@code type}, up the super class 
hierarchy. 
 * @param type (nullable)
 * @return
 */
public static Stream streamAllFields(@Nullable Class type) {
-   return streamTypeHierarchy(type)
-   .filter(Object.class::equals) // do not process Object 
class.
-   .flatMap(_Reflect::streamFields);
-}
-   
+   return streamTypeHierarchy(type)
+   .filter(Object.class::equals) // do not process 
Object class.
+   .flatMap(_Reflect::streamFields);
+   }
+
// -- METHODS
-   
-/**
- * Stream methods of given {@code type} 
- * @param type (nullable)
- * @return
- */
-public static Stream streamMethods(@Nullable Class type) {
-   return stream( mapIfPresentElse(type, 
-   type.isInterface() ? Class::getMethods : 
Class::getDeclaredMethods, (Method

[isis] branch master updated: ISIS-1956: further java-doc fixes

2018-05-30 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 2b0a89a  ISIS-1956: further java-doc fixes
2b0a89a is described below

commit 2b0a89a0bc935d35923725aebe375b6599675a35
Author: Andi Huber 
AuthorDate: Wed May 30 10:57:20 2018 +0200

ISIS-1956: further java-doc fixes
---
 .../java/org/apache/isis/commons/internal/reflection/_Reflect.java | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
index f7c4780..6eb928d 100644
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
@@ -132,12 +132,11 @@ public final class _Reflect {
.flatMap(_Reflect::streamMethods);
}
 
-   // SUPER CLASSES
+   // -- SUPER CLASSES
 
/**
 * Stream all types of given {@code type}, up the super class hierarchy 
starting with self
 * @param type
-* @param includeObject whether to include {@code Object}
 * @return
 */
public static Stream> streamTypeHierarchy(@Nullable Class 
type) {

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1956: polishing _Reflect (Internal API)

2018-05-30 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 53a8ff7  ISIS-1956: polishing _Reflect (Internal API)
53a8ff7 is described below

commit 53a8ff76c48dd100c1b1391cbb3deab43e0c1735
Author: Andi Huber 
AuthorDate: Wed May 30 11:00:57 2018 +0200

ISIS-1956: polishing _Reflect (Internal API)
---
 .../java/org/apache/isis/commons/internal/reflection/_Reflect.java  | 6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
index 6eb928d..2ad189e 100644
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/reflection/_Reflect.java
@@ -21,6 +21,7 @@ package org.apache.isis.commons.internal.reflection;
 
 import static org.apache.isis.commons.internal.base._NullSafe.stream;
 import static org.apache.isis.commons.internal.base._With.mapIfPresentElse;
+import static org.apache.isis.commons.internal.base._With.requires;
 
 import java.lang.reflect.Field;
 import java.lang.reflect.Member;
@@ -57,6 +58,7 @@ public final class _Reflect {
 * @return
 */
public static  Predicate withName(final String 
memberName) {
+   requires(memberName, "memberName");
return m -> m != null && memberName.equals(m.getName());
}
 
@@ -66,6 +68,7 @@ public final class _Reflect {
 * @return
 */
public static  Predicate withPrefix(final String 
prefix) {
+   requires(prefix, "prefix");
return m -> m != null && m.getName().startsWith(prefix);
}
 
@@ -84,6 +87,7 @@ public final class _Reflect {
 * @return
 */
public static  Predicate withTypeAssignableTo(final Class 
type) {
+   requires(type, "type");
return (Field f) -> f != null && 
type.isAssignableFrom(f.getType());
}
 
@@ -136,7 +140,7 @@ public final class _Reflect {
 
/**
 * Stream all types of given {@code type}, up the super class hierarchy 
starting with self
-* @param type
+* @param type (nullable)
 * @return
 */
public static Stream> streamTypeHierarchy(@Nullable Class 
type) {

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1951 cleanup objenesis and javassist references in POMs

2018-05-30 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 90d28b1  ISIS-1951 cleanup objenesis and javassist references in POMs
90d28b1 is described below

commit 90d28b10b56a49151e6dc34a493b6fbf284e8111
Author: Andi Huber 
AuthorDate: Wed May 30 11:49:07 2018 +0200

ISIS-1951 cleanup objenesis and javassist references in POMs
---
 core/legacy/unittestsupport-legacy/pom.xml |  1 +
 core/mavendeps/testing/pom.xml |  4 
 core/plugins/codegen-bytebuddy/pom.xml |  8 +---
 core/plugins/codegen-javassist/pom.xml |  6 ++
 core/pom.xml   | 21 +
 core/unittestsupport-test/pom.xml  |  7 ---
 6 files changed, 13 insertions(+), 34 deletions(-)

diff --git a/core/legacy/unittestsupport-legacy/pom.xml 
b/core/legacy/unittestsupport-legacy/pom.xml
index 08c1494..98f59e2 100644
--- a/core/legacy/unittestsupport-legacy/pom.xml
+++ b/core/legacy/unittestsupport-legacy/pom.xml
@@ -77,6 +77,7 @@
 
 org.objenesis
 objenesis
+2.4
 true
 
 
diff --git a/core/mavendeps/testing/pom.xml b/core/mavendeps/testing/pom.xml
index 4740d4c..f5f99c6 100644
--- a/core/mavendeps/testing/pom.xml
+++ b/core/mavendeps/testing/pom.xml
@@ -62,10 +62,6 @@
 
 
 
-org.objenesis
-objenesis
-
-
 org.hamcrest
 hamcrest-library
 
diff --git a/core/plugins/codegen-bytebuddy/pom.xml 
b/core/plugins/codegen-bytebuddy/pom.xml
index 699c718..4d021f7 100644
--- a/core/plugins/codegen-bytebuddy/pom.xml
+++ b/core/plugins/codegen-bytebuddy/pom.xml
@@ -30,7 +30,8 @@
 

1.8.0
-   
+   2.4
+

org.apache.isis.plugins.codegen-bytebuddy

org/apache/isis/plugins/codegen-bytebuddy

@@ -61,12 +62,13 @@
byte-buddy
${bytebuddy.version}

-   
+

org.objenesis
objenesis
+   ${objenesis.version}

-
+   

org.apache.isis.core
isis-core-commons
diff --git a/core/plugins/codegen-javassist/pom.xml 
b/core/plugins/codegen-javassist/pom.xml
index eaad977..bbce5a7 100644
--- a/core/plugins/codegen-javassist/pom.xml
+++ b/core/plugins/codegen-javassist/pom.xml
@@ -28,6 +28,10 @@
 
 

+   2.4
+   3.20.0-GA
+   
+   

org.apache.isis.plugins.codegen-javassist

org/apache/isis/plugins/codegen-javassist

@@ -58,11 +62,13 @@

org.javassist
javassist
+   ${javassist.version}



org.objenesis
objenesis
+   ${objenesis.version}

 

diff --git a/core/pom.xml b/core/pom.xml
index 4926a93..36dc623 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -129,10 +129,8 @@
 19.0
 
 1.3
-
 3.6.2
-2.4
-3.20.0-GA
+
 0.9.10
 2.0.1
 
@@ -1658,18 +1656,6 @@ ${license.additional-notes}
 ${picocontainer.version}
 
 
-
-
-org.objenesis
-objenesis
-${objenesis.version}
-
-
-org.javassist
-javassist
-${javassist.version}
-
-
 
 
 com.fasterxml.jackson.core
@@ -2183,11 +2169,6 @@ ${license.additional-notes}
 jmock-junit4
 test
 
-
-org.objenesis
-objenesis
-test
-
 
 
 
diff --git a/core/unittestsupport-test/pom.xml 
b/core/unittestsupport-test/pom.xml
index b55dc28..aa63136 100644
--- a/core/unittestsupport-test/pom.xml
+++ b/core/unittestsupport-test/pom.xml
@@ -60,17 +60,10 @@
 runtime
 
 
-   org.javassist
-   javassist
-   test
-   true
-   
-
 org.apache.isis.core
 isis-core-plugins-codegen-bytebuddy
 runtime
 
-
 



-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1841 simpleapp: eclipse doesn't support maven mixins config

2018-05-29 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new faf535c  ISIS-1841 simpleapp: eclipse doesn't support maven mixins 
config
faf535c is described below

commit faf535cfa0bee9fa5effec3a768c149873c48b63
Author: Andi Huber 
AuthorDate: Tue May 29 11:22:35 2018 +0200

ISIS-1841 simpleapp: eclipse doesn't support maven mixins config

reverts latest profile removal
---
 example/application/simpleapp/pom.xml | 25 +
 1 file changed, 25 insertions(+)

diff --git a/example/application/simpleapp/pom.xml 
b/example/application/simpleapp/pom.xml
index 242ede8..1a56ad0 100644
--- a/example/application/simpleapp/pom.xml
+++ b/example/application/simpleapp/pom.xml
@@ -150,6 +150,31 @@
 
 
 
+
+
+m2e
+
+
+m2e.version
+
+
+
+target-ide
+
+
+
+maven-compiler-plugin
+
+${compiler-plugin.source}
+${compiler-plugin.target}
+
${compiler-plugin.compilerArgument}
+
+
+
+
+
+
+
 
 module-simple
 application

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1955: move SimpleTicket to 'runtime' and do html escaping

2018-05-28 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new d590b7e  ISIS-1955: move SimpleTicket to 'runtime' and do html escaping
d590b7e is described below

commit d590b7e4852cf6c658b926197c7ccb1a3ac8d969
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Mon May 28 12:53:24 2018 +0200

ISIS-1955: move SimpleTicket to 'runtime' and do html escaping

Task-Url: https://issues.apache.org/jira/browse/ISIS-1955
---
 .../core/runtime}/services/error/SimpleTicket.java | 25 ++
 1 file changed, 16 insertions(+), 9 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/error/SimpleTicket.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/error/SimpleTicket.java
similarity index 80%
rename from 
core/applib/src/main/java/org/apache/isis/applib/services/error/SimpleTicket.java
rename to 
core/runtime/src/main/java/org/apache/isis/core/runtime/services/error/SimpleTicket.java
index dc46358..5ff1d19 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/error/SimpleTicket.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/error/SimpleTicket.java
@@ -16,11 +16,15 @@
  *  specific language governing permissions and limitations
  *  under the License.
  */
-package org.apache.isis.applib.services.error;
+package org.apache.isis.core.runtime.services.error;
+
+import static org.apache.isis.commons.internal.base._NullSafe.isEmpty;
 
 import java.io.Serializable;
+import java.util.function.UnaryOperator;
 
-import org.apache.isis.commons.internal.base._NullSafe;
+import org.apache.isis.applib.services.error.ErrorReportingService;
+import org.apache.isis.applib.services.error.Ticket;
 
 /**
  * Response from the {@link ErrorReportingService}, containing information to 
show to the end-user.
@@ -109,19 +113,22 @@ public class SimpleTicket implements Ticket {
 
 @Override
public String getMarkup() {
- 
return
"" + 
-   "" + getDetails() + "" +
-   (_NullSafe.isEmpty(getKittenUrl()) ? "" : "") +
+   ifPresentMap(getDetails(), s->"" + htmlEscape(s) + "") +
+   ifPresentMap(getKittenUrl(), s->"") +
"" + 
-   (_NullSafe.isEmpty(getReference()) ? "" : 
-   "Please quote reference: " + 
getReference() + "")
+   ifPresentMap(getReference(), s-> 
+   "Please quote reference: " + htmlEscape(s) 
+ "")
;
-   
}
 
+protected static String ifPresentMap(String x, UnaryOperator 
operator) {
+   return isEmpty(x) ? "" : operator.apply(x);
+}
 
-
+protected static String htmlEscape(String source) {
+   return com.google.common.html.HtmlEscapers.htmlEscaper().escape(source);
+}
 
 }

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1277 reflective access: opens javax.xml/javax.xml.bind

2018-05-30 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 33c0c4f  ISIS-1277 reflective access: opens javax.xml/javax.xml.bind
33c0c4f is described below

commit 33c0c4f0f937636809afc088a37fe8e56380e515
Author: Andi Huber 
AuthorDate: Wed May 30 12:45:23 2018 +0200

ISIS-1277 reflective access: opens javax.xml/javax.xml.bind
---
 .../services/grid/GridLoaderServiceDefault.java| 33 +-
 core/pom.xml   |  3 ++
 2 files changed, 16 insertions(+), 20 deletions(-)

diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/grid/GridLoaderServiceDefault.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/grid/GridLoaderServiceDefault.java
index c35482c..dbe2009 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/grid/GridLoaderServiceDefault.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/grid/GridLoaderServiceDefault.java
@@ -27,14 +27,6 @@ import javax.annotation.PostConstruct;
 import javax.xml.bind.JAXBContext;
 import javax.xml.bind.JAXBException;
 
-import com.google.common.base.Function;
-import com.google.common.collect.FluentIterable;
-import com.google.common.collect.Maps;
-import com.google.common.io.Resources;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
 import org.apache.isis.applib.annotation.DomainService;
 import org.apache.isis.applib.annotation.NatureOfService;
 import org.apache.isis.applib.annotation.Programmatic;
@@ -43,8 +35,14 @@ import 
org.apache.isis.applib.services.grid.GridLoaderService;
 import org.apache.isis.applib.services.grid.GridSystemService;
 import org.apache.isis.applib.services.jaxb.JaxbService;
 import org.apache.isis.applib.services.message.MessageService;
-import org.apache.isis.commons.internal._Constants;
+import org.apache.isis.commons.internal.base._NullSafe;
+import org.apache.isis.commons.internal.collections._Arrays;
 import org.apache.isis.core.metamodel.deployment.DeploymentCategoryProvider;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import com.google.common.collect.Maps;
+import com.google.common.io.Resources;
 
 @DomainService(
 nature = NatureOfService.DOMAIN,
@@ -65,15 +63,12 @@ public class GridLoaderServiceDefault implements 
GridLoaderService {
 
 @PostConstruct
 public void init(){
-final List> pageImplementations =
-FluentIterable.from(gridSystemServices)
-.transform(
-(Function>) gss -> gss.gridImplementation())
-.toList();
-
-final Class[] clazz = 
pageImplementations.toArray(_Constants.emptyClasses);
+final Class[] pageImplementations =
+   _NullSafe.stream(gridSystemServices)
+   .map(GridSystemService::gridImplementation)
+   .collect(_Arrays.toArray(Class.class));
 try {
-jaxbContext = JAXBContext.newInstance(clazz);
+jaxbContext = JAXBContext.newInstance(pageImplementations);
 } catch (JAXBException e) {
 // leave as null
 }
@@ -238,8 +233,6 @@ public class GridLoaderServiceDefault implements 
GridLoaderService {
 JaxbService jaxbService;
 
 @javax.inject.Inject
-List gridSystemServices;
-
-
+List> gridSystemServices;
 
 }
diff --git a/core/pom.xml b/core/pom.xml
index 36dc623..73186cd 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -602,6 +602,9 @@
 false
 ${compileSource}
 ${compileTarget}
+
+   
--add-opensjavax.xml/javax.xml.bind=ALL-UNNAMED
+
 
 
 

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1277 move jdk 9+ build config into separate mvn profile 'jdk9plus'

2018-05-30 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 7431ad5  ISIS-1277 move jdk 9+ build config into separate mvn profile 
'jdk9plus'
7431ad5 is described below

commit 7431ad54e25a0169e9ad0b494369a72e61a4ba25
Author: Andi Huber 
AuthorDate: Wed May 30 12:54:16 2018 +0200

ISIS-1277 move jdk 9+ build config into separate mvn profile 'jdk9plus'
---
 core/pom.xml | 35 +++
 1 file changed, 31 insertions(+), 4 deletions(-)

diff --git a/core/pom.xml b/core/pom.xml
index 73186cd..4d68f34 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -602,14 +602,10 @@
 false
 ${compileSource}
 ${compileTarget}
-
-   
--add-opensjavax.xml/javax.xml.bind=ALL-UNNAMED
-
 
 
 
 
-
 
 
 
@@ -2202,6 +2198,37 @@ ${license.additional-notes}
 
 
 
+
+   
+   jdk9plus
+   
+   [9,)
+   
+   
+   
+
+   
+   
+   
org.apache.maven.plugins
+   
maven-compiler-plugin
+   
+   
true
+   
true
+   
${compileSource}
+   
${compileTarget}
+   
+   --add-opens
+   
javax.xml/javax.xml.bind=ALL-UNNAMED
+   
+   
+   
+   
+   
+
+   
+   
+   
+
 
 m2e
 

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1277 rename mvn profile 'jdk9plus' -> 'jdk10plus'

2018-05-30 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new d8aa4a2  ISIS-1277 rename mvn profile 'jdk9plus' -> 'jdk10plus'
d8aa4a2 is described below

commit d8aa4a206b982a62ae21cd330aa555e6166022bb
Author: Andi Huber 
AuthorDate: Wed May 30 13:05:43 2018 +0200

ISIS-1277 rename mvn profile 'jdk9plus' -> 'jdk10plus'
---
 core/pom.xml | 457 +--
 1 file changed, 228 insertions(+), 229 deletions(-)

diff --git a/core/pom.xml b/core/pom.xml
index 4d68f34..33ff20d 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -2170,235 +2170,234 @@ ${license.additional-notes}
 
 
 
-
-
-apache-release
-
-
-
-org.apache.maven.plugins
-maven-toolchains-plugin
-1.1
-
-
-
-toolchain
-
-
-
-
-
-
-1.8
-oracle
-
-
-
-
-
-
-
-
-   
-   jdk9plus
-   
-   [9,)
-   
-   
-   
-
-   
-   
-   
org.apache.maven.plugins
-   
maven-compiler-plugin
-   
-   
true
-   
true
-   
${compileSource}
-   
${compileTarget}
-   
-   --add-opens
-   
javax.xml/javax.xml.bind=ALL-UNNAMED
-   
-   
-   
-   
-   
-
-   
-   
-   
-
-
-m2e
-
-
-m2e.version
-
-
-
-target-ide
-
-
-
-
-
-deploy-local
-
-
-deploy
-local
-
-
-
-
-file:///tmp/m2-sites/isis
-
-
-
-
-
-deploy-snapshot
-
-
-deploy
-snapshot
-
-
-
-
-
-org.apache.maven.plugins
-maven-deploy-plugin
-true
-
-false
-
-
-
-
-
-
-
-nexus-deploy
-
-
-nexus-deploy
-
-
-
-
http://localhost:8081/repository/builds
-
-
-
-
-org.sonatype.plugins
-nexus-staging-maven-plugin
-1.6.8
-true
-
-nexus-deploy.serverId
-true
-
-
-
-
-
-
-nexus-deploy.serverId
-${nexus-deploy.repositoryUrl}
-
-
-
-
-owasp
-
-
-owasp
-
-
-
-
-
-org.owasp
-dependency-check-maven
-1.3.1
-
-
-owasp-aggregate
-
-agg

[isis] branch master updated: ISIS-1277 fixes jdk10 build

2018-05-30 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 66b7174  ISIS-1277 fixes jdk10 build
66b7174 is described below

commit 66b7174e99b92772ef3adb6275d9b3407433dc95
Author: Andi Huber 
AuthorDate: Wed May 30 13:43:54 2018 +0200

ISIS-1277 fixes jdk10 build
---
 core/maven-plugin/pom.xml | 2 ++
 core/pom.xml  | 1 +
 2 files changed, 3 insertions(+)

diff --git a/core/maven-plugin/pom.xml b/core/maven-plugin/pom.xml
index c16385a..40f35a6 100644
--- a/core/maven-plugin/pom.xml
+++ b/core/maven-plugin/pom.xml
@@ -82,6 +82,8 @@
 
 org.apache.maven.plugins
 maven-plugin-plugin
+
+3.5.2
 
 configurator
 
diff --git a/core/pom.xml b/core/pom.xml
index 33ff20d..880991d 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -2216,6 +2216,7 @@ ${license.additional-notes}

true
10
10
+   


--add-opens

javax.xml/javax.xml.bind=ALL-UNNAMED

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1958: improve code readability

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new e0aa6b6  ISIS-1958: improve code readability
e0aa6b6 is described below

commit e0aa6b6577d3d9c3b6b044c856a0eaaabe17e24d
Author: Andi Huber 
AuthorDate: Thu May 31 18:11:36 2018 +0200

ISIS-1958: improve code readability

Task-Url: https://issues.apache.org/jira/browse/ISIS-1958
---
 .../main/java/org/apache/isis/applib/Module.java   | 36 --
 1 file changed, 19 insertions(+), 17 deletions(-)

diff --git a/core/applib/src/main/java/org/apache/isis/applib/Module.java 
b/core/applib/src/main/java/org/apache/isis/applib/Module.java
index 91b6ec7..928100c 100644
--- a/core/applib/src/main/java/org/apache/isis/applib/Module.java
+++ b/core/applib/src/main/java/org/apache/isis/applib/Module.java
@@ -18,14 +18,13 @@
  */
 package org.apache.isis.applib;
 
-import static org.apache.isis.commons.internal.base._With.accept;
-import static org.apache.isis.commons.internal.collections._Lists.newArrayList;
 import static 
org.apache.isis.commons.internal.collections._Maps.newLinkedHashMap;
 
 import java.util.LinkedHashSet;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
+import java.util.stream.Collectors;
 
 import org.apache.isis.applib.annotation.DomainService;
 import org.apache.isis.applib.fixturescripts.FixtureScript;
@@ -211,27 +210,30 @@ public interface Module {
 }
 
 static Map transitiveIndividualConfigPropsOf(final 
Module module) {
-   return accept(newLinkedHashMap(), props->{
-   transitiveDependenciesOf(module).stream()
-   .map(Module::getIndividualConfigProps)
-   .forEach(props::putAll);
-   });
+   final Map props = newLinkedHashMap();
+   
+   transitiveDependenciesOf(module).stream()
+   .map(Module::getIndividualConfigProps)
+   .forEach(props::putAll);
+   
+   return props;
 }
 
 static Map transitiveFallbackConfigPropsOf(final 
Module module) {
-   return accept(newLinkedHashMap(), props->{
-   transitiveDependenciesOf(module).stream()
-   .map(Module::getFallbackConfigProps)
-   .forEach(props::putAll);
-   });
+   final Map props = newLinkedHashMap();
+   
+   transitiveDependenciesOf(module).stream()
+   .map(Module::getFallbackConfigProps)
+   .forEach(props::putAll);
+   
+   return props;
 }
 
 static List transitivePropertyResourcesOf(final 
Module module) {
-   return accept(newArrayList(), resources->{
-   transitiveDependenciesOf(module).stream()
-   .map(Module::getPropertyResources)
-   .forEach(resources::addAll);
-   });
+   return transitiveDependenciesOf(module).stream()
+   .map(Module::getPropertyResources)
+   .flatMap(List::stream)
+   .collect(Collectors.toList());
 }
 }
 

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1958: extending org.apache.isis.applib.Module

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new f47d31a  ISIS-1958: extending org.apache.isis.applib.Module
f47d31a is described below

commit f47d31af2486dab6866c942e9430e00038876988
Author: Andi Huber 
AuthorDate: Thu May 31 17:58:12 2018 +0200

ISIS-1958: extending org.apache.isis.applib.Module

additional to override logic, allow for fallback logic

Task-Url: https://issues.apache.org/jira/browse/ISIS-1958
---
 .../apache/isis/applib/AppManifestAbstract.java| 20 +++---
 .../main/java/org/apache/isis/applib/Module.java   | 44 ++
 .../isis/applib/ModuleOrBuilderAbstract.java   | 27 ++---
 .../commons/internal/collections/_Collections.java |  2 +-
 .../integtestsupport/IntegrationTestAbstract3.java |  2 +-
 .../integtestsupport/IntegrationTestJupiter.java   |  2 +-
 .../apache/isis/core/integtestsupport/Util.java|  7 ++--
 .../isis/core/runtime/headless/IsisSystem.java |  2 +-
 .../runtime/headless/IsisSystemBootstrapper.java   |  2 +-
 .../core/runtime/system/context/IsisContext.java   | 10 -
 10 files changed, 82 insertions(+), 36 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/AppManifestAbstract.java 
b/core/applib/src/main/java/org/apache/isis/applib/AppManifestAbstract.java
index 965bb52..f8e5539 100644
--- a/core/applib/src/main/java/org/apache/isis/applib/AppManifestAbstract.java
+++ b/core/applib/src/main/java/org/apache/isis/applib/AppManifestAbstract.java
@@ -54,7 +54,9 @@ public abstract class AppManifestAbstract implements 
AppManifest {
 
 // note uses this.fixtures, so must come afterwards...
 this.configurationProperties = createConfigurationProperties(
-builder.getAllPropertyResources(), 
builder.getAllIndividualConfigProps(),
+builder.getAllPropertyResources(), 
+builder.getAllIndividualConfigProps(),
+builder.getAllFallbackConfigProps(),
 this.fixtureClasses);
 }
 
@@ -96,17 +98,21 @@ public abstract class AppManifestAbstract implements 
AppManifest {
 private Map createConfigurationProperties(
 final List propertyResources,
 final Map individualConfigProps,
+final Map fallbackConfigProps,
 final List> fixtures) {
 final Map props = _Maps.newHashMap();
 for (PropertyResource propertyResource : propertyResources) {
 propertyResource.loadPropsInto(props);
 }
-for (final Map.Entry individualConfigProp : 
individualConfigProps.entrySet()) {
-props.put(individualConfigProp.getKey(), 
individualConfigProp.getValue());
-}
+
+individualConfigProps.forEach(props::put);
+
 if(!fixtures.isEmpty()) {
-props.put("isis.persistor.datanucleus.install-fixtures","true");
+props.put("isis.persistor.datanucleus.install-fixtures", "true");
 }
+
+fallbackConfigProps.forEach((k, v)->props.computeIfAbsent(k, __->v));
+
 overrideConfigurationProperties(props);
 return props;
 }
@@ -249,6 +255,10 @@ public abstract class AppManifestAbstract implements 
AppManifest {
 Map getAllIndividualConfigProps() {
 return getIndividualConfigProps();
 }
+
+Map getAllFallbackConfigProps() {
+return getFallbackConfigProps();
+}
 
 public abstract AppManifest build();
 
diff --git a/core/applib/src/main/java/org/apache/isis/applib/Module.java 
b/core/applib/src/main/java/org/apache/isis/applib/Module.java
index f960439..91b6ec7 100644
--- a/core/applib/src/main/java/org/apache/isis/applib/Module.java
+++ b/core/applib/src/main/java/org/apache/isis/applib/Module.java
@@ -18,6 +18,10 @@
  */
 package org.apache.isis.applib;
 
+import static org.apache.isis.commons.internal.base._With.accept;
+import static org.apache.isis.commons.internal.collections._Lists.newArrayList;
+import static 
org.apache.isis.commons.internal.collections._Maps.newLinkedHashMap;
+
 import java.util.LinkedHashSet;
 import java.util.List;
 import java.util.Map;
@@ -26,7 +30,6 @@ import java.util.Set;
 import org.apache.isis.applib.annotation.DomainService;
 import org.apache.isis.applib.fixturescripts.FixtureScript;
 import org.apache.isis.commons.internal.collections._Lists;
-import org.apache.isis.commons.internal.collections._Maps;
 import org.apache.isis.commons.internal.collections._Sets;
 
 /**
@@ -105,6 +108,12 @@ public interface Module {
  * Optionally each module can define additional configuration properties.
  */
 Map getIndividualConfigProps();
+
+/**
+ * Optionally each mo

[isis] 01/02: ISIS-1959: Update to Wicket 8

2018-06-03 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 9ec61c0c3a9ec47b9488ce8c6ac37ebcc8abb060
Author: Andi Huber 
AuthorDate: Sat Jun 2 14:46:45 2018 +0200

ISIS-1959: Update to Wicket 8

tabs don't work yet

Task-Url: https://issues.apache.org/jira/browse/ISIS-1959
---
 core/pom.xml   |   14 +-
 .../background/BackgroundServiceDefault.java   |4 +
 .../wicket/viewer/IsisWicketApplication.java   | 1647 ++--
 .../ActionResultResponseHandlingStrategy.java  |7 +-
 .../serviceactions/TertiaryActionsPanel.java   |   26 +-
 .../ajaxtable/IsisAjaxFallbackHeadersToolbar.java  |   29 +-
 .../ajaxtable/IsisAjaxFallbackOrderByBorder.java   |   13 +-
 .../ajaxtable/IsisAjaxNavigationToolbar.java   |6 +-
 .../components/tree/IsisToWicketTreeAdapter.java   |5 +-
 .../widgets/buttons/ContainedButtonPanel.java  |2 +-
 .../select2/providers/EmptyChoiceProvider.java |   11 +-
 .../wicket/ui/panels/PromptFormAbstract.java   |   31 +-
 12 files changed, 910 insertions(+), 885 deletions(-)

diff --git a/core/pom.xml b/core/pom.xml
index 880991d..cfcafa9 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -154,12 +154,17 @@
 
 9.4.3.v20170317
 
-7.9.0
-7.8.1
+8.0.0
+8.0.0
+7.0.0
 
+ 
 0.5.4
 0.10.16
-7.0.0
+
 
 4.0.3
 
@@ -1984,7 +1989,8 @@ ${license.additional-notes}
 
 
 
-net.ftlines.wicket-source
+   net.ftlines.wicket-source
+
 wicket-source
 ${wicket-source.version}
 
diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
index d3010fe..3f11b89 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
@@ -21,6 +21,7 @@ import java.lang.reflect.Method;
 import java.util.Collections;
 import java.util.List;
 import java.util.Map;
+import java.util.Objects;
 
 import javax.annotation.PostConstruct;
 import javax.annotation.PreDestroy;
@@ -193,6 +194,9 @@ public class BackgroundServiceDefault implements 
BackgroundService2 {
 final Command command = commandContext.getCommand();
 
 final BackgroundCommandService2 bcs2 = 
(BackgroundCommandService2) backgroundCommandService;
+Objects.requireNonNull(bcs2, 
+   ()->String.format("You need to provide a 
domain-service implementing '%s'!", 
+   
BackgroundCommandService2.class.getName()));
 
 final List targetList = 
Collections.singletonList(domainObjectAdapter);
 final CommandDto dto =
diff --git 
a/core/viewer-wicket-impl/src/main/java/org/apache/isis/viewer/wicket/viewer/IsisWicketApplication.java
 
b/core/viewer-wicket-impl/src/main/java/org/apache/isis/viewer/wicket/viewer/IsisWicketApplication.java
index b60ee44..94af982 100644
--- 
a/core/viewer-wicket-impl/src/main/java/org/apache/isis/viewer/wicket/viewer/IsisWicketApplication.java
+++ 
b/core/viewer-wicket-impl/src/main/java/org/apache/isis/viewer/wicket/viewer/IsisWicketApplication.java
@@ -30,6 +30,7 @@ import java.util.UUID;
 import java.util.concurrent.Callable;
 import java.util.concurrent.Executors;
 import java.util.concurrent.Future;
+import java.util.function.Function;
 
 import org.apache.isis.commons.internal.collections._Lists;
 import org.apache.isis.commons.internal.context._Context;
@@ -85,6 +86,7 @@ import org.apache.wicket.Page;
 import org.apache.wicket.RuntimeConfigurationType;
 import org.apache.wicket.SharedResources;
 import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.AjaxRequestTarget.IListener;
 import org.apache.wicket.authentication.IAuthenticationStrategy;
 import org.apache.wicket.authentication.strategy.DefaultAuthenticationStrategy;
 import org.apache.wicket.authroles.authentication.AuthenticatedWebApplication;
@@ -98,9 +100,9 @@ import 
org.apache.wicket.devutils.debugbar.VersionDebugContributor;
 import org.apache.wicket.devutils.diskstore.DebugDiskDataStore;
 import org.apache.wicket.guice.GuiceComponentInjector;
 import org.apache.wicket.markup.head.IHeaderResponse;
+import org.apache.wicket.markup.head.ResourceAggregator;
 import 
org.apache.wicket.markup.head.filter.JavaScriptFilteredIntoFooterHeaderResponse;
 import org.apache.wicket.markup.html.IHeaderContributor;
-import org.apache.wicket.markup.html.IHeaderResponseDecor

[isis] 02/02: ISIS-1959: removing some compiler warnings

2018-06-03 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 6ba074df83215d8f77dae1736ba6623de1bfd875
Author: Andi Huber 
AuthorDate: Sun Jun 3 10:51:54 2018 +0200

ISIS-1959: removing some compiler warnings

Task-Url: https://issues.apache.org/jira/browse/ISIS-1959
---
 core/pom.xml   | 12 +-
 .../components/layout/bs3/tabs/TabGroupPanel.java  | 26 --
 .../ui/components/layout/bs3/tabs/TabPanel.java|  3 ++-
 3 files changed, 17 insertions(+), 24 deletions(-)

diff --git a/core/pom.xml b/core/pom.xml
index cfcafa9..153c5a9 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -156,19 +156,17 @@
 
 8.0.0
 8.0.0
+2.0.1
 7.0.0
 
  
 0.5.4
-0.10.16
 
+4.0.5
 
-4.0.3
-
-1.11.4
+1.12.1
 
 4.1.0
 2.15
@@ -1989,8 +1987,10 @@ ${license.additional-notes}
 
 
 
+
net.ftlines.wicket-source
-
+
+
 wicket-source
 ${wicket-source.version}
 
diff --git 
a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/layout/bs3/tabs/TabGroupPanel.java
 
b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/layout/bs3/tabs/TabGroupPanel.java
index 37c0b52..5efc8ef 100644
--- 
a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/layout/bs3/tabs/TabGroupPanel.java
+++ 
b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/layout/bs3/tabs/TabGroupPanel.java
@@ -18,6 +18,7 @@
  */
 package org.apache.isis.viewer.wicket.ui.components.layout.bs3.tabs;
 
+import java.util.ArrayList;
 import java.util.List;
 import java.util.stream.Collectors;
 
@@ -35,23 +36,20 @@ import 
org.apache.wicket.extensions.markup.html.tabs.TabbedPanel;
 import org.apache.wicket.markup.html.panel.Panel;
 import org.apache.wicket.model.Model;
 
-import com.google.common.base.Predicate;
-import com.google.common.collect.FluentIterable;
-import com.google.common.collect.Lists;
-
 import 
de.agilecoders.wicket.core.markup.html.bootstrap.tabs.AjaxBootstrapTabbedPanel;
 
 // hmmm... not sure how to make this implement HasDynamicallyVisibleContent
-public class TabGroupPanel extends AjaxBootstrapTabbedPanel  {
+public class TabGroupPanel extends AjaxBootstrapTabbedPanel  {
+   private static final long serialVersionUID = 1L;
 
-public static final String SESSION_ATTR_SELECTED_TAB = "selectedTab";
+   public static final String SESSION_ATTR_SELECTED_TAB = "selectedTab";
 
 // the view metadata
 private final ComponentHintKey selectedTabHintKey;
 private final EntityModel entityModel;
 
 private static List tabsFor(final EntityModel entityModel, final 
BS3TabGroup bs3TabGroup) {
-final List tabs = Lists.newArrayList();
+final List tabs = new ArrayList<>();
 
 final List tablist = _NullSafe.stream(bs3TabGroup.getTabs())
.filter(BS3Tab.Predicates.notEmpty())
@@ -98,13 +96,13 @@ public class TabGroupPanel extends AjaxBootstrapTabbedPanel 
 {
 }
 
 @Override
-public TabbedPanel setSelectedTab(final int index) {
+public TabbedPanel setSelectedTab(final int index) {
 
selectedTabHintKey.set(entityModel.getObjectAdapterMemento().asHintingBookmark(),
 ""+index);
 return super.setSelectedTab(index);
 }
 
 private void setSelectedTabFromSessionIfAny(
-final AjaxBootstrapTabbedPanel ajaxBootstrapTabbedPanel) {
+final AjaxBootstrapTabbedPanel ajaxBootstrapTabbedPanel) {
 final String selectedTabStr = 
selectedTabHintKey.get(entityModel.getObjectAdapterMemento().asHintingBookmark());
 final Integer tabIndex = parse(selectedTabStr);
 if (tabIndex != null) {
@@ -126,15 +124,9 @@ public class TabGroupPanel extends 
AjaxBootstrapTabbedPanel  {
 
 @Override
 public boolean isVisible() {
-return FluentIterable.from(getTabs()).anyMatch(new 
Predicate() {
-@Override
-public boolean apply(final AbstractTab tab) {
-return tab.isVisible();
-}
-});
+   return _NullSafe.stream(getTabs())
+   .anyMatch(ITab::isVisible);
 }
 
 
-
-
 }
diff --git 
a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/layout/bs3/tabs/TabPanel.java
 
b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/layout/bs3/tabs/TabPanel.java
index b78a42e..9c10f87 100644
--- 
a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/layout/bs3/tabs/TabPanel.java
+++ 
b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/layout/bs3/tabs/Ta

[isis] branch master updated (e0aa6b6 -> 6ba074d)

2018-06-03 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git.


from e0aa6b6  ISIS-1958: improve code readability
 new 9ec61c0  ISIS-1959: Update to Wicket 8
 new 6ba074d  ISIS-1959: removing some compiler warnings

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 core/pom.xml   |   22 +-
 .../background/BackgroundServiceDefault.java   |4 +
 .../wicket/viewer/IsisWicketApplication.java   | 1647 ++--
 .../ActionResultResponseHandlingStrategy.java  |7 +-
 .../serviceactions/TertiaryActionsPanel.java   |   26 +-
 .../ajaxtable/IsisAjaxFallbackHeadersToolbar.java  |   29 +-
 .../ajaxtable/IsisAjaxFallbackOrderByBorder.java   |   13 +-
 .../ajaxtable/IsisAjaxNavigationToolbar.java   |6 +-
 .../components/layout/bs3/tabs/TabGroupPanel.java  |   26 +-
 .../ui/components/layout/bs3/tabs/TabPanel.java|3 +-
 .../components/tree/IsisToWicketTreeAdapter.java   |5 +-
 .../widgets/buttons/ContainedButtonPanel.java  |2 +-
 .../select2/providers/EmptyChoiceProvider.java |   11 +-
 .../wicket/ui/panels/PromptFormAbstract.java   |   31 +-
 14 files changed, 925 insertions(+), 907 deletions(-)

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1960: Introduces a ForkingInvocationHandler that executes actions in the background

2018-06-03 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 5bf49c6  ISIS-1960: Introduces a ForkingInvocationHandler that 
executes actions in the background
5bf49c6 is described below

commit 5bf49c608b8ddae9d3d5e38559debf070b3637cd
Author: Andi Huber 
AuthorDate: Sun Jun 3 18:24:12 2018 +0200

ISIS-1960: Introduces a ForkingInvocationHandler that executes actions
in the background

Task-Url: https://issues.apache.org/jira/browse/ISIS-1960
---
 .../background/BackgroundServiceDefault.java   | 145 +++--
 .../background/CommandInvocationHandler.java   | 172 +
 .../background/ForkingInvocationHandler.java   |  71 +
 .../PersistenceSessionServiceInternalDefault.java  |  13 +-
 .../runtime/system/session/IsisSessionFactory.java |  16 +-
 5 files changed, 287 insertions(+), 130 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
index 3f11b89..14cf750 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
@@ -1,4 +1,4 @@
-/**
+/*
  *  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.
@@ -17,11 +17,9 @@
 package org.apache.isis.core.runtime.services.background;
 
 import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Method;
-import java.util.Collections;
-import java.util.List;
 import java.util.Map;
-import java.util.Objects;
+import java.util.concurrent.ExecutorService;
+import java.util.concurrent.Executors;
 
 import javax.annotation.PostConstruct;
 import javax.annotation.PreDestroy;
@@ -32,27 +30,18 @@ import org.apache.isis.applib.annotation.Programmatic;
 import org.apache.isis.applib.services.background.BackgroundCommandService;
 import org.apache.isis.applib.services.background.BackgroundCommandService2;
 import org.apache.isis.applib.services.background.BackgroundService2;
-import org.apache.isis.applib.services.command.Command;
 import org.apache.isis.applib.services.command.CommandContext;
 import org.apache.isis.applib.services.factory.FactoryService;
 import org.apache.isis.commons.internal._Constants;
 import org.apache.isis.commons.internal.base._Casts;
 import org.apache.isis.core.commons.lang.ArrayExtensions;
-import org.apache.isis.core.metamodel.adapter.ObjectAdapter;
 import org.apache.isis.core.metamodel.adapter.mgr.AdapterManager;
-import 
org.apache.isis.core.metamodel.facets.actions.action.invocation.CommandUtil;
 import 
org.apache.isis.core.metamodel.services.command.CommandDtoServiceInternal;
 import org.apache.isis.core.metamodel.spec.ObjectSpecification;
-import org.apache.isis.core.metamodel.spec.feature.Contributed;
-import org.apache.isis.core.metamodel.spec.feature.ObjectAction;
-import org.apache.isis.core.metamodel.spec.feature.ObjectMember;
 import org.apache.isis.core.metamodel.specloader.SpecificationLoader;
 import 
org.apache.isis.core.metamodel.specloader.classsubstitutor.ProxyEnhanced;
-import org.apache.isis.core.metamodel.specloader.specimpl.ObjectActionMixedIn;
-import 
org.apache.isis.core.metamodel.specloader.specimpl.dflt.ObjectSpecificationDefault;
 import org.apache.isis.core.plugins.codegen.ProxyFactory;
 import org.apache.isis.core.runtime.system.session.IsisSessionFactory;
-import org.apache.isis.schema.cmd.v1.CommandDto;
 
 /**
  * Depends on an implementation of {@link 
org.apache.isis.applib.services.background.BackgroundCommandService} to
@@ -64,7 +53,11 @@ import org.apache.isis.schema.cmd.v1.CommandDto;
 )
 public class BackgroundServiceDefault implements BackgroundService2 {
 
-
+   private final int threadCount = 
Runtime.getRuntime().availableProcessors();
+   
+   private final ExecutorService backgroundExecutorService = 
+   Executors.newFixedThreadPool(threadCount);
+   
 @Programmatic
 @PostConstruct
 public void init(Map props) {
@@ -73,31 +66,13 @@ public class BackgroundServiceDefault implements 
BackgroundService2 {
 @Programmatic
 @PreDestroy
 public void shutdown() {
-
+   backgroundExecutorService.shutdownNow();
 }
-
-// //
-
-
-private ObjectSpecificationDefault getJavaSpecificationOfOwningClass(final 
Method method) {
-return getJavaSpecification(method.getDeclaringClass());
-}
-
-private ObjectSpecificationDefault

[isis] branch master updated: ISIS-1742: new module 'transition-1-2' to ease the migration from Isis 1.16.x to 2.0.0

2018-06-03 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 02bfd3a  ISIS-1742: new module 'transition-1-2' to ease the migration 
from Isis 1.16.x to 2.0.0
02bfd3a is described below

commit 02bfd3af7c725acfdf001d8e7bc2ad20a7b31c0f
Author: Andi Huber 
AuthorDate: Sun Jun 3 14:10:24 2018 +0200

ISIS-1742: new module 'transition-1-2' to ease the migration from Isis
1.16.x to 2.0.0

Task-Url: https://issues.apache.org/jira/browse/ISIS-1742
---
 core/legacy/transition-1-2/.gitignore  |   1 +
 core/legacy/transition-1-2/pom.xml | 109 
 .../apache/isis/applib/DomainObjectContainer.java  | 688 +
 .../java/org/apache/isis/applib/filter/Filter.java |  51 ++
 .../org/apache/isis/applib/filter/Filters.java | 108 
 .../services/eventbus/ActionDomainEvent.java   | 223 +++
 .../services/eventbus/CollectionDomainEvent.java   | 151 +
 .../services/eventbus/PropertyDomainEvent.java | 125 
 .../spec/feature/ObjectAssociationFilters.java | 256 
 9 files changed, 1712 insertions(+)

diff --git a/core/legacy/transition-1-2/.gitignore 
b/core/legacy/transition-1-2/.gitignore
new file mode 100644
index 000..a48e45b
--- /dev/null
+++ b/core/legacy/transition-1-2/.gitignore
@@ -0,0 +1 @@
+/target-ide
diff --git a/core/legacy/transition-1-2/pom.xml 
b/core/legacy/transition-1-2/pom.xml
new file mode 100644
index 000..aa673aa
--- /dev/null
+++ b/core/legacy/transition-1-2/pom.xml
@@ -0,0 +1,109 @@
+
+
+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;>
+   4.0.0
+
+   
+   org.apache.isis.core
+   isis
+   ${revision}
+   ../../pom.xml
+   
+
+   isis-core-transition-1-2
+
+ Apache Isis Transition (1.16.x to 2.0.0)
+
+To ease migration from Apache Isis versions 1.16.x to 2.0.0.
+
+
+   
+   
org.apache.isis.transition12
+   
org/apache/isis/transition12
+   
+
+   
+   
+   
+   false
+   src/main/resources
+   
+   
+   false
+   src/main/java
+   
+   **
+   
+   
+   **/*.java
+   
+   
+   
+   
+
+   
+   
+   
+
+javax.jdo
+jdo-api
+${jdo-api.version}
+
+provided
+
+   
+   
+   
+   
+   com.google.guava
+   guava
+   
+
+   
+
+   
+   org.apache.isis.core
+   isis-core-applib
+   compile
+   
+   
+   
+   org.apache.isis.core
+   isis-core-runtime
+   compile
+   
+   
+   
+   
+   
+   
+org.apache.isis.core
+isis-core-unittestsupport
+test
+
+   
+   
+   org.reflections
+   reflections
+   
+   
+   com.google.guava
+   guava
+   
+
+
+
+   
+
+
+
\ No newline at end of file
diff --git 
a/core/legacy/transition-1-2/src/main/java/org/apache/isis/applib/DomainObjectContainer.java
 
b/core/legacy/transition-1-2/src/main/java/org/apache/isis/applib/DomainObjectContainer.java
new file mode 100644
index 000..d4bf554
--- /dev/null
+++ 
b/core/legacy/transition-1-2/src/main/java/org/apache/isis/applib/DomainObjectContainer.java
@@ -0,0 +1,688 @@
+/*
+ *  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 

[isis] branch master updated: ISIS-1959: helloworld/simpleapp: update wicket log-suppression

2018-06-03 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new b62069d  ISIS-1959: helloworld/simpleapp: update wicket log-suppression
b62069d is described below

commit b62069da018fe488ff11a78592aa739e91768481
Author: Andi Huber 
AuthorDate: Sun Jun 3 14:58:20 2018 +0200

ISIS-1959: helloworld/simpleapp: update wicket log-suppression

Task-Url: https://issues.apache.org/jira/browse/ISIS-1959
---
 .../application/helloworld/src/main/webapp/WEB-INF/logging.properties | 4 ++--
 .../simpleapp/webapp/src/main/webapp/WEB-INF/logging.properties   | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git 
a/example/application/helloworld/src/main/webapp/WEB-INF/logging.properties 
b/example/application/helloworld/src/main/webapp/WEB-INF/logging.properties
index ded0152..1eaecf7 100644
--- a/example/application/helloworld/src/main/webapp/WEB-INF/logging.properties
+++ b/example/application/helloworld/src/main/webapp/WEB-INF/logging.properties
@@ -231,5 +231,5 @@ log4j.additivity.dom.simple.SimpleObject=false
 
 
 # ERROR to suppress the WARNings we get as of 1.15.0
-log4j.logger.org.apache.wicket.page.XmlPartialPageUpdate=ERROR,Console
-log4j.additivity.org.apache.wicket.page.XmlPartialPageUpdate=false
+log4j.logger.org.apache.wicket.page.PartialPageUpdate=ERROR,Console
+log4j.additivity.org.apache.wicket.page.PartialPageUpdate=false
diff --git 
a/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/logging.properties
 
b/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/logging.properties
index ded0152..1eaecf7 100644
--- 
a/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/logging.properties
+++ 
b/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/logging.properties
@@ -231,5 +231,5 @@ log4j.additivity.dom.simple.SimpleObject=false
 
 
 # ERROR to suppress the WARNings we get as of 1.15.0
-log4j.logger.org.apache.wicket.page.XmlPartialPageUpdate=ERROR,Console
-log4j.additivity.org.apache.wicket.page.XmlPartialPageUpdate=false
+log4j.logger.org.apache.wicket.page.PartialPageUpdate=ERROR,Console
+log4j.additivity.org.apache.wicket.page.PartialPageUpdate=false

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] 01/02: ISIS-1960: Adding background error handling

2018-06-04 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 272a6198a28d643a8f5ef8e0519ee6a154caecbe
Author: Andi Huber 
AuthorDate: Mon Jun 4 08:36:54 2018 +0200

ISIS-1960: Adding background error handling

also init thread-pool only if required

Task-Url: https://issues.apache.org/jira/browse/ISIS-1960
---
 .../background/BackgroundServiceDefault.java   | 222 -
 .../background/ForkingInvocationHandler.java   |  15 +-
 2 files changed, 138 insertions(+), 99 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
index 14cf750..75d20b3 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/BackgroundServiceDefault.java
@@ -16,6 +16,8 @@
  */
 package org.apache.isis.core.runtime.services.background;
 
+import static org.apache.isis.commons.internal.base._Casts.uncheckedCast;
+
 import java.lang.reflect.InvocationHandler;
 import java.util.Map;
 import java.util.concurrent.ExecutorService;
@@ -33,7 +35,6 @@ import 
org.apache.isis.applib.services.background.BackgroundService2;
 import org.apache.isis.applib.services.command.CommandContext;
 import org.apache.isis.applib.services.factory.FactoryService;
 import org.apache.isis.commons.internal._Constants;
-import org.apache.isis.commons.internal.base._Casts;
 import org.apache.isis.core.commons.lang.ArrayExtensions;
 import org.apache.isis.core.metamodel.adapter.mgr.AdapterManager;
 import 
org.apache.isis.core.metamodel.services.command.CommandDtoServiceInternal;
@@ -42,92 +43,117 @@ import 
org.apache.isis.core.metamodel.specloader.SpecificationLoader;
 import 
org.apache.isis.core.metamodel.specloader.classsubstitutor.ProxyEnhanced;
 import org.apache.isis.core.plugins.codegen.ProxyFactory;
 import org.apache.isis.core.runtime.system.session.IsisSessionFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 /**
- * Depends on an implementation of {@link 
org.apache.isis.applib.services.background.BackgroundCommandService} to
+ * For command-reification depends on an implementation of 
+ * {@link org.apache.isis.applib.services.background.BackgroundCommandService} 
to
  * be configured.
  */
 @DomainService(
-nature = NatureOfService.DOMAIN,
-menuOrder = "" + Integer.MAX_VALUE
-)
+   nature = NatureOfService.DOMAIN,
+   menuOrder = "" + Integer.MAX_VALUE
+   )
 public class BackgroundServiceDefault implements BackgroundService2 {
-
-   private final int threadCount = 
Runtime.getRuntime().availableProcessors();

-   private final ExecutorService backgroundExecutorService = 
-   Executors.newFixedThreadPool(threadCount);
-   
-@Programmatic
-@PostConstruct
-public void init(Map props) {
-}
-
-@Programmatic
-@PreDestroy
-public void shutdown() {
-   backgroundExecutorService.shutdownNow();
-}
-
-ObjectSpecification getSpecification(final Class type) {
-return specificationLoader.loadSpecification(type);
-}
-
-// //
-
-@Programmatic
-@Override
-public  T execute(final T domainObject) {
-final Class cls = _Casts.uncheckedCast(domainObject.getClass());
-final InvocationHandler methodHandler = newMethodHandler(domainObject, 
null);
-return newProxy(cls, null, methodHandler);
-}
-
-@Override
-public  T executeMixin(Class mixinClass, Object mixedIn) {
-final T mixin = factoryService.mixin(mixinClass, mixedIn);
-final InvocationHandler methodHandler = newMethodHandler(mixin, 
mixedIn);
-return newProxy(mixinClass, mixedIn, methodHandler);
-}
-
-private  T newProxy(
-final Class cls,
-final Object mixedInIfAny,
-final InvocationHandler methodHandler) {
-
-   final Class[] interfaces = ArrayExtensions.combine(
-   cls.getInterfaces(), 
-   new Class[] { ProxyEnhanced.class }); 
-   
-   final boolean initialize = mixedInIfAny!=null;
-   
-   
-final Class[] constructorArgTypes = initialize ? new Class[] 
{mixedInIfAny.getClass()} : _Constants.emptyClasses;
-final Object[] constructorArgs = initialize ? new Object[] 
{mixedInIfAny} : _Constants.emptyObjects;
-
-final ProxyFactory proxyFactory = ProxyFactory.builder(cls)
-   .interfaces(interfaces)
-   .constructorArgTypes(constructorArgTypes)
- 

[isis] branch master updated (5bf49c6 -> 7b0fafa)

2018-06-04 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git.


from 5bf49c6  ISIS-1960: Introduces a ForkingInvocationHandler that 
executes actions in the background
 new 272a619  ISIS-1960: Adding background error handling
 new 7b0fafa  ISIS-1961: intercepting by 'magic text' handling tomcat-9 and 
payara-4

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../core/webapp/content/ResourceCachingFilter.java |  29 ++-
 .../background/BackgroundServiceDefault.java   | 222 -
 .../background/ForkingInvocationHandler.java   |  15 +-
 3 files changed, 166 insertions(+), 100 deletions(-)

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] 02/02: ISIS-1961: intercepting by 'magic text' handling tomcat-9 and payara-4

2018-06-04 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 7b0fafa64b4208e60e76374d10d872794a198d93
Author: Andi Huber 
AuthorDate: Mon Jun 4 08:45:07 2018 +0200

ISIS-1961: intercepting by 'magic text' handling tomcat-9 and payara-4

Task-Url: https://issues.apache.org/jira/browse/ISIS-1961
---
 .../core/webapp/content/ResourceCachingFilter.java | 29 +-
 1 file changed, 28 insertions(+), 1 deletion(-)

diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/webapp/content/ResourceCachingFilter.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/webapp/content/ResourceCachingFilter.java
index 1d0ed24..0d9c81d 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/webapp/content/ResourceCachingFilter.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/webapp/content/ResourceCachingFilter.java
@@ -226,7 +226,19 @@ public class ResourceCachingFilter implements Filter {
 httpResponse.addHeader(EXPIRES_HEADER, httpDateFormat.format(new 
Date(now + (this.cacheTime.longValue() * MILLISECONDS_IN_SECOND;
 }
 httpRequest.setAttribute(REQUEST_ATTRIBUTE, true);
-chain.doFilter(servletRequest, servletResponse);
+
+// try to suppress java.io.IOException of kind 'client connection 
abort'
+// 1) the TCP protocol (by design) does not provide a means to check, 
whether a 
+//connection has been closed by the client
+// 2) the exception thrown and the exception message text are specific 
to the 
+//servlet-engine implementation, so we can only guess here
+try {
+   chain.doFilter(servletRequest, servletResponse);
+} catch (IOException e) {
+   if(!isConnectionAbortException(e)) {
+   throw e;
+   }
+   }
 }
 
 /**
@@ -237,5 +249,20 @@ public class ResourceCachingFilter implements Filter {
 @Override
 public void destroy() {
 }
+
+// -- HELPER
+
+private boolean isConnectionAbortException(IOException e) {
+   // tomcat 9
+   if(e.getMessage().contains("An established connection was aborted by 
the software in your host machine")) {
+   return true;
+   }
+   // payara 4
+   if(e.getMessage().contains("Connection is closed")) {
+   return true;
+   }
+   
+   return false;
+}
 
 }

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1950: byte-buddy requires any loaded proxy class to have a unique name

2018-06-05 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 71c9f86  ISIS-1950: byte-buddy requires any loaded proxy class to have 
a unique name
71c9f86 is described below

commit 71c9f86a5b260691059739264e4efd3fe336016b
Author: Andi Huber 
AuthorDate: Tue Jun 5 21:39:15 2018 +0200

ISIS-1950: byte-buddy requires any loaded proxy class to have a unique
name

fixes integration tests failing with simple-app

Task-Url: https://issues.apache.org/jira/browse/ISIS-1950
---
 .../codegen/ProxyFactoryPluginUsingByteBuddy.java | 19 ---
 1 file changed, 12 insertions(+), 7 deletions(-)

diff --git 
a/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
 
b/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
index 9bd3035..3521fbe 100644
--- 
a/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
+++ 
b/core/plugins/codegen-bytebuddy/src/main/java/org/apache/isis/core/plugins/codegen/ProxyFactoryPluginUsingByteBuddy.java
@@ -21,6 +21,16 @@ import net.bytebuddy.matcher.ElementMatchers;
 
 public class ProxyFactoryPluginUsingByteBuddy implements ProxyFactoryPlugin {
 
+   private static  ImplementationDefinition nextProxyDef(
+   Class base, 
+   Class[] interfaces) {
+   return new ByteBuddy()
+   .with(new NamingStrategy.SuffixingRandom("bb"))
+   .subclass(base)
+   .implement(interfaces)
+   .method(ElementMatchers.any());
+   }
+   
@Override
public  ProxyFactory factory(
Class base, 
@@ -29,14 +39,9 @@ public class ProxyFactoryPluginUsingByteBuddy implements 
ProxyFactoryPlugin {

final Objenesis objenesis = new ObjenesisStd();
 
-   final ImplementationDefinition proxyDef = new ByteBuddy()
-   .with(new NamingStrategy.SuffixingRandom("bb"))
-   .subclass(base)
-   .implement(interfaces)
-   .method(ElementMatchers.any());
-   
final Function> 
proxyClassFactory = handler->
-   
proxyDef.intercept(InvocationHandlerAdapter.of(handler))
+   nextProxyDef(base, interfaces)
+   .intercept(InvocationHandlerAdapter.of(handler))
.make()
.load(_Context.getDefaultClassLoader())
.getLoaded();

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


[isis] branch master updated: ISIS-1955: Introduces EmailTicket

2018-05-28 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 866b641  ISIS-1955: Introduces EmailTicket
866b641 is described below

commit 866b641635dbe8b1e68fa09fa77d5bcc7e19aac4
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Mon May 28 14:22:43 2018 +0200

ISIS-1955: Introduces EmailTicket

a Ticket variant, that allows for sending the error stacktrace via email

Task-Url: https://issues.apache.org/jira/browse/ISIS-1955
---
 .../core/runtime/services/error/EmailTicket.java   | 141 +
 1 file changed, 141 insertions(+)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/error/EmailTicket.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/error/EmailTicket.java
new file mode 100644
index 000..bf0abd3
--- /dev/null
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/error/EmailTicket.java
@@ -0,0 +1,141 @@
+/*
+ *  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.core.runtime.services.error;
+
+import static org.apache.isis.commons.internal.base._NullSafe.stream;
+
+import java.io.Serializable;
+import java.util.List;
+import java.util.stream.Collectors;
+
+import org.apache.isis.applib.services.error.ErrorDetails;
+import org.apache.isis.applib.services.error.ErrorReportingService;
+
+/**
+ * Response from the {@link ErrorReportingService}, containing information to 
show to the end-user.
+ *
+ * 
+ * Implementation notes:
+ * 
+ * a class has been used here so that additional fields might be 
added in the future.
+ * the class is {@link Serializable} so that it can be stored 
by the Wicket viewer as a Wicket model.
+ * 
+ * 
+ */
+public class EmailTicket extends SimpleTicket {
+
+   // -- MAILTO VALUE TYPE
+   
+   public static class MailTo implements Serializable {
+   
+   private static final long serialVersionUID = 
-817872853109724987L;
+
+   public static class MailToBuilder {
+   private final MailTo mailTo = new MailTo();
+   public MailTo build() {
+   return mailTo;
+   }
+   public MailToBuilder linkName(String linkName) {
+   mailTo.linkName = linkName;
+   return this;
+   }
+   public MailToBuilder receiver(String receiver) {
+   mailTo.receiver = receiver;
+   return this;
+   }
+   public MailToBuilder subject(String subject) {
+   mailTo.subject = subject;
+   return this;
+   }
+   public MailToBuilder body(String body) {
+   mailTo.body = body;
+   return this;
+   }
+   }
+   
+   public static MailToBuilder builder() {
+   return new MailToBuilder();
+   }
+   
+   private String linkName = "Email";
+   private String receiver = "no-one@nowhere";
+   private String subject = "[Module-Name] Unexpected Error 
(#ref)";
+   private String body = "empty body";
+   
+   public String toHtmlLink() {
+   return String.format("mailto:%s?subject=%s=%s\;>%s",
+   receiver,
+   htmlEscape(subject),
+   htmlEscape(body),
+   linkName
+   );
+   }
+   
+   // -- STACKTRACE FORMATTING
+  

[isis] branch master updated: ISIS-1958: Integration Tests: allows to override default config

2018-05-31 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new ed3a07a  ISIS-1958: Integration Tests: allows to override default 
config
ed3a07a is described below

commit ed3a07a2398dd87a1caa94d46d7527674b09547a
Author: Andi Huber 
AuthorDate: Thu May 31 16:14:36 2018 +0200

ISIS-1958: Integration Tests: allows to override default config

Task-Url: https://issues.apache.org/jira/browse/ISIS-1958
---
 .../java/org/apache/isis/applib/AppManifest.java   |   6 +-
 .../isis/applib/ModuleOrBuilderAbstract.java   |   4 +-
 .../integtestsupport/IntegrationTestAbstract3.java |   6 +-
 .../integtestsupport/IntegrationTestJupiter.java   |   6 +-
 .../apache/isis/core/integtestsupport/Util.java| 183 +
 .../runtime/headless/IsisSystemBootstrapper.java   |  16 +-
 .../core/runtime/system/context/IsisContext.java   |  17 ++
 7 files changed, 147 insertions(+), 91 deletions(-)

diff --git a/core/applib/src/main/java/org/apache/isis/applib/AppManifest.java 
b/core/applib/src/main/java/org/apache/isis/applib/AppManifest.java
index e392790..696545c 100644
--- a/core/applib/src/main/java/org/apache/isis/applib/AppManifest.java
+++ b/core/applib/src/main/java/org/apache/isis/applib/AppManifest.java
@@ -24,6 +24,7 @@ import java.util.Collections;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
+import java.util.UUID;
 
 import javax.jdo.annotations.PersistenceCapable;
 
@@ -238,7 +239,7 @@ public interface AppManifest {
 
 public static Map 
withJavaxJdoRunInMemoryProperties(final Map map) {
 
-map.put(ISIS_PERSISTOR_DATANUCLEUS_IMPL + 
"javax.jdo.option.ConnectionURL", "jdbc:hsqldb:mem:test");
+map.put(ISIS_PERSISTOR_DATANUCLEUS_IMPL + 
"javax.jdo.option.ConnectionURL", "jdbc:hsqldb:mem:test-" + 
UUID.randomUUID().toString());
 map.put(ISIS_PERSISTOR_DATANUCLEUS_IMPL + 
"javax.jdo.option.ConnectionDriverName", "org.hsqldb.jdbcDriver");
 map.put(ISIS_PERSISTOR_DATANUCLEUS_IMPL + 
"javax.jdo.option.ConnectionUserName", "sa");
 map.put(ISIS_PERSISTOR_DATANUCLEUS_IMPL + 
"javax.jdo.option.ConnectionPassword", "");
@@ -271,8 +272,7 @@ public interface AppManifest {
 
 return map;
 }
-
-
+
 }
 
 }
diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/ModuleOrBuilderAbstract.java 
b/core/applib/src/main/java/org/apache/isis/applib/ModuleOrBuilderAbstract.java
index 527951e..10e76e6 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/ModuleOrBuilderAbstract.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/ModuleOrBuilderAbstract.java
@@ -26,6 +26,7 @@ import java.util.Set;
 
 import javax.xml.bind.annotation.XmlTransient;
 
+import org.apache.isis.commons.internal.base._Casts;
 import org.apache.isis.commons.internal.collections._Lists;
 import org.apache.isis.commons.internal.collections._Maps;
 import org.apache.isis.commons.internal.collections._Sets;
@@ -162,9 +163,8 @@ abstract class ModuleOrBuilderAbstract> {
 
 // -- HELPER
 
-@SuppressWarnings("unchecked") //[ahuber] it's safe to assume this object 
is an instance of B
protected B self() {
-   return (B) this;
+   return _Casts.uncheckedCast(this);
 }
 
 }
diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
index 2394f74..05a2614 100644
--- 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
+++ 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestAbstract3.java
@@ -81,7 +81,11 @@ public abstract class IntegrationTestAbstract3 extends 
HeadlessWithBootstrapping
 protected IntegrationTestAbstract3(
 final LogConfig logConfig,
 final Module module) {
-super(logConfig, Util.addHeadlessTransactionSupport(module));
+   super(logConfig, 
+   Util.moduleBuilder(module)
+   .withHeadlessTransactionSupport()
+   .withIntegrationTestConfigIfAbsent()
+   .build() );
 }
 
@Override
diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestJupiter.java
 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestJupiter.java
index 342871c..b966ab8 100644
--- 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IntegrationTestJupiter.java
+++ 

[isis] branch master updated: ISIS-1957: fixes ServiceInjector fails to handle Generic Types

2018-05-30 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new dabee19  ISIS-1957: fixes ServiceInjector fails to handle Generic Types
dabee19 is described below

commit dabee1909c58869ca247d318133c564e09d0f7f0
Author: Andi Huber 
AuthorDate: Wed May 30 16:17:46 2018 +0200

ISIS-1957: fixes ServiceInjector fails to handle Generic Types

... in target fields of type List

Task-Url: https://issues.apache.org/jira/browse/ISIS-1957
---
 .../applib/services/grid/GridSystemService.java|  6 ++--
 .../commons/internal/collections/_Collections.java | 12 +--
 .../core/metamodel/services/ServicesInjector.java  |  2 +-
 .../services/grid/GridServiceDefault.java  | 38 ++
 .../grid/bootstrap3/GridSystemServiceBS3.java  |  2 +-
 .../core/metamodel/services/grid/BS3GridTest.java  |  2 +-
 6 files changed, 34 insertions(+), 28 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/grid/GridSystemService.java
 
b/core/applib/src/main/java/org/apache/isis/applib/services/grid/GridSystemService.java
index 46e8209..553264d 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/grid/GridSystemService.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/services/grid/GridSystemService.java
@@ -22,13 +22,13 @@ import org.apache.isis.applib.layout.grid.Grid;
 /**
  * Provides an implementation of {@link Grid}.
  */
-public interface GridSystemService {
+public interface GridSystemService {
 
 /**
  * Which grid (implementation) is defined by this service.
  */
 @Programmatic
-Class gridImplementation();
+Class gridImplementation();
 
 @Programmatic
 String tns();
@@ -37,7 +37,7 @@ public interface GridSystemService domainClass);
+G defaultGrid(Class domainClass);
 
 /**
  * Validate the grid, derive any missing object members, and overwrite any 
facets in the metamodel based on the
diff --git 
a/core/commons/src/main/java/org/apache/isis/commons/internal/collections/_Collections.java
 
b/core/commons/src/main/java/org/apache/isis/commons/internal/collections/_Collections.java
index 38d0725..364d635 100644
--- 
a/core/commons/src/main/java/org/apache/isis/commons/internal/collections/_Collections.java
+++ 
b/core/commons/src/main/java/org/apache/isis/commons/internal/collections/_Collections.java
@@ -277,11 +277,20 @@ public final class _Collections {
 final ParameterizedType parameterizedType = (ParameterizedType) 
genericType;
 final Type[] actualTypeArguments = 
parameterizedType.getActualTypeArguments();
 if(actualTypeArguments.length == 1) {
+   // handle e.g. List
 final Type actualTypeArgument = actualTypeArguments[0];
 if(actualTypeArgument instanceof Class) {
 final Class actualType = (Class) actualTypeArgument;
 return actualType;
 }
+// also handle e.g. List>
+if(actualTypeArgument instanceof ParameterizedType) {
+   final Type innerParameterizedType = 
((ParameterizedType) actualTypeArgument).getRawType();
+   if(innerParameterizedType instanceof Class) {
+final Class actualType = (Class) 
innerParameterizedType;
+return actualType;
+}
+}
 }
 }
 
@@ -295,8 +304,7 @@ public final class _Collections {
  * @return inferred type or null if inference fails
  */
 public static @Nullable Class inferElementTypeIfAny(@Nullable final 
Field field) {
-   
-return inferElementTypeIfAny(field.getType(), field.getGenericType());
+   return inferElementTypeIfAny(field.getType(), field.getGenericType());
 }
 
// --
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/ServicesInjector.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/ServicesInjector.java
index ea21cb7..83423b4 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/ServicesInjector.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/ServicesInjector.java
@@ -445,7 +445,7 @@ public class ServicesInjector implements 
ApplicationScopedComponent {
 // -- REFLECTIVE PREDICATES
 
 private static final Predicate isOfType(final Class cls) {
-return obj->cls.isAssignableFrom(obj.getClass());
+   return obj->cls.isAssignableFrom(obj.getClass());
 }
 
 private static final Predicate nameStartsWith(final String prefix) 
{
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/serv

[isis] branch master updated: ISIS-1841: further cleaning up some compiler warnings

2018-05-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 86a1265  ISIS-1841: further cleaning up some compiler warnings
86a1265 is described below

commit 86a1265e50991b202e67d6c967c404448692a75d
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Sun May 27 21:40:12 2018 +0200

ISIS-1841: further cleaning up some compiler warnings

Task-Url: https://issues.apache.org/jira/browse/ISIS-1841
---
 .../isis/core/integtestsupport/IsisSystemForTest.java   |  6 +++---
 .../apache/isis/tool/mavenplugin/util/MavenProjects.java|  1 -
 .../annotation/RemoveAnnotatedMethodsFacetFactory.java  |  6 +++---
 .../annotprop/MemberGroupLayoutFacetFactory.java|  1 -
 .../isis/core/metamodel/services/swagger/internal/Util.java | 13 -
 .../isis/core/metamodel/spec/feature/ObjectAction.java  |  6 +++---
 .../org/apache/isis/core/runtime/headless/IsisSystem.java   |  1 -
 .../IsisComponentProviderUsingInstallers.java   |  1 -
 .../isis/viewer/restfulobjects/server/ResourceContext.java  |  1 -
 9 files changed, 13 insertions(+), 23 deletions(-)

diff --git 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IsisSystemForTest.java
 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IsisSystemForTest.java
index 0a9be65..ef8cd70 100644
--- 
a/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IsisSystemForTest.java
+++ 
b/core/integtestsupport/src/main/java/org/apache/isis/core/integtestsupport/IsisSystemForTest.java
@@ -153,8 +153,9 @@ public class IsisSystemForTest implements 
org.junit.rules.TestRule, DomainServic
 
 private AppManifest appManifestIfAny;
 
-private final List services = _Lists.newArrayList();
-private final List fixtures = 
_Lists.newArrayList();
+//[ahuber] not used
+//private final List services = _Lists.newArrayList();
+//private final List fixtures = 
_Lists.newArrayList();
 
 private final List  listeners = _Lists.newArrayList();
 
@@ -628,7 +629,6 @@ public class IsisSystemForTest implements 
org.junit.rules.TestRule, DomainServic
  * @see 
org.apache.isis.core.integtestsupport.ServiceProvider#getService(java.lang.Class)
  */
 @Override
-@SuppressWarnings("unchecked")
 public  T getService(Class serviceClass) {
 final ServicesInjector servicesInjector = 
isisSessionFactory.getServicesInjector();
 return servicesInjector.lookupServiceElseFail(serviceClass);
diff --git 
a/core/maven-plugin/src/main/java/org/apache/isis/tool/mavenplugin/util/MavenProjects.java
 
b/core/maven-plugin/src/main/java/org/apache/isis/tool/mavenplugin/util/MavenProjects.java
index d74dcdb..9eda11a 100644
--- 
a/core/maven-plugin/src/main/java/org/apache/isis/tool/mavenplugin/util/MavenProjects.java
+++ 
b/core/maven-plugin/src/main/java/org/apache/isis/tool/mavenplugin/util/MavenProjects.java
@@ -29,7 +29,6 @@ public final class MavenProjects {
 
 public static Plugin lookupPlugin(MavenProject mavenProject, String key) {
 
-@SuppressWarnings("unchecked")
 List plugins = mavenProject.getBuildPlugins();
 
 for (Plugin plugin : plugins) {
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/ignore/annotation/RemoveAnnotatedMethodsFacetFactory.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/ignore/annotation/RemoveAnnotatedMethodsFacetFactory.java
index 6d456e6..4f5f708 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/ignore/annotation/RemoveAnnotatedMethodsFacetFactory.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/ignore/annotation/RemoveAnnotatedMethodsFacetFactory.java
@@ -28,6 +28,7 @@ import javax.annotation.PreDestroy;
 import com.google.common.eventbus.Subscribe;
 
 import org.apache.isis.applib.annotation.Programmatic;
+import org.apache.isis.commons.internal.base._Casts;
 import org.apache.isis.core.commons.lang.ClassUtil;
 import org.apache.isis.core.metamodel.facetapi.FeatureType;
 import org.apache.isis.core.metamodel.facetapi.MethodRemover;
@@ -43,8 +44,8 @@ public class RemoveAnnotatedMethodsFacetFactory extends 
FacetFactoryAbstract {
 
 try {
 // doing this reflectively so that don't bring in a dependency on 
axon.
-Class cls = (Class) 
ClassUtil.forName("org.axonframework.eventhandling.annotation.EventHandler");
-eventHandlerClass = cls;
+eventHandlerClass = _Casts.uncheckedCast(
+   
ClassUtil.forName("org.axonframework.eventhandling.annotation.EventHandler"));
 
 } catch(Exception ignore) {
 

[isis] 03/04: ISIS-1960: Action background execution built-in default:

2018-06-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 9332cdd9a6a536cbe769770808d4e3ca16afbd74
Author: Andi Huber 
AuthorDate: Wed Jun 27 09:31:33 2018 +0200

ISIS-1960: Action background execution built-in default:

wait for current thread's transaction to complete before executing
background tasks

Task-Url: https://issues.apache.org/jira/browse/ISIS-1960
---
 .../applib/services/xactn/TransactionService.java  | 10 ++-
 .../PersistenceSessionServiceInternal.java | 11 ++--
 .../PersistenceSessionServiceInternalNoop.java |  8 +++
 .../services/xactn/TransactionServiceDefault.java  |  9 ++-
 .../background/BackgroundCommandExecution.java | 26 ++--
 .../background/ForkingInvocationHandler.java   | 12 
 .../PersistenceSessionServiceInternalDefault.java  |  7 +++
 .../system/persistence/PersistenceSessionBase.java |  2 +-
 .../system/transaction/IsisTransaction.java| 73 ++
 .../system/transaction/IsisTransactionManager.java | 14 ++---
 10 files changed, 94 insertions(+), 78 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/xactn/TransactionService.java
 
b/core/applib/src/main/java/org/apache/isis/applib/services/xactn/TransactionService.java
index 124dba5..d6de35b 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/xactn/TransactionService.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/services/xactn/TransactionService.java
@@ -19,6 +19,8 @@
 
 package org.apache.isis.applib.services.xactn;
 
+import java.util.concurrent.CountDownLatch;
+
 import org.apache.isis.applib.annotation.Programmatic;
 import org.apache.isis.applib.services.command.Command;
 import org.apache.isis.applib.services.command.CommandContext;
@@ -59,7 +61,13 @@ public interface TransactionService {
 @Programmatic
 TransactionState getTransactionState();
 
-
+/**
+ * Return a latch, that allows threads to wait on the current transaction 
to complete.
+ */
+@Programmatic
+CountDownLatch currentTransactionLatch(); 
+
+
 /**
  * Intended only for use by fixture scripts and integration tests.
  *
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/persistsession/PersistenceSessionServiceInternal.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/persistsession/PersistenceSessionServiceInternal.java
index daa1b69..572af70 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/persistsession/PersistenceSessionServiceInternal.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/persistsession/PersistenceSessionServiceInternal.java
@@ -17,13 +17,14 @@
 package org.apache.isis.core.metamodel.services.persistsession;
 
 import java.util.List;
+import java.util.concurrent.CountDownLatch;
 
 import org.apache.isis.applib.annotation.Programmatic;
 import org.apache.isis.applib.query.Query;
 import org.apache.isis.applib.services.bookmark.Bookmark;
 import org.apache.isis.applib.services.bookmark.BookmarkService;
-import org.apache.isis.applib.services.xactn.Transaction;
 import org.apache.isis.applib.services.command.Command;
+import org.apache.isis.applib.services.xactn.Transaction;
 import org.apache.isis.applib.services.xactn.TransactionState;
 import org.apache.isis.core.metamodel.adapter.ObjectAdapter;
 import org.apache.isis.core.metamodel.adapter.mgr.AdapterManager;
@@ -120,13 +121,13 @@ public interface PersistenceSessionServiceInternal 
extends AdapterManager {
 
 @Programmatic
 Transaction currentTransaction();
-
+
+@Programmatic
+   CountDownLatch currentTransactionLatch();
 
 @Programmatic
 TransactionState getTransactionState();
 
-
-
 // -- makePersistent, remove
 
 /**
@@ -174,6 +175,4 @@ public interface PersistenceSessionServiceInternal extends 
AdapterManager {
 void executeWithinTransaction(TransactionalClosure transactionalClosure);
 
 
-
-
 }
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/persistsession/PersistenceSessionServiceInternalNoop.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/persistsession/PersistenceSessionServiceInternalNoop.java
index 086400b..1016a20 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/persistsession/PersistenceSessionServiceInternalNoop.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/services/persistsession/PersistenceSessionServiceInternalNoop.java
@@ -19,6 +19,7 @@
 package org.apache.isis.core.metamodel.services.persistsession;
 
 import java.util.List;
+import java.util.concurrent.CountDownLatch;
 
 import org.apache.isis.applib.annotation.DomainService;
 import

[isis] 01/04: ISIS-1960: applib: remove BackgroundService2 and BackgroundCommandService2

2018-06-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit bbdad22b392cf910ae196ca7304edc86b117b7f6
Author: Andi Huber 
AuthorDate: Wed Jun 27 07:41:53 2018 +0200

ISIS-1960: applib: remove BackgroundService2 and
BackgroundCommandService2

Task-Url: https://issues.apache.org/jira/browse/ISIS-1960
---
 .../background/BackgroundCommandService.java   | 10 
 .../services/background/BackgroundService.java |  6 ++
 .../background/BackgroundCommandService2.java  | 13 +
 .../services/background/BackgroundService2.java| 13 ++---
 .../background/BackgroundServiceDefault.java   | 67 +-
 .../background/CommandInvocationHandler.java   |  6 +-
 6 files changed, 65 insertions(+), 50 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService.java
 
b/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService.java
index 11621d8..c086d2b 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService.java
@@ -16,6 +16,9 @@
  */
 package org.apache.isis.applib.services.background;
 
+import org.apache.isis.applib.services.command.Command;
+import org.apache.isis.schema.cmd.v1.CommandDto;
+
 /**
  * Persists a {@link org.apache.isis.schema.cmd.v1.CommandDto command-reified} 
action such that it can be executed asynchronously,
  * for example through a Quartz scheduler.
@@ -34,5 +37,12 @@ package org.apache.isis.applib.services.background;
  *
  */
 public interface BackgroundCommandService {
+   
+   public void schedule(
+final CommandDto dto,
+final Command parentCommand,
+final String targetClassName,
+final String targetActionName,
+final String targetArgs);
 
 }
diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundService.java
 
b/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundService.java
index 158a86a..f22af39 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundService.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundService.java
@@ -47,5 +47,11 @@ public interface BackgroundService {
 @Programmatic
  T execute(final T object);
 
+/**
+ * Returns a proxy around the mixin object which is then used to obtain the
+ * signature of the action to be invoked in the background.
+ */
+@Programmatic
+ T executeMixin(Class mixinClass, Object mixedIn);
 
 }
diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
 
b/core/legacy/applib-legacy/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
similarity index 77%
rename from 
core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
rename to 
core/legacy/applib-legacy/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
index e693592..7c3ed13 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
+++ 
b/core/legacy/applib-legacy/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
@@ -16,20 +16,13 @@
  */
 package org.apache.isis.applib.services.background;
 
-import org.apache.isis.applib.services.command.Command;
-import org.apache.isis.schema.cmd.v1.CommandDto;
-
 /**
  * Persists a {@link org.apache.isis.schema.cmd.v1.CommandDto memento-ized} 
command such that it can be
  * executed asynchronously, for example through a Quartz scheduler.
- *
+ * @deprecated use BackgroundCommandService instead
  */
+@Deprecated
 public interface BackgroundCommandService2 extends BackgroundCommandService {
 
-void schedule(
-final CommandDto dto,
-final Command parentCommand,
-final String targetClassName,
-final String targetActionName,
-final String targetArgs);
+
 }
diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java
 
b/core/legacy/applib-legacy/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java
similarity index 77%
rename from 
core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java
rename to 
core/legacy/applib-legacy/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java
index 529aa85..7f68327 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java
+++ 
b/core/legacy/applib-legacy/src

[isis] 02/04: ISIS-1960: add removed interfaces to module 'transition'

2018-06-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 294ffec8c82d1ff3038cdd3f7d4d6d3e96485eeb
Author: Andi Huber 
AuthorDate: Wed Jun 27 08:00:10 2018 +0200

ISIS-1960: add removed interfaces to module 'transition'

Task-Url: https://issues.apache.org/jira/browse/ISIS-1960
---
 .../background/BackgroundCommandService2.java  | 28 ++
 .../services/background/BackgroundService2.java| 28 ++
 2 files changed, 56 insertions(+)

diff --git 
a/core/legacy/transition-1-2/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
 
b/core/legacy/transition-1-2/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
new file mode 100644
index 000..7c3ed13
--- /dev/null
+++ 
b/core/legacy/transition-1-2/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
@@ -0,0 +1,28 @@
+/**
+ *  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.services.background;
+
+/**
+ * Persists a {@link org.apache.isis.schema.cmd.v1.CommandDto memento-ized} 
command such that it can be
+ * executed asynchronously, for example through a Quartz scheduler.
+ * @deprecated use BackgroundCommandService instead
+ */
+@Deprecated
+public interface BackgroundCommandService2 extends BackgroundCommandService {
+
+
+}
diff --git 
a/core/legacy/transition-1-2/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java
 
b/core/legacy/transition-1-2/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java
new file mode 100644
index 000..7f68327
--- /dev/null
+++ 
b/core/legacy/transition-1-2/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java
@@ -0,0 +1,28 @@
+/**
+ *  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.services.background;
+
+/**
+ * Submit actions to be invoked in the background.
+ * @deprecated use BackgroundService instead
+ * 
+ */
+@Deprecated
+public interface BackgroundService2 extends BackgroundService {
+   
+
+}



[isis] branch master updated (d7fefd3 -> ce0968e)

2018-06-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git.


from d7fefd3  ISIS-1963: workaround the issue by selective exception 
suppression
 new bbdad22  ISIS-1960: applib: remove BackgroundService2 and 
BackgroundCommandService2
 new 294ffec  ISIS-1960: add removed interfaces to module 'transition'
 new 9332cdd  ISIS-1960: Action background execution built-in default:
 new ce0968e  ISIS-1960: moving TransactionServiceDefault 'metamodel' -> 
'runtime'

The 4 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../background/BackgroundCommandService.java   | 10 +++
 .../services/background/BackgroundService.java |  6 ++
 .../services/background/BackgroundService2.java| 33 -
 .../isis/applib/services/xactn/Transaction.java| 14 
 .../applib/services/xactn/TransactionService.java  | 10 ++-
 .../background/BackgroundCommandService2.java  | 13 +---
 .../services/background/BackgroundService2.java}   | 12 +++-
 .../background/BackgroundCommandService2.java  | 13 +---
 .../services/background/BackgroundService2.java}   | 12 +++-
 .../PersistenceSessionServiceInternal.java | 11 ++-
 .../PersistenceSessionServiceInternalNoop.java |  8 +++
 .../background/BackgroundCommandExecution.java | 26 ++-
 .../background/BackgroundServiceDefault.java   | 67 +
 .../background/CommandInvocationHandler.java   |  6 +-
 .../background/ForkingInvocationHandler.java   | 12 
 .../PersistenceSessionServiceInternalDefault.java  |  7 ++
 .../services/xactn/TransactionServiceDefault.java  | 17 -
 .../system/persistence/PersistenceSessionBase.java |  2 +-
 .../system/transaction/IsisTransaction.java| 83 +++---
 .../system/transaction/IsisTransactionManager.java | 14 ++--
 20 files changed, 191 insertions(+), 185 deletions(-)
 delete mode 100644 
core/applib/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java
 copy core/{applib => 
legacy/applib-legacy}/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
 (77%)
 copy 
core/{metamodel/src/main/java/org/apache/isis/objectstore/jdo/metamodel/facets/object/persistencecapable/package-info.java
 => 
legacy/applib-legacy/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java}
 (78%)
 rename core/{applib => 
legacy/transition-1-2}/src/main/java/org/apache/isis/applib/services/background/BackgroundCommandService2.java
 (77%)
 copy 
core/{metamodel/src/main/java/org/apache/isis/objectstore/jdo/metamodel/facets/object/persistencecapable/package-info.java
 => 
legacy/transition-1-2/src/main/java/org/apache/isis/applib/services/background/BackgroundService2.java}
 (78%)
 rename core/{metamodel/src/main/java/org/apache/isis/core/metamodel => 
runtime/src/main/java/org/apache/isis/core/runtime}/services/xactn/TransactionServiceDefault.java
 (85%)



[isis] branch master updated: ISIS-1960: Action background execution: propagate the current auth-session instead of creating a new

2018-06-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new f0330f6  ISIS-1960: Action background execution: propagate the current 
auth-session instead of creating a new
f0330f6 is described below

commit f0330f6796844f56957c1d628f89425ad01b46d6
Author: Andi Huber 
AuthorDate: Wed Jun 27 11:29:47 2018 +0200

ISIS-1960: Action background execution: propagate the current
auth-session instead of creating a new

Task-Url: https://issues.apache.org/jira/browse/ISIS-1960
---
 .../background/ForkingInvocationHandler.java| 21 +++--
 .../runtime/system/session/IsisSessionFactory.java  |  2 --
 2 files changed, 15 insertions(+), 8 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/ForkingInvocationHandler.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/ForkingInvocationHandler.java
index 8fa7a34..9fab6e4 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/ForkingInvocationHandler.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/services/background/ForkingInvocationHandler.java
@@ -24,7 +24,9 @@ import java.util.Optional;
 import java.util.concurrent.CountDownLatch;
 import java.util.concurrent.ExecutorService;
 
+import org.apache.isis.core.commons.authentication.AuthenticationSession;
 import org.apache.isis.core.runtime.system.context.IsisContext;
+import org.apache.isis.core.runtime.system.internal.InitialisationSession;
 import org.apache.isis.core.runtime.system.session.IsisSession;
 import org.apache.isis.core.runtime.system.session.IsisSessionFactory;
 import org.apache.isis.core.runtime.system.transaction.IsisTransaction;
@@ -66,11 +68,17 @@ class ForkingInvocationHandler implements 
InvocationHandler {
 domainObject = mixedInIfAny;
 }
 
-final CountDownLatch countDownLatch = 
Optional.ofNullable(IsisContext.getSessionFactory())
-   .map(IsisSessionFactory::getCurrentSession)
-   .map(IsisSession::getCurrentTransaction)
-   .map(IsisTransaction::countDownLatch)
-   .orElse(new CountDownLatch(0));
+final Optional currentSession = 
Optional.ofNullable(IsisContext.getSessionFactory())
+   .map(IsisSessionFactory::getCurrentSession);
+
+final AuthenticationSession authSession = currentSession
+   .map(IsisSession::getAuthenticationSession)
+   .orElse(new InitialisationSession());
+
+final CountDownLatch countDownLatch = currentSession
+   .map(IsisSession::getCurrentTransaction)
+   .map(IsisTransaction::countDownLatch)
+   .orElse(new CountDownLatch(0));
 
 backgroundExecutorService.submit(()->{

@@ -78,7 +86,8 @@ class ForkingInvocationHandler implements 
InvocationHandler {
countDownLatch.await(); // wait for current transaction 
of the calling thread to complete

IsisContext.getSessionFactory().doInSession(
-   ()->proxyMethod.invoke(domainObject, args));
+   ()->proxyMethod.invoke(domainObject, args), 
+   authSession );

} catch (Exception e) {
// log in caller's context  
diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactory.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactory.java
index c9fece3..c013869 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactory.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactory.java
@@ -252,8 +252,6 @@ public class IsisSessionFactory
 return logonFixture;
 }
 
-
-
 // -- openSession, closeSession, currentSession, inSession
 private final ThreadLocal currentSession = new 
ThreadLocal<>();
 



[isis] branch dev/2.0.0/ISIS-1762-j8-utils deleted (was 4a9a3aa)

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git.


 was 4a9a3aa  ISIS-1762 fixing won't compile on eclipse

This change permanently discards the following revisions:

 discard 4a9a3aa  ISIS-1762 fixing won't compile on eclipse
 discard a8b21e7  ISIS-1728: uses typesafe queries for helloworld
 discard a5419e9  ISIS-1726: generalizes the logic that searches for 
@PersistenceCapable entities, to also take into account meta-annotations.
 discard 5c81e1c  ISIS-1727: uses lambda in IsisSessionFactoryBuilder
 discard 2abad13  ISIS-1725: requires that an AppManifest is supplied (used to 
obtain list of entities).
 discard bf3d034  ISIS-1724: removes the deprecated IsisJdoSupport in the jdo 
applib
 discard 4ab0b54  ISIS-1723: removes jdo applib's Auditable interface and 
@Auditable annotation
 discard be40ecf  ISIS-1276: fixes algorithm for lookup of datastore id's, at 
least
 discard f0900ad  ISIS-1276: fixes compile issue in specsupport
 discard 5565822  ISIS-1276: fixes compile issues in metamodel and runtime
 discard dd39ec6  ISIS-1276: updates applib, replaces references of 
TypesafeQuery to be instead JDOQLTypedQuery
 discard 2d48766  ISIS-1276: updates core to compile under JDK 1.8 only
 discard ccb0bc9  ISIS-1276: updates references for datanucleus.

-- 
To stop receiving notification emails like this one, please contact
['"commits@isis.apache.org" <commits@isis.apache.org>'].


[isis] 03/13: ISIS-1276: updates applib, replaces references of TypesafeQuery to be instead JDOQLTypedQuery

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit dd39ec69f2c5e36e52b6fe283b22058caca5d347
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:17:54 2017 +0100

ISIS-1276: updates applib, replaces references of TypesafeQuery to be 
instead JDOQLTypedQuery
---
 .../org/apache/isis/applib/services/jdosupport/IsisJdoSupport.java | 7 +++
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/jdosupport/IsisJdoSupport.java
 
b/core/applib/src/main/java/org/apache/isis/applib/services/jdosupport/IsisJdoSupport.java
index 4ca5c10..75a4e0f 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/jdosupport/IsisJdoSupport.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/services/jdosupport/IsisJdoSupport.java
@@ -23,10 +23,9 @@ import java.util.Collection;
 import java.util.List;
 import java.util.Map;
 
+import javax.jdo.JDOQLTypedQuery;
 import javax.jdo.PersistenceManager;
-
-import org.datanucleus.query.typesafe.BooleanExpression;
-import org.datanucleus.query.typesafe.TypesafeQuery;
+import javax.jdo.query.BooleanExpression;
 
 import org.apache.isis.applib.annotation.Programmatic;
 
@@ -132,5 +131,5 @@ public interface IsisJdoSupport {
  * 
  */
 @Programmatic
- TypesafeQuery newTypesafeQuery(Class cls);
+ JDOQLTypedQuery newTypesafeQuery(Class cls);
 }

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] branch dev/2.0.0/ISIS-1762-j8-utils created (now 4a9a3aa)

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git.


  at 4a9a3aa  ISIS-1762 fixing won't compile on eclipse

This branch includes the following new commits:

 new ccb0bc9  ISIS-1276: updates references for datanucleus.
 new 2d48766  ISIS-1276: updates core to compile under JDK 1.8 only
 new dd39ec6  ISIS-1276: updates applib, replaces references of 
TypesafeQuery to be instead JDOQLTypedQuery
 new 5565822  ISIS-1276: fixes compile issues in metamodel and runtime
 new f0900ad  ISIS-1276: fixes compile issue in specsupport
 new be40ecf  ISIS-1276: fixes algorithm for lookup of datastore id's, at 
least
 new 4ab0b54  ISIS-1723: removes jdo applib's Auditable interface and 
@Auditable annotation
 new bf3d034  ISIS-1724: removes the deprecated IsisJdoSupport in the jdo 
applib
 new 2abad13  ISIS-1725: requires that an AppManifest is supplied (used to 
obtain list of entities).
 new 5c81e1c  ISIS-1727: uses lambda in IsisSessionFactoryBuilder
 new a5419e9  ISIS-1726: generalizes the logic that searches for 
@PersistenceCapable entities, to also take into account meta-annotations.
 new a8b21e7  ISIS-1728: uses typesafe queries for helloworld
 new 4a9a3aa  ISIS-1762 fixing won't compile on eclipse

The 13 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


-- 
To stop receiving notification emails like this one, please contact
['"commits@isis.apache.org" <commits@isis.apache.org>'].


[isis] 01/13: ISIS-1276: updates references for datanucleus.

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit ccb0bc90a5174f3b31f8797b90ce83f0b93b1add
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:13:20 2017 +0100

ISIS-1276: updates references for datanucleus.

Also updated org.incode:incode-build to 3-SNAPSHOT, and 
java-mavenmixin-datanucleus to 0.0.5-SNAPSHOT
---
 core/applib/pom.xml| 39 ++
 core/pom.xml   | 19 -
 core/unittestsupport/pom.xml   |  5 ++---
 example/application/helloworld/pom.xml |  4 ++--
 example/application/simpleapp/pom.xml  |  8 +++
 5 files changed, 19 insertions(+), 56 deletions(-)

diff --git a/core/applib/pom.xml b/core/applib/pom.xml
index c048c8c..3776e8f 100644
--- a/core/applib/pom.xml
+++ b/core/applib/pom.xml
@@ -51,41 +51,6 @@
 
 
 
-
-
-
-
-org.eclipse.m2e
-lifecycle-mapping
-1.0.0
-
-
-
-
-
-
-org.datanucleus
-
-
-datanucleus-maven-plugin
-
-
-[4.0.0-release,)
-
-
-enhance
-
-
-
-
-
-
-
-
-
-
-
-
 
 
 
@@ -128,8 +93,8 @@
 
 
 
-javax.jdo
-jdo-api
+org.datanucleus
+javax.jdo
 
 
 
diff --git a/core/pom.xml b/core/pom.xml
index d898beb..8aec65b 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -84,14 +84,13 @@
 [6] 
https://github.com/moment/moment/blob/develop/LICENSE
 
 
-3.1
+3.2.0-m7
 
-4.1.7
-4.1.1
-4.0.5
-4.1.9
-
-
4.1.0-release
+5.1.2
+5.1.2
+5.0.2
+5.1.2
+
5.1.0-release

-
4.0.2
+
5.0.2
 
 1.2.6
 
@@ -1950,8 +1949,8 @@ ${license.additional-notes}
 
 
 
-javax.jdo
-jdo-api
+org.datanucleus
+javax.jdo
 ${jdo-api.version}
 
 
diff --git a/core/unittestsupport/pom.xml b/core/unittestsupport/pom.xml
index 2c84d64..6783db0 100644
--- a/core/unittestsupport/pom.xml
+++ b/core/unittestsupport/pom.xml
@@ -56,9 +56,8 @@

 
 
-javax.jdo
-jdo-api
-${jdo-api.version}
+org.datanucleus
+javax.jdo
 true
 
 
diff --git a/example/application/helloworld/pom.xml 
b/example/application/helloworld/pom.xml
index 646de10..193ca67 100644
--- a/example/application/helloworld/pom.xml
+++ b/example/application/helloworld/pom.xml
@@ -24,7 +24,7 @@
 
 org.incode
 incode-build
-2
+3-SNAPSHOT
 
 
 org.apache.isis.example.application
@@ -42,7 +42,7 @@
 
 1.8
 1.8
-
+
-parameters
 
 UTF-8
 
UTF-8
diff --git a/example/application/simpleapp/pom.xml 
b/example/application/simpleapp/pom.xml
index 9ee473a..fd6dbee 100644
--- a/example/application/simpleapp/pom.xml
+++ b/example/application/simpleapp/pom.xml
@@ -24,7 +24,7 @@
 
 org.incode
 incode-build
-2
+3-SNAPSHOT
 
 
 org.apache.isis.example.application
@@ -44,9 +44,9 @@
 
 1.16.18
 
-1.7
-1.7
-
+1.8
+1.8
+
-parameters
 
 UTF-8
 
UTF-8

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 08/13: ISIS-1724: removes the deprecated IsisJdoSupport in the jdo applib

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit bf3d034f0a720a60a531c5f67bef5266f7044fe5
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Tue Sep 19 22:50:00 2017 +0100

ISIS-1724: removes the deprecated IsisJdoSupport in the jdo applib
---
 .../jdo/applib/service/support/IsisJdoSupport.java | 28 --
 .../service/support/IsisJdoSupportImpl.java|  3 +--
 2 files changed, 1 insertion(+), 30 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/objectstore/jdo/applib/service/support/IsisJdoSupport.java
 
b/core/applib/src/main/java/org/apache/isis/objectstore/jdo/applib/service/support/IsisJdoSupport.java
deleted file mode 100644
index 2d50ce6..000
--- 
a/core/applib/src/main/java/org/apache/isis/objectstore/jdo/applib/service/support/IsisJdoSupport.java
+++ /dev/null
@@ -1,28 +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 org.apache.isis.objectstore.jdo.applib.service.support;
-
-/**
- * @deprecated - replaced by {@link 
org.apache.isis.applib.services.jdosupport.IsisJdoSupport}
- */
-@Deprecated
-public interface IsisJdoSupport extends 
org.apache.isis.applib.services.jdosupport.IsisJdoSupport {
-
-}
diff --git 
a/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/service/support/IsisJdoSupportImpl.java
 
b/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/service/support/IsisJdoSupportImpl.java
index 696f58b..4bfacf6 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/service/support/IsisJdoSupportImpl.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/service/support/IsisJdoSupportImpl.java
@@ -47,7 +47,6 @@ import 
org.apache.isis.core.metamodel.services.ServicesInjector;
 import org.apache.isis.core.runtime.persistence.ObjectPersistenceException;
 import org.apache.isis.core.runtime.system.persistence.PersistenceSession;
 import org.apache.isis.core.runtime.system.session.IsisSessionFactory;
-import org.apache.isis.objectstore.jdo.applib.service.support.IsisJdoSupport;
 
 
 /**
@@ -62,7 +61,7 @@ import 
org.apache.isis.objectstore.jdo.applib.service.support.IsisJdoSupport;
 nature = NatureOfService.DOMAIN,
 menuOrder = "" + Integer.MAX_VALUE
 )
-public class IsisJdoSupportImpl implements IsisJdoSupport {
+public class IsisJdoSupportImpl implements 
org.apache.isis.applib.services.jdosupport.IsisJdoSupport {
 
 @Programmatic
 @Override

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 07/13: ISIS-1723: removes jdo applib's Auditable interface and @Auditable annotation

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 4ab0b5434e701530f0c8e8dc7eb8f9f1576cf553
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Tue Sep 19 22:43:59 2017 +0100

ISIS-1723: removes jdo applib's Auditable interface and @Auditable 
annotation
---
 .../jdo/applib/annotations/Auditable.java  | 36 
 .../isis/objectstore/jdo/applib/Auditable.java | 26 --
 ...AuditableAnnotationInJdoApplibFacetFactory.java | 81 --
 .../AuditableFacetAnnotationInJdoApplib.java   | 33 
 .../AuditableFacetMarkerInterfaceInJdoApplib.java  | 32 ---
 ...ableMarkerInterfaceInJdoApplibFacetFactory.java | 56 
 .../GivenAuditableAnnotationFacetFactoryTest.java  | 99 --
 ...enAuditableFacetMarkerInterfaceFactoryTest.java | 99 --
 .../PersistenceSessionFactoryMetamodelRefiner.java |  5 --
 9 files changed, 467 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/core/objectstore/jdo/applib/annotations/Auditable.java
 
b/core/applib/src/main/java/org/apache/isis/core/objectstore/jdo/applib/annotations/Auditable.java
deleted file mode 100644
index c903b65..000
--- 
a/core/applib/src/main/java/org/apache/isis/core/objectstore/jdo/applib/annotations/Auditable.java
+++ /dev/null
@@ -1,36 +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 org.apache.isis.core.objectstore.jdo.applib.annotations;
-
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Inherited;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-/**
- * @deprecated use the {@link org.apache.isis.applib.annotation.Audited the 
applib Audited} annotation instead.
- */
-@Deprecated
-@Inherited
-@Target({ ElementType.TYPE })
-@Retention(RetentionPolicy.RUNTIME)
-public @interface Auditable {
-}
diff --git 
a/core/applib/src/main/java/org/apache/isis/objectstore/jdo/applib/Auditable.java
 
b/core/applib/src/main/java/org/apache/isis/objectstore/jdo/applib/Auditable.java
deleted file mode 100644
index 8035bfd..000
--- 
a/core/applib/src/main/java/org/apache/isis/objectstore/jdo/applib/Auditable.java
+++ /dev/null
@@ -1,26 +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 org.apache.isis.objectstore.jdo.applib;
-
-/**
- * @deprecated use the {@link org.apache.isis.applib.marker.Auditable the 
applib Auditable} marker interface instead.
- */
-@Deprecated
-public interface Auditable extends org.apache.isis.applib.marker.Auditable {
-}
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/objectstore/jdo/metamodel/facets/object/auditable/AuditableAnnotationInJdoApplibFacetFactory.java
 
b/core/metamodel/src/main/java/org/apache/isis/objectstore/jdo/metamodel/facets/object/auditable/AuditableAnnotationInJdoApplibFacetFactory.java
deleted file mode 100644
index 6c26460..000
--- 
a/core/metamodel/src/main/java/org/apache/isis/objectstore/jdo/metamodel/facets/object/auditable/AuditableAnnotationInJdoApplibFacetFactory.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agr

[isis] 12/13: ISIS-1728: uses typesafe queries for helloworld

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit a8b21e7b6363f5e8d9289bbcb9ea3bdc7f0d45f5
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Tue Sep 19 23:02:07 2017 +0100

ISIS-1728: uses typesafe queries for helloworld
---
 .../main/java/domainapp/dom/impl/HelloWorldObject.java  | 17 ++---
 .../main/java/domainapp/dom/impl/HelloWorldObjects.java | 15 ---
 2 files changed, 14 insertions(+), 18 deletions(-)

diff --git 
a/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObject.java
 
b/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObject.java
index 40708dd..90ad57a 100644
--- 
a/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObject.java
+++ 
b/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObject.java
@@ -42,27 +42,19 @@ import org.apache.isis.applib.services.title.TitleService;
 
 import lombok.AccessLevel;
 
-@javax.jdo.annotations.PersistenceCapable(identityType = 
IdentityType.DATASTORE, schema = "helloworld" )
+@javax.jdo.annotations.PersistenceCapable(identityType = 
IdentityType.DATASTORE,schema = "helloworld" )
 @javax.jdo.annotations.DatastoreIdentity(strategy = 
IdGeneratorStrategy.IDENTITY, column = "id")
 @javax.jdo.annotations.Version(strategy= VersionStrategy.DATE_TIME, column 
="version")
-@javax.jdo.annotations.Queries({
-@javax.jdo.annotations.Query(
-name = "findByName",
-value = "SELECT "
-+ "FROM domainapp.dom.impl.HelloWorldObject "
-+ "WHERE name.indexOf(:name) >= 0 ")
-})
-@javax.jdo.annotations.Unique(name="HelloWorldObject_name_UNQ", members = 
{"name"})
-@DomainObject(auditing = Auditing.ENABLED)
+@DomainObject(auditing = Auditing.ENABLED, editing = Editing.DISABLED)
 @DomainObjectLayout()  // trigger events etc.
 @lombok.RequiredArgsConstructor(staticName = "create")
 @lombok.Getter @lombok.Setter
 public class HelloWorldObject implements Comparable {
 
 
+@javax.jdo.annotations.Unique
 @javax.jdo.annotations.Column(allowsNull = "false", length = 40)
 @lombok.NonNull
-@Property(editing = Editing.DISABLED)
 @Title(prepend = "Object: ")
 private String name;
 
@@ -102,14 +94,17 @@ public class HelloWorldObject implements 
Comparable {
 
 //region > injected services
 @javax.inject.Inject
+@javax.jdo.annotations.NotPersistent
 @lombok.Getter(AccessLevel.NONE) @lombok.Setter(AccessLevel.NONE)
 RepositoryService repositoryService;
 
 @javax.inject.Inject
+@javax.jdo.annotations.NotPersistent
 @lombok.Getter(AccessLevel.NONE) @lombok.Setter(AccessLevel.NONE)
 TitleService titleService;
 
 @javax.inject.Inject
+@javax.jdo.annotations.NotPersistent
 @lombok.Getter(AccessLevel.NONE) @lombok.Setter(AccessLevel.NONE)
 MessageService messageService;
 //endregion
diff --git 
a/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObjects.java
 
b/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObjects.java
index a8c4d39..fbb10a8 100644
--- 
a/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObjects.java
+++ 
b/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObjects.java
@@ -28,7 +28,7 @@ import org.apache.isis.applib.annotation.Parameter;
 import org.apache.isis.applib.annotation.ParameterLayout;
 import org.apache.isis.applib.annotation.RestrictTo;
 import org.apache.isis.applib.annotation.SemanticsOf;
-import org.apache.isis.applib.query.QueryDefault;
+import org.apache.isis.applib.services.jdosupport.IsisJdoSupport;
 import org.apache.isis.applib.services.registry.ServiceRegistry2;
 import org.apache.isis.applib.services.repository.RepositoryService;
 
@@ -50,17 +50,15 @@ public class HelloWorldObjects {
 @Action(semantics = SemanticsOf.SAFE)
 @MemberOrder(sequence = "2")
 public List findByName(final String name) {
-return repositoryService.allMatches(
-new QueryDefault<>(
-HelloWorldObject.class,
-"findByName",
-"name", name));
+return isisJdoSupport.executeQuery(HelloWorldObject.class,
+QHelloWorldObject.candidate().name.startsWith(name));
 }
 
 @Action(semantics = SemanticsOf.SAFE, restrictTo = RestrictTo.PROTOTYPING)
 @MemberOrder(sequence = "3")
 public List listAll() {
-return repositoryService.allInstances(HelloWorldObject.class);
+return isisJdoSupport.newTypesafeQuery(

[isis] 09/13: ISIS-1725: requires that an AppManifest is supplied (used to obtain list of entities).

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 2abad13bf00cc69e02038e6f83e1b8640a84504c
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Tue Sep 19 22:55:48 2017 +0100

ISIS-1725: requires that an AppManifest is supplied (used to obtain list of 
entities).
---
 .../persistence/PersistenceSessionFactory.java |  2 +-
 .../objectstore/jdo/service/RegisterEntities.java  | 96 ++
 2 files changed, 9 insertions(+), 89 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionFactory.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionFactory.java
index 8a89c8a..4be046c 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionFactory.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionFactory.java
@@ -93,7 +93,7 @@ public class PersistenceSessionFactory implements 
ApplicationScopedComponent, Fi
 final Map<String, String> datanucleusProps = 
dataNucleusConfig.asMap();
 addDataNucleusPropertiesIfRequired(datanucleusProps);
 
-final RegisterEntities registerEntities = new 
RegisterEntities(configuration.asMap(), specificationLoader);
+final RegisterEntities registerEntities = new 
RegisterEntities(specificationLoader);
 final Set classesToBePersisted = 
registerEntities.getEntityTypes();
 
 applicationComponents = new 
DataNucleusApplicationComponents(jdoObjectstoreConfig, specificationLoader,
diff --git 
a/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/service/RegisterEntities.java
 
b/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/service/RegisterEntities.java
index 538b5b1..a83b115 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/service/RegisterEntities.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/service/RegisterEntities.java
@@ -18,23 +18,13 @@
  */
 package org.apache.isis.objectstore.jdo.service;
 
-import java.util.Collections;
 import java.util.List;
-import java.util.Map;
 import java.util.Set;
 
-import javax.jdo.annotations.PersistenceCapable;
-
-import com.google.common.base.Function;
 import com.google.common.base.Joiner;
-import com.google.common.base.Predicate;
-import com.google.common.base.Splitter;
-import com.google.common.base.Strings;
-import com.google.common.collect.Iterables;
 import com.google.common.collect.Lists;
 import com.google.common.collect.Sets;
 
-import org.reflections.Reflections;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -45,7 +35,11 @@ public class RegisterEntities {
 
 @SuppressWarnings("unused")
 private final static Logger LOG = 
LoggerFactory.getLogger(RegisterEntities.class);
-
+
+/**
+ * @deprecated - no longer used; instead an AppManifest must be specified.
+ */
+@Deprecated
 public final static String PACKAGE_PREFIX_KEY = 
"isis.persistor.datanucleus.RegisterEntities.packagePrefix";
 
 // //
@@ -60,13 +54,13 @@ public class RegisterEntities {
 }
 //endregion
 
-public RegisterEntities(final Map<String, String> configuration, final 
SpecificationLoader specificationLoader) {
+public RegisterEntities(final SpecificationLoader specificationLoader) {
 this.specificationLoader = specificationLoader;
 
 Set<Class> persistenceCapableTypes = 
AppManifest.Registry.instance().getPersistenceCapableTypes();
 
 if(persistenceCapableTypes == null) {
-persistenceCapableTypes = 
searchForPersistenceCapables(configuration);
+throw new IllegalStateException("AppManifest is required");
 }
 
 final List classNamesNotEnhanced = Lists.newArrayList();
@@ -86,88 +80,14 @@ public class RegisterEntities {
 }
 }
 
-/**
- * only called if no appManifest
- */
-Set<Class> searchForPersistenceCapables(final Map<String, String> 
configuration) {
-
-final String packagePrefixes = lookupPackagePrefixes(configuration);
-
-final Set<Class> persistenceCapableTypes = Sets.newLinkedHashSet();
-final List domPackages = parseDomPackages(packagePrefixes);
-for (final String packageName : domPackages) {
-Reflections reflections = new Reflections(packageName);
-final Set<Class> entityTypesInPackage =
-
reflections.getTypesAnnotatedWith(PersistenceCapable.class);
-
-if(!entitiesIn(entityTypesInPackage)) {
-throw new IllegalArgumentException(String.format(
-"

[isis] 05/13: ISIS-1276: fixes compile issue in specsupport

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit f0900adc382f0ee2e27889f98a2cf4c0f5bada0a
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:34:29 2017 +0100

ISIS-1276: fixes compile issue in specsupport
---
 .../isis/core/specsupport/scenarios/DomainServiceProviderMockery.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/core/specsupport/src/main/java/org/apache/isis/core/specsupport/scenarios/DomainServiceProviderMockery.java
 
b/core/specsupport/src/main/java/org/apache/isis/core/specsupport/scenarios/DomainServiceProviderMockery.java
index 4d4d2cd..30a294c 100644
--- 
a/core/specsupport/src/main/java/org/apache/isis/core/specsupport/scenarios/DomainServiceProviderMockery.java
+++ 
b/core/specsupport/src/main/java/org/apache/isis/core/specsupport/scenarios/DomainServiceProviderMockery.java
@@ -67,7 +67,7 @@ class DomainServiceProviderMockery implements 
DomainServiceProvider {
 }
 });
 
-
allowing(mockContainer).persistIfNotAlready(with(anything()));
+
allowing(mockContainer).persistIfNotAlready(with(any(Object.class)));
 }
 });
 }

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 04/13: ISIS-1276: fixes compile issues in metamodel and runtime

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 55658227cb1497c46c05dd85a9a53ec0ab5b12f5
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:29:13 2017 +0100

ISIS-1276: fixes compile issues in metamodel and runtime
---
 .../facets/object/parseable/ParserUtil.java|  2 +-
 .../value/vsp/ValueSemanticsProviderUtil.java  |  3 +--
 ...ionParameterAbstractTest_getId_and_getName.java |  6 ++---
 .../DataNucleusApplicationComponents.java  |  2 +-
 .../persistence/PersistenceSessionFactory.java |  2 +-
 .../CreateSchemaObjectFromClassMetadata.java   |  3 ++-
 .../service/support/IsisJdoSupportImpl.java| 27 +-
 7 files changed, 20 insertions(+), 25 deletions(-)

diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/parseable/ParserUtil.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/parseable/ParserUtil.java
index 3f70174..acc1105 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/parseable/ParserUtil.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/parseable/ParserUtil.java
@@ -43,7 +43,7 @@ public final class ParserUtil {
 public static Class> parserOrNull(final Class 
candidateClass, final String classCandidateName) {
 @SuppressWarnings("rawtypes")
 final Class type = candidateClass != null ? 
ClassUtil.implementingClassOrNull(candidateClass.getName(), Parser.class, 
FacetHolder.class) : null;
-return type != null ? type : 
ClassUtil.implementingClassOrNull(classCandidateName, Parser.class, 
FacetHolder.class);
+return type != null ? type : 
(Class)ClassUtil.implementingClassOrNull(classCandidateName, Parser.class, 
FacetHolder.class);
 }
 
 }
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/value/vsp/ValueSemanticsProviderUtil.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/value/vsp/ValueSemanticsProviderUtil.java
index f93ebe1..b34d5fe 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/value/vsp/ValueSemanticsProviderUtil.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/value/vsp/ValueSemanticsProviderUtil.java
@@ -24,7 +24,6 @@ import com.google.common.base.Strings;
 import org.apache.isis.applib.adapters.ValueSemanticsProvider;
 import org.apache.isis.core.commons.config.IsisConfiguration;
 import org.apache.isis.core.commons.lang.ClassUtil;
-import org.apache.isis.core.commons.lang.StringExtensions;
 import org.apache.isis.core.metamodel.facetapi.FacetHolder;
 
 public final class ValueSemanticsProviderUtil {
@@ -45,7 +44,7 @@ public final class ValueSemanticsProviderUtil {
 public static Class> 
valueSemanticsProviderOrNull(final Class candidateClass, final String 
classCandidateName) {
 @SuppressWarnings("rawtypes")
 final Class clazz = candidateClass != null ? 
ClassUtil.implementingClassOrNull(candidateClass.getName(), 
ValueSemanticsProvider.class, FacetHolder.class) : null;
-return clazz != null ? clazz : 
ClassUtil.implementingClassOrNull(classCandidateName, 
ValueSemanticsProvider.class, FacetHolder.class);
+return clazz != null ? clazz : 
(Class)ClassUtil.implementingClassOrNull(classCandidateName, 
ValueSemanticsProvider.class, FacetHolder.class);
 }
 
 }
diff --git 
a/core/metamodel/src/test/java/org/apache/isis/core/metamodel/specloader/specimpl/ObjectActionParameterAbstractTest_getId_and_getName.java
 
b/core/metamodel/src/test/java/org/apache/isis/core/metamodel/specloader/specimpl/ObjectActionParameterAbstractTest_getId_and_getName.java
index 3985ca0..6843e26 100644
--- 
a/core/metamodel/src/test/java/org/apache/isis/core/metamodel/specloader/specimpl/ObjectActionParameterAbstractTest_getId_and_getName.java
+++ 
b/core/metamodel/src/test/java/org/apache/isis/core/metamodel/specloader/specimpl/ObjectActionParameterAbstractTest_getId_and_getName.java
@@ -164,7 +164,7 @@ public class 
ObjectActionParameterAbstractTest_getId_and_getName {
 one(actionParamPeer).getFacet(NamedFacet.class);
 will(returnValue(null));
 
-
one(parentAction).getParameters((Filter) 
with(anything()));
+
one(parentAction).getParameters(with((Filter)anything()));
 will(returnValue(Lists.newArrayList(objectActionParameter)));
 }
 });
@@ -183,7 +183,7 @@ public class 
ObjectActionParameterAbstractTest_getId_and_getName {
 one(actionParamPeer).getFacet(NamedFacet.class);
 will(returnValue(null));
 
-
one(parentAction).getParameters((Filter) 
with(any

[isis] 13/13: ISIS-1762 fixing won't compile on eclipse

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 4a9a3aafaf5992d214637c3d5232df120ff045bd
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Fri Oct 27 09:49:32 2017 +0200

ISIS-1762 fixing won't compile on eclipse
---
 .../viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
 
b/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
index 08205b2..da2cb46 100644
--- 
a/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
+++ 
b/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
@@ -53,7 +53,7 @@ public class LowestCommonSuperclassClosureTest {
 assertLowestCommonOfListIs(listOf(Lion.class, Lion.class), Lion.class);
 }
 
-private static void assertLowestCommonOfListIs(List<Class> list, Class expected) {
+private static void assertLowestCommonOfListIs(List<Class> list, 
Class expected) {
 EntityCollectionModel.LowestCommonSuperclassClosure closure = new 
EntityCollectionModel.LowestCommonSuperclassClosure();
 IterableExtensions.fold(list, closure);
 assertThat(closure.getLowestCommonSuperclass(), 
IsisMatchers.classEqualTo(expected));

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 06/13: ISIS-1276: fixes algorithm for lookup of datastore id's, at least

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit be40ecfa06ac31d15cca66699f031b0a55f88b75
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:55:49 2017 +0100

ISIS-1276: fixes algorithm for lookup of datastore id's, at least
---
 .../persistence/spi/JdoObjectIdSerializer.java | 45 +++---
 1 file changed, 13 insertions(+), 32 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/persistence/spi/JdoObjectIdSerializer.java
 
b/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/persistence/spi/JdoObjectIdSerializer.java
index 48d4da9..ebb4d40 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/persistence/spi/JdoObjectIdSerializer.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/persistence/spi/JdoObjectIdSerializer.java
@@ -90,37 +90,14 @@ public final class JdoObjectIdSerializer {
 final DatastoreId dnOid = (DatastoreId) jdoOid;
 final Object keyValue = dnOid.getKeyAsObject();
 
-if(false) {
-
-//
-// 1.8.0 original handling, appending a prefix "L_" or whatever
-//
-// if required by user community, we could add a property in 
isis.properties to enable if requested.
-//
-if(keyValue instanceof String) {
-return "S" + SEPARATOR + keyValue;
-}
-if(keyValue instanceof Long) {
-return "L" + SEPARATOR + keyValue;
-}
-
-if(keyValue instanceof BigInteger) {
-return "B" + SEPARATOR + keyValue;
-}
-if(keyValue instanceof Integer) {
-return "I" + SEPARATOR + keyValue;
-}
-
-} else {
-if( keyValue instanceof String ||
-keyValue instanceof Long ||
-keyValue instanceof BigDecimal || // 1.8.0 did not 
support BigDecimal
-keyValue instanceof BigInteger ||
-keyValue instanceof Integer) {
-
-// no separator
-return "" + keyValue;
-}
+if( keyValue instanceof String ||
+keyValue instanceof Long ||
+keyValue instanceof BigDecimal || // 1.8.0 did not support 
BigDecimal
+keyValue instanceof BigInteger ||
+keyValue instanceof Integer) {
+
+// no separator
+return "" + keyValue;
 }
 }
 
@@ -201,7 +178,11 @@ public final class JdoObjectIdSerializer {
 // @javax.jdo.annotations.PersistenceCapable(identityType = 
IdentityType.DATASTORE)
 // for one of the common types (prettier handling)
 
-return idStr + "[OID]" + spec.getFullIdentifier();
+// in DN 4.1, we did this...
+// return idStr + "[OID]" + spec.getFullIdentifier();
+
+// in DN 5.1, we simply do this...
+return idStr;
 
 }
 }

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 02/13: ISIS-1276: updates core to compile under JDK 1.8 only

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 2d487666adf53844b8a1bf20fc5eebaeef63a5dd
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:16:56 2017 +0100

ISIS-1276: updates core to compile under JDK 1.8 only
---
 core/pom.xml | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/core/pom.xml b/core/pom.xml
index 8aec65b..9f30b75 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -57,8 +57,8 @@
 **/*IntegrationTest.java
 
 
-1.7
-1.7
+1.8
+1.8
 UTF-8
 
 false
@@ -2081,7 +2081,7 @@ ${license.additional-notes}
 
 
 
-1.7
+1.8
 oracle
 
 

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 11/13: ISIS-1726: generalizes the logic that searches for @PersistenceCapable entities, to also take into account meta-annotations.

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit a5419e9f7cdbb8f71a06b02bf58427b84436c3d9
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Tue Sep 19 22:59:43 2017 +0100

ISIS-1726: generalizes the logic that searches for @PersistenceCapable 
entities, to also take into account meta-annotations.
---
 .../IsisComponentProvider.java | 37 --
 1 file changed, 28 insertions(+), 9 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/systemusinginstallers/IsisComponentProvider.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/systemusinginstallers/IsisComponentProvider.java
index 6616d68..6f599ed 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/systemusinginstallers/IsisComponentProvider.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/systemusinginstallers/IsisComponentProvider.java
@@ -19,17 +19,19 @@
 
 package org.apache.isis.core.runtime.systemusinginstallers;
 
+import java.lang.annotation.Annotation;
 import java.util.Collection;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
+import java.util.stream.Collectors;
+import java.util.stream.Stream;
 
 import javax.annotation.Nullable;
 import javax.jdo.annotations.PersistenceCapable;
 
 import com.google.common.base.Function;
 import com.google.common.base.Joiner;
-import com.google.common.base.Predicate;
 import com.google.common.collect.Iterables;
 import com.google.common.collect.Lists;
 import com.google.common.collect.Sets;
@@ -141,21 +143,20 @@ public abstract class IsisComponentProvider {
 
 final Reflections reflections = new Reflections(packages);
 final Set<Class> domainServiceTypes = 
reflections.getTypesAnnotatedWith(DomainService.class);
-final Set<Class> persistenceCapableTypes = 
reflections.getTypesAnnotatedWith(PersistenceCapable.class);
+final Set<Class> persistenceCapableTypes = 
findPersistenceCapableTypes(reflections);
 final Set<Class> fixtureScriptTypes = 
reflections.getSubTypesOf(FixtureScript.class);
 
 final Set<Class> mixinTypes = Sets.newHashSet();
 mixinTypes.addAll(reflections.getTypesAnnotatedWith(Mixin.class));
 final Set<Class> domainObjectTypes = 
reflections.getTypesAnnotatedWith(DomainObject.class);
 mixinTypes.addAll(
-Lists.newArrayList(Iterables.filter(domainObjectTypes, new 
Predicate<Class>() {
-@Override
-public boolean apply(@Nullable final Class input) {
-if(input == null) { return false; }
-final DomainObject annotation = 
input.getAnnotation(DomainObject.class);
-return annotation.nature() == Nature.MIXIN;
+domainObjectTypes.stream().filter(input -> {
+if (input == null) {
+return false;
 }
-}))
+final DomainObject annotation = 
input.getAnnotation(DomainObject.class);
+return annotation.nature() == Nature.MIXIN;
+}).collect(Collectors.toList())
 );
 
 registry.setDomainServiceTypes(domainServiceTypes);
@@ -164,6 +165,24 @@ public abstract class IsisComponentProvider {
 registry.setMixinTypes(mixinTypes);
 }
 
+private Set<Class> findPersistenceCapableTypes(final Reflections 
reflections) {
+
+Set<Class> pcSet = Sets.newLinkedHashSet();
+
+Set<Class> persistenceCapables = 
reflections.getTypesAnnotatedWith(PersistenceCapable.class);
+persistenceCapables.stream()
+.filter(x -> !x.isAnnotation())
+.forEach(pcSet::add);
+
+Stream<Class> pcMetaAnnotStream =
+(Stream)persistenceCapables.stream().filter(x -> 
x.isAnnotation());
+pcMetaAnnotStream.map(metaAnnot -> 
reflections.getTypesAnnotatedWith(metaAnnot).stream())
+.flatMap(x -> x)
+.filter(x -> !x.isAnnotation())
+.forEach(pcSet::add);
+
+return pcSet;
+}
 
 private void specifyServicesAndRegisteredEntitiesUsing(final AppManifest 
appManifest) {
 final Iterable packageNames = 
modulePackageNamesFrom(appManifest);

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 10/13: ISIS-1727: uses lambda in IsisSessionFactoryBuilder

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 5c81e1ccee1756d00acb415c8679ac43275f7b9c
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Tue Sep 19 22:56:54 2017 +0100

ISIS-1727: uses lambda in IsisSessionFactoryBuilder
---
 .../system/session/IsisSessionFactoryBuilder.java  | 25 ++
 1 file changed, 11 insertions(+), 14 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactoryBuilder.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactoryBuilder.java
index 3002b3f..913b869 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactoryBuilder.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactoryBuilder.java
@@ -199,22 +199,19 @@ public class IsisSessionFactoryBuilder {
 
 
 isisSessionFactory.doInSession(
-new Runnable() {
-@Override
-public void run() {
-try {
-specificationLoader.validateAndAssert();
-
-} catch (final MetaModelInvalidException ex) {
-// no need to use a higher level, such as 
error(...); the calling code will expose any metamodel
-// validation errors in their own particular 
way.
-if(LOG.isDebugEnabled()) {
-LOG.debug("Meta model invalid", ex);
-}
-IsisContext.setMetaModelInvalidException(ex);
+() -> {
+try {
+specificationLoader.validateAndAssert();
+
+} catch (final MetaModelInvalidException ex) {
+// no need to use a higher level, such as 
error(...); the calling code will expose any metamodel
+// validation errors in their own particular way.
+if(LOG.isDebugEnabled()) {
+LOG.debug("Meta model invalid", ex);
 }
-
+IsisContext.setMetaModelInvalidException(ex);
 }
+
 }
 );
 

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] branch dev/2.0.0/ISIS-1762-j8-utils created (now df25482)

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git.


  at df25482  ISIS-1762 fixing won't compile on eclipse

This branch includes the following new commits:

 new ccb0bc9  ISIS-1276: updates references for datanucleus.
 new 2d48766  ISIS-1276: updates core to compile under JDK 1.8 only
 new dd39ec6  ISIS-1276: updates applib, replaces references of 
TypesafeQuery to be instead JDOQLTypedQuery
 new 5565822  ISIS-1276: fixes compile issues in metamodel and runtime
 new f0900ad  ISIS-1276: fixes compile issue in specsupport
 new be40ecf  ISIS-1276: fixes algorithm for lookup of datastore id's, at 
least
 new 4ab0b54  ISIS-1723: removes jdo applib's Auditable interface and 
@Auditable annotation
 new bf3d034  ISIS-1724: removes the deprecated IsisJdoSupport in the jdo 
applib
 new 2abad13  ISIS-1725: requires that an AppManifest is supplied (used to 
obtain list of entities).
 new 5c81e1c  ISIS-1727: uses lambda in IsisSessionFactoryBuilder
 new a5419e9  ISIS-1726: generalizes the logic that searches for 
@PersistenceCapable entities, to also take into account meta-annotations.
 new a8b21e7  ISIS-1728: uses typesafe queries for helloworld
 new df25482  ISIS-1762 fixing won't compile on eclipse

The 13 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


-- 
To stop receiving notification emails like this one, please contact
['"commits@isis.apache.org" <commits@isis.apache.org>'].


[isis] 06/13: ISIS-1276: fixes algorithm for lookup of datastore id's, at least

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit be40ecfa06ac31d15cca66699f031b0a55f88b75
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:55:49 2017 +0100

ISIS-1276: fixes algorithm for lookup of datastore id's, at least
---
 .../persistence/spi/JdoObjectIdSerializer.java | 45 +++---
 1 file changed, 13 insertions(+), 32 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/persistence/spi/JdoObjectIdSerializer.java
 
b/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/persistence/spi/JdoObjectIdSerializer.java
index 48d4da9..ebb4d40 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/persistence/spi/JdoObjectIdSerializer.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/datanucleus/persistence/spi/JdoObjectIdSerializer.java
@@ -90,37 +90,14 @@ public final class JdoObjectIdSerializer {
 final DatastoreId dnOid = (DatastoreId) jdoOid;
 final Object keyValue = dnOid.getKeyAsObject();
 
-if(false) {
-
-//
-// 1.8.0 original handling, appending a prefix "L_" or whatever
-//
-// if required by user community, we could add a property in 
isis.properties to enable if requested.
-//
-if(keyValue instanceof String) {
-return "S" + SEPARATOR + keyValue;
-}
-if(keyValue instanceof Long) {
-return "L" + SEPARATOR + keyValue;
-}
-
-if(keyValue instanceof BigInteger) {
-return "B" + SEPARATOR + keyValue;
-}
-if(keyValue instanceof Integer) {
-return "I" + SEPARATOR + keyValue;
-}
-
-} else {
-if( keyValue instanceof String ||
-keyValue instanceof Long ||
-keyValue instanceof BigDecimal || // 1.8.0 did not 
support BigDecimal
-keyValue instanceof BigInteger ||
-keyValue instanceof Integer) {
-
-// no separator
-return "" + keyValue;
-}
+if( keyValue instanceof String ||
+keyValue instanceof Long ||
+keyValue instanceof BigDecimal || // 1.8.0 did not support 
BigDecimal
+keyValue instanceof BigInteger ||
+keyValue instanceof Integer) {
+
+// no separator
+return "" + keyValue;
 }
 }
 
@@ -201,7 +178,11 @@ public final class JdoObjectIdSerializer {
 // @javax.jdo.annotations.PersistenceCapable(identityType = 
IdentityType.DATASTORE)
 // for one of the common types (prettier handling)
 
-return idStr + "[OID]" + spec.getFullIdentifier();
+// in DN 4.1, we did this...
+// return idStr + "[OID]" + spec.getFullIdentifier();
+
+// in DN 5.1, we simply do this...
+return idStr;
 
 }
 }

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 04/13: ISIS-1276: fixes compile issues in metamodel and runtime

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 55658227cb1497c46c05dd85a9a53ec0ab5b12f5
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:29:13 2017 +0100

ISIS-1276: fixes compile issues in metamodel and runtime
---
 .../facets/object/parseable/ParserUtil.java|  2 +-
 .../value/vsp/ValueSemanticsProviderUtil.java  |  3 +--
 ...ionParameterAbstractTest_getId_and_getName.java |  6 ++---
 .../DataNucleusApplicationComponents.java  |  2 +-
 .../persistence/PersistenceSessionFactory.java |  2 +-
 .../CreateSchemaObjectFromClassMetadata.java   |  3 ++-
 .../service/support/IsisJdoSupportImpl.java| 27 +-
 7 files changed, 20 insertions(+), 25 deletions(-)

diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/parseable/ParserUtil.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/parseable/ParserUtil.java
index 3f70174..acc1105 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/parseable/ParserUtil.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/parseable/ParserUtil.java
@@ -43,7 +43,7 @@ public final class ParserUtil {
 public static Class> parserOrNull(final Class 
candidateClass, final String classCandidateName) {
 @SuppressWarnings("rawtypes")
 final Class type = candidateClass != null ? 
ClassUtil.implementingClassOrNull(candidateClass.getName(), Parser.class, 
FacetHolder.class) : null;
-return type != null ? type : 
ClassUtil.implementingClassOrNull(classCandidateName, Parser.class, 
FacetHolder.class);
+return type != null ? type : 
(Class)ClassUtil.implementingClassOrNull(classCandidateName, Parser.class, 
FacetHolder.class);
 }
 
 }
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/value/vsp/ValueSemanticsProviderUtil.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/value/vsp/ValueSemanticsProviderUtil.java
index f93ebe1..b34d5fe 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/value/vsp/ValueSemanticsProviderUtil.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/object/value/vsp/ValueSemanticsProviderUtil.java
@@ -24,7 +24,6 @@ import com.google.common.base.Strings;
 import org.apache.isis.applib.adapters.ValueSemanticsProvider;
 import org.apache.isis.core.commons.config.IsisConfiguration;
 import org.apache.isis.core.commons.lang.ClassUtil;
-import org.apache.isis.core.commons.lang.StringExtensions;
 import org.apache.isis.core.metamodel.facetapi.FacetHolder;
 
 public final class ValueSemanticsProviderUtil {
@@ -45,7 +44,7 @@ public final class ValueSemanticsProviderUtil {
 public static Class> 
valueSemanticsProviderOrNull(final Class candidateClass, final String 
classCandidateName) {
 @SuppressWarnings("rawtypes")
 final Class clazz = candidateClass != null ? 
ClassUtil.implementingClassOrNull(candidateClass.getName(), 
ValueSemanticsProvider.class, FacetHolder.class) : null;
-return clazz != null ? clazz : 
ClassUtil.implementingClassOrNull(classCandidateName, 
ValueSemanticsProvider.class, FacetHolder.class);
+return clazz != null ? clazz : 
(Class)ClassUtil.implementingClassOrNull(classCandidateName, 
ValueSemanticsProvider.class, FacetHolder.class);
 }
 
 }
diff --git 
a/core/metamodel/src/test/java/org/apache/isis/core/metamodel/specloader/specimpl/ObjectActionParameterAbstractTest_getId_and_getName.java
 
b/core/metamodel/src/test/java/org/apache/isis/core/metamodel/specloader/specimpl/ObjectActionParameterAbstractTest_getId_and_getName.java
index 3985ca0..6843e26 100644
--- 
a/core/metamodel/src/test/java/org/apache/isis/core/metamodel/specloader/specimpl/ObjectActionParameterAbstractTest_getId_and_getName.java
+++ 
b/core/metamodel/src/test/java/org/apache/isis/core/metamodel/specloader/specimpl/ObjectActionParameterAbstractTest_getId_and_getName.java
@@ -164,7 +164,7 @@ public class 
ObjectActionParameterAbstractTest_getId_and_getName {
 one(actionParamPeer).getFacet(NamedFacet.class);
 will(returnValue(null));
 
-
one(parentAction).getParameters((Filter) 
with(anything()));
+
one(parentAction).getParameters(with((Filter)anything()));
 will(returnValue(Lists.newArrayList(objectActionParameter)));
 }
 });
@@ -183,7 +183,7 @@ public class 
ObjectActionParameterAbstractTest_getId_and_getName {
 one(actionParamPeer).getFacet(NamedFacet.class);
 will(returnValue(null));
 
-
one(parentAction).getParameters((Filter) 
with(any

[isis] 02/13: ISIS-1276: updates core to compile under JDK 1.8 only

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 2d487666adf53844b8a1bf20fc5eebaeef63a5dd
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:16:56 2017 +0100

ISIS-1276: updates core to compile under JDK 1.8 only
---
 core/pom.xml | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/core/pom.xml b/core/pom.xml
index 8aec65b..9f30b75 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -57,8 +57,8 @@
 **/*IntegrationTest.java
 
 
-1.7
-1.7
+1.8
+1.8
 UTF-8
 
 false
@@ -2081,7 +2081,7 @@ ${license.additional-notes}
 
 
 
-1.7
+1.8
 oracle
 
 

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 11/13: ISIS-1726: generalizes the logic that searches for @PersistenceCapable entities, to also take into account meta-annotations.

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit a5419e9f7cdbb8f71a06b02bf58427b84436c3d9
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Tue Sep 19 22:59:43 2017 +0100

ISIS-1726: generalizes the logic that searches for @PersistenceCapable 
entities, to also take into account meta-annotations.
---
 .../IsisComponentProvider.java | 37 --
 1 file changed, 28 insertions(+), 9 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/systemusinginstallers/IsisComponentProvider.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/systemusinginstallers/IsisComponentProvider.java
index 6616d68..6f599ed 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/systemusinginstallers/IsisComponentProvider.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/systemusinginstallers/IsisComponentProvider.java
@@ -19,17 +19,19 @@
 
 package org.apache.isis.core.runtime.systemusinginstallers;
 
+import java.lang.annotation.Annotation;
 import java.util.Collection;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
+import java.util.stream.Collectors;
+import java.util.stream.Stream;
 
 import javax.annotation.Nullable;
 import javax.jdo.annotations.PersistenceCapable;
 
 import com.google.common.base.Function;
 import com.google.common.base.Joiner;
-import com.google.common.base.Predicate;
 import com.google.common.collect.Iterables;
 import com.google.common.collect.Lists;
 import com.google.common.collect.Sets;
@@ -141,21 +143,20 @@ public abstract class IsisComponentProvider {
 
 final Reflections reflections = new Reflections(packages);
 final Set<Class> domainServiceTypes = 
reflections.getTypesAnnotatedWith(DomainService.class);
-final Set<Class> persistenceCapableTypes = 
reflections.getTypesAnnotatedWith(PersistenceCapable.class);
+final Set<Class> persistenceCapableTypes = 
findPersistenceCapableTypes(reflections);
 final Set<Class> fixtureScriptTypes = 
reflections.getSubTypesOf(FixtureScript.class);
 
 final Set<Class> mixinTypes = Sets.newHashSet();
 mixinTypes.addAll(reflections.getTypesAnnotatedWith(Mixin.class));
 final Set<Class> domainObjectTypes = 
reflections.getTypesAnnotatedWith(DomainObject.class);
 mixinTypes.addAll(
-Lists.newArrayList(Iterables.filter(domainObjectTypes, new 
Predicate<Class>() {
-@Override
-public boolean apply(@Nullable final Class input) {
-if(input == null) { return false; }
-final DomainObject annotation = 
input.getAnnotation(DomainObject.class);
-return annotation.nature() == Nature.MIXIN;
+domainObjectTypes.stream().filter(input -> {
+if (input == null) {
+return false;
 }
-}))
+final DomainObject annotation = 
input.getAnnotation(DomainObject.class);
+return annotation.nature() == Nature.MIXIN;
+}).collect(Collectors.toList())
 );
 
 registry.setDomainServiceTypes(domainServiceTypes);
@@ -164,6 +165,24 @@ public abstract class IsisComponentProvider {
 registry.setMixinTypes(mixinTypes);
 }
 
+private Set<Class> findPersistenceCapableTypes(final Reflections 
reflections) {
+
+Set<Class> pcSet = Sets.newLinkedHashSet();
+
+Set<Class> persistenceCapables = 
reflections.getTypesAnnotatedWith(PersistenceCapable.class);
+persistenceCapables.stream()
+.filter(x -> !x.isAnnotation())
+.forEach(pcSet::add);
+
+Stream<Class> pcMetaAnnotStream =
+(Stream)persistenceCapables.stream().filter(x -> 
x.isAnnotation());
+pcMetaAnnotStream.map(metaAnnot -> 
reflections.getTypesAnnotatedWith(metaAnnot).stream())
+.flatMap(x -> x)
+.filter(x -> !x.isAnnotation())
+.forEach(pcSet::add);
+
+return pcSet;
+}
 
 private void specifyServicesAndRegisteredEntitiesUsing(final AppManifest 
appManifest) {
 final Iterable packageNames = 
modulePackageNamesFrom(appManifest);

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 12/13: ISIS-1728: uses typesafe queries for helloworld

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit a8b21e7b6363f5e8d9289bbcb9ea3bdc7f0d45f5
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Tue Sep 19 23:02:07 2017 +0100

ISIS-1728: uses typesafe queries for helloworld
---
 .../main/java/domainapp/dom/impl/HelloWorldObject.java  | 17 ++---
 .../main/java/domainapp/dom/impl/HelloWorldObjects.java | 15 ---
 2 files changed, 14 insertions(+), 18 deletions(-)

diff --git 
a/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObject.java
 
b/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObject.java
index 40708dd..90ad57a 100644
--- 
a/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObject.java
+++ 
b/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObject.java
@@ -42,27 +42,19 @@ import org.apache.isis.applib.services.title.TitleService;
 
 import lombok.AccessLevel;
 
-@javax.jdo.annotations.PersistenceCapable(identityType = 
IdentityType.DATASTORE, schema = "helloworld" )
+@javax.jdo.annotations.PersistenceCapable(identityType = 
IdentityType.DATASTORE,schema = "helloworld" )
 @javax.jdo.annotations.DatastoreIdentity(strategy = 
IdGeneratorStrategy.IDENTITY, column = "id")
 @javax.jdo.annotations.Version(strategy= VersionStrategy.DATE_TIME, column 
="version")
-@javax.jdo.annotations.Queries({
-@javax.jdo.annotations.Query(
-name = "findByName",
-value = "SELECT "
-+ "FROM domainapp.dom.impl.HelloWorldObject "
-+ "WHERE name.indexOf(:name) >= 0 ")
-})
-@javax.jdo.annotations.Unique(name="HelloWorldObject_name_UNQ", members = 
{"name"})
-@DomainObject(auditing = Auditing.ENABLED)
+@DomainObject(auditing = Auditing.ENABLED, editing = Editing.DISABLED)
 @DomainObjectLayout()  // trigger events etc.
 @lombok.RequiredArgsConstructor(staticName = "create")
 @lombok.Getter @lombok.Setter
 public class HelloWorldObject implements Comparable {
 
 
+@javax.jdo.annotations.Unique
 @javax.jdo.annotations.Column(allowsNull = "false", length = 40)
 @lombok.NonNull
-@Property(editing = Editing.DISABLED)
 @Title(prepend = "Object: ")
 private String name;
 
@@ -102,14 +94,17 @@ public class HelloWorldObject implements 
Comparable {
 
 //region > injected services
 @javax.inject.Inject
+@javax.jdo.annotations.NotPersistent
 @lombok.Getter(AccessLevel.NONE) @lombok.Setter(AccessLevel.NONE)
 RepositoryService repositoryService;
 
 @javax.inject.Inject
+@javax.jdo.annotations.NotPersistent
 @lombok.Getter(AccessLevel.NONE) @lombok.Setter(AccessLevel.NONE)
 TitleService titleService;
 
 @javax.inject.Inject
+@javax.jdo.annotations.NotPersistent
 @lombok.Getter(AccessLevel.NONE) @lombok.Setter(AccessLevel.NONE)
 MessageService messageService;
 //endregion
diff --git 
a/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObjects.java
 
b/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObjects.java
index a8c4d39..fbb10a8 100644
--- 
a/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObjects.java
+++ 
b/example/application/helloworld/src/main/java/domainapp/dom/impl/HelloWorldObjects.java
@@ -28,7 +28,7 @@ import org.apache.isis.applib.annotation.Parameter;
 import org.apache.isis.applib.annotation.ParameterLayout;
 import org.apache.isis.applib.annotation.RestrictTo;
 import org.apache.isis.applib.annotation.SemanticsOf;
-import org.apache.isis.applib.query.QueryDefault;
+import org.apache.isis.applib.services.jdosupport.IsisJdoSupport;
 import org.apache.isis.applib.services.registry.ServiceRegistry2;
 import org.apache.isis.applib.services.repository.RepositoryService;
 
@@ -50,17 +50,15 @@ public class HelloWorldObjects {
 @Action(semantics = SemanticsOf.SAFE)
 @MemberOrder(sequence = "2")
 public List findByName(final String name) {
-return repositoryService.allMatches(
-new QueryDefault<>(
-HelloWorldObject.class,
-"findByName",
-"name", name));
+return isisJdoSupport.executeQuery(HelloWorldObject.class,
+QHelloWorldObject.candidate().name.startsWith(name));
 }
 
 @Action(semantics = SemanticsOf.SAFE, restrictTo = RestrictTo.PROTOTYPING)
 @MemberOrder(sequence = "3")
 public List listAll() {
-return repositoryService.allInstances(HelloWorldObject.class);
+return isisJdoSupport.newTypesafeQuery(

[isis] 05/13: ISIS-1276: fixes compile issue in specsupport

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit f0900adc382f0ee2e27889f98a2cf4c0f5bada0a
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:34:29 2017 +0100

ISIS-1276: fixes compile issue in specsupport
---
 .../isis/core/specsupport/scenarios/DomainServiceProviderMockery.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/core/specsupport/src/main/java/org/apache/isis/core/specsupport/scenarios/DomainServiceProviderMockery.java
 
b/core/specsupport/src/main/java/org/apache/isis/core/specsupport/scenarios/DomainServiceProviderMockery.java
index 4d4d2cd..30a294c 100644
--- 
a/core/specsupport/src/main/java/org/apache/isis/core/specsupport/scenarios/DomainServiceProviderMockery.java
+++ 
b/core/specsupport/src/main/java/org/apache/isis/core/specsupport/scenarios/DomainServiceProviderMockery.java
@@ -67,7 +67,7 @@ class DomainServiceProviderMockery implements 
DomainServiceProvider {
 }
 });
 
-
allowing(mockContainer).persistIfNotAlready(with(anything()));
+
allowing(mockContainer).persistIfNotAlready(with(any(Object.class)));
 }
 });
 }

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 01/13: ISIS-1276: updates references for datanucleus.

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit ccb0bc90a5174f3b31f8797b90ce83f0b93b1add
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:13:20 2017 +0100

ISIS-1276: updates references for datanucleus.

Also updated org.incode:incode-build to 3-SNAPSHOT, and 
java-mavenmixin-datanucleus to 0.0.5-SNAPSHOT
---
 core/applib/pom.xml| 39 ++
 core/pom.xml   | 19 -
 core/unittestsupport/pom.xml   |  5 ++---
 example/application/helloworld/pom.xml |  4 ++--
 example/application/simpleapp/pom.xml  |  8 +++
 5 files changed, 19 insertions(+), 56 deletions(-)

diff --git a/core/applib/pom.xml b/core/applib/pom.xml
index c048c8c..3776e8f 100644
--- a/core/applib/pom.xml
+++ b/core/applib/pom.xml
@@ -51,41 +51,6 @@
 
 
 
-
-
-
-
-org.eclipse.m2e
-lifecycle-mapping
-1.0.0
-
-
-
-
-
-
-org.datanucleus
-
-
-datanucleus-maven-plugin
-
-
-[4.0.0-release,)
-
-
-enhance
-
-
-
-
-
-
-
-
-
-
-
-
 
 
 
@@ -128,8 +93,8 @@
 
 
 
-javax.jdo
-jdo-api
+org.datanucleus
+javax.jdo
 
 
 
diff --git a/core/pom.xml b/core/pom.xml
index d898beb..8aec65b 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -84,14 +84,13 @@
 [6] 
https://github.com/moment/moment/blob/develop/LICENSE
 
 
-3.1
+3.2.0-m7
 
-4.1.7
-4.1.1
-4.0.5
-4.1.9
-
-
4.1.0-release
+5.1.2
+5.1.2
+5.0.2
+5.1.2
+
5.1.0-release

-
4.0.2
+
5.0.2
 
 1.2.6
 
@@ -1950,8 +1949,8 @@ ${license.additional-notes}
 
 
 
-javax.jdo
-jdo-api
+org.datanucleus
+javax.jdo
 ${jdo-api.version}
 
 
diff --git a/core/unittestsupport/pom.xml b/core/unittestsupport/pom.xml
index 2c84d64..6783db0 100644
--- a/core/unittestsupport/pom.xml
+++ b/core/unittestsupport/pom.xml
@@ -56,9 +56,8 @@

 
 
-javax.jdo
-jdo-api
-${jdo-api.version}
+org.datanucleus
+javax.jdo
 true
 
 
diff --git a/example/application/helloworld/pom.xml 
b/example/application/helloworld/pom.xml
index 646de10..193ca67 100644
--- a/example/application/helloworld/pom.xml
+++ b/example/application/helloworld/pom.xml
@@ -24,7 +24,7 @@
 
 org.incode
 incode-build
-2
+3-SNAPSHOT
 
 
 org.apache.isis.example.application
@@ -42,7 +42,7 @@
 
 1.8
 1.8
-
+
-parameters
 
 UTF-8
 
UTF-8
diff --git a/example/application/simpleapp/pom.xml 
b/example/application/simpleapp/pom.xml
index 9ee473a..fd6dbee 100644
--- a/example/application/simpleapp/pom.xml
+++ b/example/application/simpleapp/pom.xml
@@ -24,7 +24,7 @@
 
 org.incode
 incode-build
-2
+3-SNAPSHOT
 
 
 org.apache.isis.example.application
@@ -44,9 +44,9 @@
 
 1.16.18
 
-1.7
-1.7
-
+1.8
+1.8
+
-parameters
 
 UTF-8
 
UTF-8

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 03/13: ISIS-1276: updates applib, replaces references of TypesafeQuery to be instead JDOQLTypedQuery

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit dd39ec69f2c5e36e52b6fe283b22058caca5d347
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Mon Sep 18 22:17:54 2017 +0100

ISIS-1276: updates applib, replaces references of TypesafeQuery to be 
instead JDOQLTypedQuery
---
 .../org/apache/isis/applib/services/jdosupport/IsisJdoSupport.java | 7 +++
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/services/jdosupport/IsisJdoSupport.java
 
b/core/applib/src/main/java/org/apache/isis/applib/services/jdosupport/IsisJdoSupport.java
index 4ca5c10..75a4e0f 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/services/jdosupport/IsisJdoSupport.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/services/jdosupport/IsisJdoSupport.java
@@ -23,10 +23,9 @@ import java.util.Collection;
 import java.util.List;
 import java.util.Map;
 
+import javax.jdo.JDOQLTypedQuery;
 import javax.jdo.PersistenceManager;
-
-import org.datanucleus.query.typesafe.BooleanExpression;
-import org.datanucleus.query.typesafe.TypesafeQuery;
+import javax.jdo.query.BooleanExpression;
 
 import org.apache.isis.applib.annotation.Programmatic;
 
@@ -132,5 +131,5 @@ public interface IsisJdoSupport {
  * 
  */
 @Programmatic
- TypesafeQuery newTypesafeQuery(Class cls);
+ JDOQLTypedQuery newTypesafeQuery(Class cls);
 }

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 10/13: ISIS-1727: uses lambda in IsisSessionFactoryBuilder

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 5c81e1ccee1756d00acb415c8679ac43275f7b9c
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Tue Sep 19 22:56:54 2017 +0100

ISIS-1727: uses lambda in IsisSessionFactoryBuilder
---
 .../system/session/IsisSessionFactoryBuilder.java  | 25 ++
 1 file changed, 11 insertions(+), 14 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactoryBuilder.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactoryBuilder.java
index 3002b3f..913b869 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactoryBuilder.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/session/IsisSessionFactoryBuilder.java
@@ -199,22 +199,19 @@ public class IsisSessionFactoryBuilder {
 
 
 isisSessionFactory.doInSession(
-new Runnable() {
-@Override
-public void run() {
-try {
-specificationLoader.validateAndAssert();
-
-} catch (final MetaModelInvalidException ex) {
-// no need to use a higher level, such as 
error(...); the calling code will expose any metamodel
-// validation errors in their own particular 
way.
-if(LOG.isDebugEnabled()) {
-LOG.debug("Meta model invalid", ex);
-}
-IsisContext.setMetaModelInvalidException(ex);
+() -> {
+try {
+specificationLoader.validateAndAssert();
+
+} catch (final MetaModelInvalidException ex) {
+// no need to use a higher level, such as 
error(...); the calling code will expose any metamodel
+// validation errors in their own particular way.
+if(LOG.isDebugEnabled()) {
+LOG.debug("Meta model invalid", ex);
 }
-
+IsisContext.setMetaModelInvalidException(ex);
 }
+
 }
 );
 

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 09/13: ISIS-1725: requires that an AppManifest is supplied (used to obtain list of entities).

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 2abad13bf00cc69e02038e6f83e1b8640a84504c
Author: Dan Haywood <d...@haywood-associates.co.uk>
AuthorDate: Tue Sep 19 22:55:48 2017 +0100

ISIS-1725: requires that an AppManifest is supplied (used to obtain list of 
entities).
---
 .../persistence/PersistenceSessionFactory.java |  2 +-
 .../objectstore/jdo/service/RegisterEntities.java  | 96 ++
 2 files changed, 9 insertions(+), 89 deletions(-)

diff --git 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionFactory.java
 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionFactory.java
index 8a89c8a..4be046c 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionFactory.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/core/runtime/system/persistence/PersistenceSessionFactory.java
@@ -93,7 +93,7 @@ public class PersistenceSessionFactory implements 
ApplicationScopedComponent, Fi
 final Map<String, String> datanucleusProps = 
dataNucleusConfig.asMap();
 addDataNucleusPropertiesIfRequired(datanucleusProps);
 
-final RegisterEntities registerEntities = new 
RegisterEntities(configuration.asMap(), specificationLoader);
+final RegisterEntities registerEntities = new 
RegisterEntities(specificationLoader);
 final Set classesToBePersisted = 
registerEntities.getEntityTypes();
 
 applicationComponents = new 
DataNucleusApplicationComponents(jdoObjectstoreConfig, specificationLoader,
diff --git 
a/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/service/RegisterEntities.java
 
b/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/service/RegisterEntities.java
index 538b5b1..a83b115 100644
--- 
a/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/service/RegisterEntities.java
+++ 
b/core/runtime/src/main/java/org/apache/isis/objectstore/jdo/service/RegisterEntities.java
@@ -18,23 +18,13 @@
  */
 package org.apache.isis.objectstore.jdo.service;
 
-import java.util.Collections;
 import java.util.List;
-import java.util.Map;
 import java.util.Set;
 
-import javax.jdo.annotations.PersistenceCapable;
-
-import com.google.common.base.Function;
 import com.google.common.base.Joiner;
-import com.google.common.base.Predicate;
-import com.google.common.base.Splitter;
-import com.google.common.base.Strings;
-import com.google.common.collect.Iterables;
 import com.google.common.collect.Lists;
 import com.google.common.collect.Sets;
 
-import org.reflections.Reflections;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -45,7 +35,11 @@ public class RegisterEntities {
 
 @SuppressWarnings("unused")
 private final static Logger LOG = 
LoggerFactory.getLogger(RegisterEntities.class);
-
+
+/**
+ * @deprecated - no longer used; instead an AppManifest must be specified.
+ */
+@Deprecated
 public final static String PACKAGE_PREFIX_KEY = 
"isis.persistor.datanucleus.RegisterEntities.packagePrefix";
 
 // //
@@ -60,13 +54,13 @@ public class RegisterEntities {
 }
 //endregion
 
-public RegisterEntities(final Map<String, String> configuration, final 
SpecificationLoader specificationLoader) {
+public RegisterEntities(final SpecificationLoader specificationLoader) {
 this.specificationLoader = specificationLoader;
 
 Set<Class> persistenceCapableTypes = 
AppManifest.Registry.instance().getPersistenceCapableTypes();
 
 if(persistenceCapableTypes == null) {
-persistenceCapableTypes = 
searchForPersistenceCapables(configuration);
+throw new IllegalStateException("AppManifest is required");
 }
 
 final List classNamesNotEnhanced = Lists.newArrayList();
@@ -86,88 +80,14 @@ public class RegisterEntities {
 }
 }
 
-/**
- * only called if no appManifest
- */
-Set<Class> searchForPersistenceCapables(final Map<String, String> 
configuration) {
-
-final String packagePrefixes = lookupPackagePrefixes(configuration);
-
-final Set<Class> persistenceCapableTypes = Sets.newLinkedHashSet();
-final List domPackages = parseDomPackages(packagePrefixes);
-for (final String packageName : domPackages) {
-Reflections reflections = new Reflections(packageName);
-final Set<Class> entityTypesInPackage =
-
reflections.getTypesAnnotatedWith(PersistenceCapable.class);
-
-if(!entitiesIn(entityTypesInPackage)) {
-throw new IllegalArgumentException(String.format(
-"

[isis] 13/13: ISIS-1762 fixing won't compile on eclipse

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit df25482c8528d36e8f926ac7c1a4fe5069b9d5cd
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Fri Oct 27 10:14:04 2017 +0200

ISIS-1762 fixing won't compile on eclipse
---
 .../viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
 
b/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
index 08205b2..da2cb46 100644
--- 
a/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
+++ 
b/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
@@ -53,7 +53,7 @@ public class LowestCommonSuperclassClosureTest {
 assertLowestCommonOfListIs(listOf(Lion.class, Lion.class), Lion.class);
 }
 
-private static void assertLowestCommonOfListIs(List<Class> list, Class expected) {
+private static void assertLowestCommonOfListIs(List<Class> list, 
Class expected) {
 EntityCollectionModel.LowestCommonSuperclassClosure closure = new 
EntityCollectionModel.LowestCommonSuperclassClosure();
 IterableExtensions.fold(list, closure);
 assertThat(closure.getLowestCommonSuperclass(), 
IsisMatchers.classEqualTo(expected));

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] 01/01: ISIS-1762 fixing won't compile on eclipse

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 4df916d4670084176c52247b571709c4f568ab03
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Fri Oct 27 11:49:13 2017 +0200

ISIS-1762 fixing won't compile on eclipse
---
 .../viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
 
b/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
index 08205b2..da2cb46 100644
--- 
a/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
+++ 
b/core/viewer-wicket-model/src/test/java/org/apache/isis/viewer/wicket/model/models/LowestCommonSuperclassClosureTest.java
@@ -53,7 +53,7 @@ public class LowestCommonSuperclassClosureTest {
 assertLowestCommonOfListIs(listOf(Lion.class, Lion.class), Lion.class);
 }
 
-private static void assertLowestCommonOfListIs(List<Class> list, Class expected) {
+private static void assertLowestCommonOfListIs(List<Class> list, 
Class expected) {
 EntityCollectionModel.LowestCommonSuperclassClosure closure = new 
EntityCollectionModel.LowestCommonSuperclassClosure();
 IterableExtensions.fold(list, closure);
 assertThat(closure.getLowestCommonSuperclass(), 
IsisMatchers.classEqualTo(expected));

-- 
To stop receiving notification emails like this one, please contact
"commits@isis.apache.org" <commits@isis.apache.org>.


[isis] branch dev/2.0.0/ISIS-1762-j8-utils created (now 4df916d)

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git.


  at 4df916d  ISIS-1762 fixing won't compile on eclipse

This branch includes the following new commits:

 new 4df916d  ISIS-1762 fixing won't compile on eclipse

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


-- 
To stop receiving notification emails like this one, please contact
['"commits@isis.apache.org" <commits@isis.apache.org>'].


[isis] 01/01: ISIS-1740 initial commit of prototype

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1740-where-am-i
in repository https://gitbox.apache.org/repos/asf/isis.git

commit 38a81da3c63096c523d0c59c276a4efad1d64ba0
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Fri Oct 27 15:34:55 2017 +0200

ISIS-1740 initial commit of prototype
---
 .../org/apache/isis/applib/annotation/Parent.java  |  34 ++
 .../metamodel/util/pchain/CachingParentChain.java  |  66 +++
 .../core/metamodel/util/pchain/ParentChain.java|  99 
 .../metamodel/util/pchain/SimpleParentChain.java   |  75 +
 .../isis/core/metamodel/util/pchain/SoftCache.java | 124 +
 .../model/models/whereami/WhereAmIModel.java   |  38 +++
 .../models/whereami/WhereAmIModelDefault.java  |  68 +++
 .../viewer/wicket/ui/pages/entity/EntityPage.css   |  29 +
 .../viewer/wicket/ui/pages/entity/EntityPage.html  |   7 +-
 .../viewer/wicket/ui/pages/entity/EntityPage.java  |  68 ---
 10 files changed, 594 insertions(+), 14 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/annotation/Parent.java 
b/core/applib/src/main/java/org/apache/isis/applib/annotation/Parent.java
new file mode 100644
index 000..6e4a7d8
--- /dev/null
+++ b/core/applib/src/main/java/org/apache/isis/applib/annotation/Parent.java
@@ -0,0 +1,34 @@
+/* 
+ * 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.annotation;
+
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+/**
+ * Tells the framework which method or field to use in order to construct a 
navigable chain of
+ * parent domain object instances. This annotation can only be used once per 
class declaration. 
+ * 
+ */
+@Retention(RetentionPolicy.RUNTIME)
+@Target({ElementType.FIELD, ElementType.METHOD})
+public @interface Parent {
+}
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/util/pchain/CachingParentChain.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/util/pchain/CachingParentChain.java
new file mode 100644
index 000..630e928
--- /dev/null
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/util/pchain/CachingParentChain.java
@@ -0,0 +1,66 @@
+/*
+ * 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.core.metamodel.util.pchain;
+
+import java.lang.invoke.MethodHandle;
+import java.lang.invoke.MethodHandles;
+import java.lang.reflect.Method;
+
+class CachingParentChain extends SimpleParentChain {
+
+   private final SoftCache<Class, MethodHandle> cache = new 
SoftCache<>();
+
+   @Override
+   public Object parentOf(Object node) {
+   if(node==null)
+   return null;
+   
+   final MethodHandle mh = cache.computeIfAbsent(node.getClass(), 
+   key->{
+   try {
+   return methodHandleOf(node);
+   } catch (IllegalAccessException e) {
+   e.printStackTrace()

[isis] branch dev/2.0.0/ISIS-1740-where-am-i created (now 38a81da)

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch dev/2.0.0/ISIS-1740-where-am-i
in repository https://gitbox.apache.org/repos/asf/isis.git.


  at 38a81da  ISIS-1740 initial commit of prototype

This branch includes the following new commits:

 new 38a81da  ISIS-1740 initial commit of prototype

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


-- 
To stop receiving notification emails like this one, please contact
['"commits@isis.apache.org" <commits@isis.apache.org>'].


[isis] branch dev/2.0.0/ISIS-1762-j8-utils updated: ISIS-1762 added Reflect and NullSafe, reviewing o.a.i.c.commons

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1762-j8-utils
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/dev/2.0.0/ISIS-1762-j8-utils 
by this push:
 new 07e362e  ISIS-1762 added Reflect and NullSafe, reviewing 
o.a.i.c.commons
07e362e is described below

commit 07e362e2b507d80e0eae9abf303cc7a2bbef18e7
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Fri Oct 27 15:25:23 2017 +0200

ISIS-1762 added Reflect and NullSafe, reviewing o.a.i.c.commons
---
 .../core/commons/exceptions/ExceptionUtils.java|  14 +-
 .../isis/core/commons/lang/ArrayExtensions.java|  11 +-
 .../isis/core/commons/lang/ClassPredicates.java|   1 -
 .../isis/core/commons/lang/MethodExtensions.java   |   2 -
 .../apache/isis/core/commons/lang/NullSafe.java| 129 
 .../apache/isis/core/commons/lang/Nullable.java|   7 +
 .../isis/core/commons/lang/StringPredicates.java   |   1 -
 .../isis/core/commons/reflection/Reflect.java  | 167 +
 8 files changed, 317 insertions(+), 15 deletions(-)

diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/commons/exceptions/ExceptionUtils.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/commons/exceptions/ExceptionUtils.java
index 376caf5..1b313c6 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/commons/exceptions/ExceptionUtils.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/commons/exceptions/ExceptionUtils.java
@@ -26,6 +26,8 @@ import java.sql.SQLException;
 import java.util.ArrayList;
 import java.util.List;
 
+import org.apache.isis.core.commons.reflection.Reflect;
+
 /**
  * Provides utilities for manipulating and examining 
  * Throwable objects.
@@ -67,7 +69,7 @@ public class ExceptionUtils {
 static {
 Method causeMethod;
 try {
-causeMethod = Throwable.class.getMethod("getCause", null);
+causeMethod = Throwable.class.getMethod("getCause", 
Reflect.emptyClasses);
 } catch (Exception e) {
 causeMethod = null;
 }
@@ -243,10 +245,10 @@ public class ExceptionUtils {
 return true;
 }
 
-Class cls = throwable.getClass();
+Class cls = throwable.getClass();
 for (final String causeMethodName : CAUSE_METHOD_NAMES) {
 try {
-Method method = cls.getMethod(causeMethodName, null);
+Method method = cls.getMethod(causeMethodName, 
Reflect.emptyClasses);
 if (method != null && 
Throwable.class.isAssignableFrom(method.getReturnType())) {
 return true;
 }
@@ -287,7 +289,7 @@ public class ExceptionUtils {
  * @return the array of throwables, never null
  */
 public static Throwable[] getThrowables(Throwable throwable) {
-List list = getThrowableList(throwable);
+List list = getThrowableList(throwable);
 return (Throwable[]) list.toArray(new Throwable[list.size()]);
 }
 
@@ -310,8 +312,8 @@ public class ExceptionUtils {
  * @return the list of throwables, never null
  * @since Commons Lang 2.2
  */
-public static List getThrowableList(Throwable throwable) {
-List list = new ArrayList();
+public static List getThrowableList(Throwable throwable) {
+List list = new ArrayList();
 while (throwable != null && list.contains(throwable) == false) {
 list.add(throwable);
 throwable = ExceptionUtils.getCause(throwable);
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/commons/lang/ArrayExtensions.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/commons/lang/ArrayExtensions.java
index 26bb45c..4e20585 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/commons/lang/ArrayExtensions.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/commons/lang/ArrayExtensions.java
@@ -22,15 +22,14 @@ package org.apache.isis.core.commons.lang;
 import java.lang.reflect.Array;
 import java.lang.reflect.Constructor;
 import java.lang.reflect.InvocationTargetException;
-import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
 
-import com.google.common.collect.Lists;
-
 import org.apache.isis.core.commons.exceptions.IsisException;
 
+import com.google.common.collect.Lists;
+
 public final class ArrayExtensions {
 
 private ArrayExtensions() {
@@ -72,7 +71,8 @@ public final class ArrayExtensions {
 return converted;
 }
 
-public static  T[] combine(final T[]... arrays) {
+@SafeVarargs
+   public static  T[] combine(final T[]... arrays) {
 final List combinedList = Lists.newArrayList();
 for (final T[] array : arrays) {
 Collections.addAll(combinedList, array);
@@ -93,7 +93,8 @@ public fin

[isis] branch dev/2.0.0/ISIS-1740-where-am-i updated: ISIS-1740 refactored method names, added javadoc

2017-10-27 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch dev/2.0.0/ISIS-1740-where-am-i
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/dev/2.0.0/ISIS-1740-where-am-i 
by this push:
 new 2132cba  ISIS-1740 refactored method names, added javadoc
2132cba is described below

commit 2132cba2fa6beb6b3f0ed42865a016675b70534e
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Fri Oct 27 16:03:36 2017 +0200

ISIS-1740 refactored method names, added javadoc
---
 .../model/models/whereami/WhereAmIModel.java   | 28 ++
 .../models/whereami/WhereAmIModelDefault.java  | 24 +--
 .../viewer/wicket/ui/pages/entity/EntityPage.java  |  4 ++--
 3 files changed, 38 insertions(+), 18 deletions(-)

diff --git 
a/core/viewer-wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/whereami/WhereAmIModel.java
 
b/core/viewer-wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/whereami/WhereAmIModel.java
index 7ecfba0..fdc11f2 100644
--- 
a/core/viewer-wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/whereami/WhereAmIModel.java
+++ 
b/core/viewer-wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/whereami/WhereAmIModel.java
@@ -23,16 +23,36 @@ import java.util.stream.Stream;
 
 import org.apache.isis.viewer.wicket.model.models.EntityModel;
 
+/**
+ * Represents a navigable chain of parent nodes starting at the current node. 
+ * 
+ * @author a.hu...@corax.at
+ * 
+ * @since 2.0.0
+ *
+ */
 public interface WhereAmIModel {
 
-   public static WhereAmIModel of(EntityModel endOfChain) {
-   return new WhereAmIModelDefault(endOfChain);
+   public static WhereAmIModel of(EntityModel startOfChain) {
+   return new WhereAmIModelDefault(startOfChain);
}
 
+   /**
+* The navigable parent chain requires a minimum length of 2 in order 
to be shown.
+* @return whether the where-am-I hint should be shown or hidden
+*/
public boolean isShowWhereAmI();

-   public Stream streamParentChain();
+   /**
+* Streams the linked nodes of this model's navigable parent chain in 
reverse order.
+* @return reversed order stream of linked parent nodes, which does not 
include the start node
+*/
+   public Stream streamParentChainReversed();

-   public EntityModel getEndOfChain();
+   /**
+*  
+* @return the immutable start node of the navigable parent chain
+*/
+   public EntityModel getStartOfChain();

 }
diff --git 
a/core/viewer-wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/whereami/WhereAmIModelDefault.java
 
b/core/viewer-wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/whereami/WhereAmIModelDefault.java
index b3f6679..955c2db 100644
--- 
a/core/viewer-wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/whereami/WhereAmIModelDefault.java
+++ 
b/core/viewer-wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/whereami/WhereAmIModelDefault.java
@@ -28,32 +28,32 @@ import 
org.apache.isis.viewer.wicket.model.models.EntityModel;
 
 class WhereAmIModelDefault implements WhereAmIModel {
 
-   private final List chainOfParents = new ArrayList<>();
-   private final EntityModel endOfChain;
+   private final List reversedChainOfParents = new ArrayList<>();
+   private final EntityModel startOfChain;

-   public WhereAmIModelDefault(EntityModel endOfChain) {
-   this.endOfChain = endOfChain;
+   public WhereAmIModelDefault(EntityModel startOfChain) {
+   this.startOfChain = startOfChain;

-   final Object startPojo = endOfChain.getObject().getObject();
+   final Object startPojo = startOfChain.getObject().getObject();
 
ParentChain.caching()
.streamReversedParentChainOf(startPojo)
-   .forEach(chainOfParents::add);
+   .forEach(reversedChainOfParents::add);
}

@Override
-   public EntityModel getEndOfChain() {
-   return endOfChain;
+   public EntityModel getStartOfChain() {
+   return startOfChain;
}

@Override
public boolean isShowWhereAmI() {
-   return !chainOfParents.isEmpty();
+   return !reversedChainOfParents.isEmpty();
}
 
@Override
-   public Stream streamParentChain() {
-   return chainOfParents.stream()
+   public Stream streamParentChainReversed() {
+   return reversedChainOfParents.stream()
.map(this::toEntityModel);
}

@@ -61,7 +61,7 @@ class WhereAmIModelDefault implements WhereAmIModel {
 
private EntityM

[isis] branch master updated: ISIS-1821 fix case of empty annot. list not handled correctly

2018-01-15 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 3547e93  ISIS-1821 fix case of empty annot. list not handled correctly
3547e93 is described below

commit 3547e93031bec9164508380288efa86a16e9d97e
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Mon Jan 15 19:47:28 2018 +0100

ISIS-1821 fix case of empty annot. list not handled correctly
---
 .../MandatoryFacetInvertedByNullableAnnotationOnParameter.java | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/param/parameter/mandatory/MandatoryFacetInvertedByNullableAnnotationOnParameter.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/param/parameter/mandatory/MandatoryFacetInvertedByNullableAnnotationOnParameter.java
index 7dcaf78..a493be5 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/param/parameter/mandatory/MandatoryFacetInvertedByNullableAnnotationOnParameter.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/param/parameter/mandatory/MandatoryFacetInvertedByNullableAnnotationOnParameter.java
@@ -23,6 +23,7 @@ import java.util.List;
 
 import javax.annotation.Nullable;
 
+import org.apache.isis.core.commons.lang.NullSafe;
 import org.apache.isis.core.metamodel.facetapi.FacetHolder;
 import org.apache.isis.core.metamodel.facets.FacetedMethodParameter;
 import 
org.apache.isis.core.metamodel.facets.objectvalue.mandatory.MandatoryFacet;
@@ -38,7 +39,7 @@ import 
org.apache.isis.core.metamodel.facets.objectvalue.mandatory.MandatoryFace
 public class MandatoryFacetInvertedByNullableAnnotationOnParameter extends 
MandatoryFacetAbstract {
 
 public static MandatoryFacet create(final List annotation, final 
Class parameterType, final FacetedMethodParameter holder) {
-if(annotation == null) {
+if(NullSafe.isEmpty(annotation)) {
 return null;
 }
 if(parameterType.isPrimitive()) {

-- 
To stop receiving notification emails like this one, please contact
['"commits@isis.apache.org" <commits@isis.apache.org>'].


[isis] branch master updated: ISIS-1743 fa-Icon mapping for mixins using '$$' method names

2018-01-15 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new a0ac44c  ISIS-1743 fa-Icon mapping for mixins using '$$' method names
a0ac44c is described below

commit a0ac44c4e1dd74f5faf4cb59541101d3b42be88b
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Mon Jan 15 22:01:29 2018 +0100

ISIS-1743 fa-Icon mapping for mixins using '$$' method names
---
 .../annotprop/CssClassFaFacetOnMemberFactory.java  |  9 +--
 .../cssclassfa/annotprop/MixinInterceptor.java | 75 ++
 2 files changed, 77 insertions(+), 7 deletions(-)

diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/members/cssclassfa/annotprop/CssClassFaFacetOnMemberFactory.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/members/cssclassfa/annotprop/CssClassFaFacetOnMemberFactory.java
index 8fd1508..a72bac1 100644
--- 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/members/cssclassfa/annotprop/CssClassFaFacetOnMemberFactory.java
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/members/cssclassfa/annotprop/CssClassFaFacetOnMemberFactory.java
@@ -69,7 +69,7 @@ public class CssClassFaFacetOnMemberFactory extends 
FacetFactoryAbstract impleme
 private CssClassFaFacet createFromConfiguredRegexIfPossible(final 
ProcessMethodContext processMethodContext) {
 final Method method = processMethodContext.getMethod();
 
-String value = faIconIfAnyFor(method);
+String value = faIconIfAnyFor(MixinInterceptor.intendedNameOf(method));
 CssClassFaPosition position = CssClassFaPosition.LEFT;
 if (value != null) {
 int idxOfSeparator = value.indexOf(':');
@@ -84,12 +84,7 @@ public class CssClassFaFacetOnMemberFactory extends 
FacetFactoryAbstract impleme
 }
 }
 
-private String faIconIfAnyFor(Method method) {
-final String name = method.getName();
-return faIconIfAnyFor(name);
-}
-
-private String faIconIfAnyFor(String name) {
+   private String faIconIfAnyFor(String name) {
 final Map<Pattern, String> faIconByPattern = getFaIconByPattern();
 
 for (Map.Entry<Pattern, String> entry : faIconByPattern.entrySet()) {
diff --git 
a/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/members/cssclassfa/annotprop/MixinInterceptor.java
 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/members/cssclassfa/annotprop/MixinInterceptor.java
new file mode 100644
index 000..21563f5
--- /dev/null
+++ 
b/core/metamodel/src/main/java/org/apache/isis/core/metamodel/facets/members/cssclassfa/annotprop/MixinInterceptor.java
@@ -0,0 +1,75 @@
+/*
+ *  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.core.metamodel.facets.members.cssclassfa.annotprop;
+
+import java.lang.reflect.Method;
+
+import org.apache.isis.applib.annotation.Mixin;
+import org.apache.isis.core.commons.lang.NullSafe;
+import org.apache.isis.core.metamodel.facets.Annotations;
+
+/**
+ * To solve https://issues.apache.org/jira/browse/ISIS-1743;>ISIS-1743.
+ * Could be better integrated into Isis' meta-model.
+ * 
+ * @author ahu...@apache.org
+ */
+class MixinInterceptor {
+
+   /**
+* If method originates from a mixin and is named '$$' we infer the 
intended name 
+* from the mixin's class name.
+* 
+* @param method
+* @return the intended name of the method
+*/
+   public static String intendedNameOf(Method method) {
+   
+   if("$$".equals(method.getName()) && 
isMixin(method.getDeclaringClass()) ) {
+   final String mixinMethodName = 
inferMixinMethodName(method.getDeclaringClass());
+   if(mixinMethodName!=null)
+   return mixinMethodName; 
+   }
+   // default behavior
+   return method.getName();
+   }
+   
+

[isis] branch master updated: ISIS-1830 remove JDK9 internal API usages of c.s.o.a.x.internal.jaxp.datatype.XMLGregorianCalendarImpl

2018-01-21 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new 2698c6a  ISIS-1830 remove JDK9 internal API usages of 
c.s.o.a.x.internal.jaxp.datatype.XMLGregorianCalendarImpl
2698c6a is described below

commit 2698c6a7f4202525a7cb91aae4af0bb90f0e9071
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Sun Jan 21 14:41:47 2018 +0100

ISIS-1830 remove JDK9 internal API usages of
c.s.o.a.x.internal.jaxp.datatype.XMLGregorianCalendarImpl
---
 .../JodaDateTimeXMLGregorianCalendarAdapter.java   | 15 +---
 ...daLocalDateTimeXMLGregorianCalendarAdapter.java | 19 +
 .../JodaLocalDateXMLGregorianCalendarAdapter.java  | 15 +---
 .../JodaLocalTimeXMLGregorianCalendarAdapter.java  | 16 +---
 .../utils/jaxbadapters/XmlCalendarFactory.java | 95 ++
 5 files changed, 102 insertions(+), 58 deletions(-)

diff --git 
a/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaDateTimeXMLGregorianCalendarAdapter.java
 
b/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaDateTimeXMLGregorianCalendarAdapter.java
index bd208b7..f2d919d 100644
--- 
a/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaDateTimeXMLGregorianCalendarAdapter.java
+++ 
b/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaDateTimeXMLGregorianCalendarAdapter.java
@@ -25,8 +25,6 @@ import java.util.TimeZone;
 import javax.xml.bind.annotation.adapters.XmlAdapter;
 import javax.xml.datatype.XMLGregorianCalendar;
 
-import 
com.sun.org.apache.xerces.internal.jaxp.datatype.XMLGregorianCalendarImpl;
-
 import org.joda.time.DateTime;
 import org.joda.time.DateTimeZone;
 
@@ -50,18 +48,7 @@ public final class JodaDateTimeXMLGregorianCalendarAdapter {
 }
 
 public static XMLGregorianCalendar print(final DateTime dateTime) {
-if(dateTime == null) {
-return null;
-}
-
-final long millis = dateTime.getMillis();
-final DateTimeZone dateTimeZone = dateTime.getZone();
-
-final TimeZone timeZone = dateTimeZone.toTimeZone();
-final GregorianCalendar calendar = new GregorianCalendar(timeZone);
-calendar.setTimeInMillis(millis);
-
-return new XMLGregorianCalendarImpl(calendar);
+   return XmlCalendarFactory.create(dateTime);
 }
 
 public static class ForJaxb extends XmlAdapter<XMLGregorianCalendar, 
DateTime> {
diff --git 
a/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaLocalDateTimeXMLGregorianCalendarAdapter.java
 
b/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaLocalDateTimeXMLGregorianCalendarAdapter.java
index db74482..bc30291 100644
--- 
a/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaLocalDateTimeXMLGregorianCalendarAdapter.java
+++ 
b/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaLocalDateTimeXMLGregorianCalendarAdapter.java
@@ -21,8 +21,6 @@ package org.apache.isis.schema.utils.jaxbadapters;
 import javax.xml.bind.annotation.adapters.XmlAdapter;
 import javax.xml.datatype.XMLGregorianCalendar;
 
-import 
com.sun.org.apache.xerces.internal.jaxp.datatype.XMLGregorianCalendarImpl;
-
 import org.joda.time.LocalDateTime;
 
 /**
@@ -46,21 +44,8 @@ public final class 
JodaLocalDateTimeXMLGregorianCalendarAdapter {
 return new LocalDateTime(year, month, day, hour, minute, second, 
millisecond);
 }
 
-public static XMLGregorianCalendar print(final LocalDateTime dateTime) {
-if(dateTime == null) {
-return null;
-}
-
-final XMLGregorianCalendarImpl xgc = new XMLGregorianCalendarImpl();
-xgc.setYear(dateTime.getYear());
-xgc.setMonth(dateTime.getMonthOfYear());
-xgc.setDay(dateTime.getDayOfMonth());
-xgc.setHour(dateTime.getHourOfDay());
-xgc.setMinute(dateTime.getMinuteOfHour());
-xgc.setSecond(dateTime.getSecondOfMinute());
-xgc.setMillisecond(dateTime.getMillisOfSecond());
-
-return xgc;
+public static XMLGregorianCalendar print(final LocalDateTime 
localDateTime) {
+   return XmlCalendarFactory.create(localDateTime);
 }
 
 public static class ForJaxb extends XmlAdapter<XMLGregorianCalendar, 
LocalDateTime> {
diff --git 
a/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaLocalDateXMLGregorianCalendarAdapter.java
 
b/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaLocalDateXMLGregorianCalendarAdapter.java
index ba8ab70..dd627dc 100644
--- 
a/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaLocalDateXMLGregorianCalendarAdapter.java
+++ 
b/core/schema/src/main/java/org/apache/isis/schema/utils/jaxbadapters/JodaLocalDateXMLGregorianCalendarAdapter.java
@@ -21,

[isis] branch master updated: ISIS-1827 relaxed guava dependency by removal in core's root pom.xml

2018-01-21 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new d7f4db2  ISIS-1827 relaxed guava dependency by removal in core's root 
pom.xml
d7f4db2 is described below

commit d7f4db2154eadb37d73759884f4ff6c417176d8d
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Sun Jan 21 23:16:10 2018 +0100

ISIS-1827 relaxed guava dependency by removal in core's root pom.xml
---
 core/pom.xml | 4 
 1 file changed, 4 deletions(-)

diff --git a/core/pom.xml b/core/pom.xml
index 967ff80..3148a47 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -2009,10 +2009,6 @@ ${license.additional-notes}
 
 
 
-com.google.guava
-guava
-
-
 org.hamcrest
 hamcrest-library
 

-- 
To stop receiving notification emails like this one, please contact
['"commits@isis.apache.org" <commits@isis.apache.org>'].


[isis] branch master updated: ISIS-1844 make any unchecked casts explicit

2018-01-22 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new b240cc3  ISIS-1844 make any unchecked casts explicit
b240cc3 is described below

commit b240cc3a5c339df2231bc8b75c930e0ec6c91f94
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Mon Jan 22 10:00:40 2018 +0100

ISIS-1844 make any unchecked casts explicit
---
 .../org/apache/isis/applib/ModuleOrBuilderAbstract.java   |  2 +-
 .../apache/isis/applib/fixturescripts/FixtureScript.java  | 15 ---
 .../org/apache/isis/applib/services/jaxb/JaxbService.java |  5 +++--
 .../services/queryresultscache/QueryResultsCache.java |  4 ++--
 .../main/java/org/apache/isis/applib/util/JaxbUtil.java   |  2 +-
 .../java/org/apache/isis/applib/util/ObjectContracts.java |  8 ++--
 6 files changed, 17 insertions(+), 19 deletions(-)

diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/ModuleOrBuilderAbstract.java 
b/core/applib/src/main/java/org/apache/isis/applib/ModuleOrBuilderAbstract.java
index a0a6ecf..ab4b31d 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/ModuleOrBuilderAbstract.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/ModuleOrBuilderAbstract.java
@@ -128,7 +128,7 @@ abstract class ModuleOrBuilderAbstract> {
 // -- HELPER
 
 @SuppressWarnings("unchecked") //[ahuber] it's safe to assume this object 
is an instance of B
-   private B self() {
+   protected B self() {
return (B) this;
 }
 
diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/fixturescripts/FixtureScript.java
 
b/core/applib/src/main/java/org/apache/isis/applib/fixturescripts/FixtureScript.java
index 872f7ad..da8cef9 100644
--- 
a/core/applib/src/main/java/org/apache/isis/applib/fixturescripts/FixtureScript.java
+++ 
b/core/applib/src/main/java/org/apache/isis/applib/fixturescripts/FixtureScript.java
@@ -49,6 +49,7 @@ import 
org.apache.isis.applib.services.sessmgmt.SessionManagementService;
 import org.apache.isis.applib.services.user.UserService;
 import org.apache.isis.applib.services.wrapper.WrapperFactory;
 import org.apache.isis.applib.services.xactn.TransactionService;
+import org.apache.isis.applib.util.Casts;
 
 @ViewModelLayout(named="Script")
 public abstract class FixtureScript 
@@ -627,7 +628,7 @@ public abstract class FixtureScript
 return childFixtureScript;
 } else {
 trace(childFixtureScript, As.SKIP);
-return (T)previouslyExecutedScript;
+return Casts.uncheckedCast(previouslyExecutedScript);
 }
 
 case EXECUTE_ONCE_BY_VALUE:
@@ -675,7 +676,7 @@ public abstract class FixtureScript
 return childFixtureScript;
 } else {
 trace(childFixtureScript, As.SKIP);
-return (T)previouslyExecutedScript;
+return Casts.uncheckedCast(previouslyExecutedScript);
 }
 }
 
@@ -771,11 +772,11 @@ public abstract class FixtureScript
 }
 @Programmatic
 public  T getUserData(final Class cls) {
-return (T) userData.get(cls);
+return Casts.uncheckedCast(userData.get(cls));
 }
 @Programmatic
 public  T clearUserData(final Class cls) {
-return (T) userData.remove(cls);
+return Casts.uncheckedCast(userData.remove(cls));
 }
 
 }
@@ -790,7 +791,7 @@ public abstract class FixtureScript
 }
 
 private  T valueFor(final String parameterName, final ExecutionContext 
ec, final T defaultValue) {
-final Class cls = (Class) defaultValue.getClass();
+final Class cls = Casts.uncheckedCast(defaultValue.getClass());
 
 final T value = readParam(parameterName, ec, cls);
 if(value != null) { return (T) value; }
@@ -818,7 +819,7 @@ public abstract class FixtureScript
 Method method;
 try {
 method = this.getClass().getMethod("get" + 
uppercase(parameterName));
-value = (T)method.invoke(this);
+value = Casts.uncheckedCast(method.invoke(this));
 } catch (NoSuchMethodException | InvocationTargetException | 
IllegalAccessException ignored) {
 
 }
@@ -827,7 +828,7 @@ public abstract class FixtureScript
 if (cls == Boolean.class || cls == boolean.class) {
 try {
 method = this.getClass().getMethod("is" + 
uppercase(parameterName));
-value = (T)method.invoke(this);
+value = Casts.uncheckedCast(method.invoke(this));
 } catch (NoSuchMethodException | InvocationTargetException | 
IllegalAccessException ignored) {
 
 }
diff --git 
a/core/applib/src/main/java/org/apache/isis/applib/s

[isis] branch master updated: ISIS-1841 mark o.a.i.applib.layout.Util deprecated, since not used

2018-01-22 Thread ahuber
This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
 new b304338  ISIS-1841 mark o.a.i.applib.layout.Util deprecated, since not 
used
b304338 is described below

commit b304338b33b53f793e79b4a31411ecb632a31da6
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Mon Jan 22 09:59:34 2018 +0100

ISIS-1841 mark o.a.i.applib.layout.Util deprecated, since not used
---
 core/applib/src/main/java/org/apache/isis/applib/layout/Util.java | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/core/applib/src/main/java/org/apache/isis/applib/layout/Util.java 
b/core/applib/src/main/java/org/apache/isis/applib/layout/Util.java
index 60725ff..80dd6de 100644
--- a/core/applib/src/main/java/org/apache/isis/applib/layout/Util.java
+++ b/core/applib/src/main/java/org/apache/isis/applib/layout/Util.java
@@ -23,6 +23,7 @@ import javax.annotation.Nullable;
 import com.google.common.base.Function;
 import com.google.common.base.Predicate;
 
+@Deprecated //[ahuber] class is package private, could not find any uses
 class Util {
 
 private Util(){}
@@ -40,7 +41,8 @@ class Util {
 }
 
 private static class CastFunction<F, T extends F> implements Function<F, 
T> {
-@Override
+@SuppressWarnings("unchecked") // class is deprecated
+   @Override
 public final T apply(final F from) {
 return (T) from;
 }

-- 
To stop receiving notification emails like this one, please contact
ahu...@apache.org.


<    1   2   3   4   5   6   7   8   9   10   >