buildbot exception in on ofbizTrunkFrameworkPlugins

2021-02-14 Thread buildbot
The Buildbot has detected a build exception on builder 
ofbizTrunkFrameworkPlugins while building ofbiz-plugins. Full details are 
available at:
https://ci.apache.org/builders/ofbizTrunkFrameworkPlugins/builds/1999

Buildbot URL: https://ci.apache.org/

Buildslave for this Build: asf947_ubuntu

Build Reason: The AnyBranchScheduler scheduler named 'onTrunkPluginsCommit' 
triggered this build
Build Source Stamp: [branch trunk] e964d6172435db4be4870e09110576a68e33aafc
Blamelist: Jacques Le Roux 

BUILD FAILED: exception build upload test-results part 1

Sincerely,
 -The Buildbot





[ofbiz-plugins] branch trunk updated: Improved: Default ordering of webapps titles in main menu (OFBIZ-12166)

2021-02-14 Thread jleroux
This is an automated email from the ASF dual-hosted git repository.

jleroux pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-plugins.git


The following commit(s) were added to refs/heads/trunk by this push:
 new e964d61  Improved: Default ordering of webapps titles in main menu 
(OFBIZ-12166)
e964d61 is described below

commit e964d6172435db4be4870e09110576a68e33aafc
Author: Jacques Le Roux 
AuthorDate: Sun Feb 14 21:12:52 2021 +0100

Improved: Default ordering of webapps titles in main menu (OFBIZ-12166)

This 1st step sorts the plugins. We need to discuss more...
---
 assetmaint/ofbiz-component.xml |  2 ++
 bi/ofbiz-component.xml |  1 +
 birt/ofbiz-component.xml   |  4 
 cmssite/ofbiz-component.xml|  9 +++--
 ebay/ofbiz-component.xml   |  1 +
 ebaystore/ofbiz-component.xml  |  1 +
 example/ofbiz-component.xml|  1 +
 exampleext/ofbiz-component.xml | 10 --
 lucene/ofbiz-component.xml |  1 +
 myportal/ofbiz-component.xml   | 10 --
 projectmgr/ofbiz-component.xml |  1 +
 scrum/ofbiz-component.xml  |  1 +
 solr/ofbiz-component.xml   |  3 ++-
 webpos/ofbiz-component.xml |  1 +
 14 files changed, 39 insertions(+), 7 deletions(-)

diff --git a/assetmaint/ofbiz-component.xml b/assetmaint/ofbiz-component.xml
index 8060f1a..ae36953 100644
--- a/assetmaint/ofbiz-component.xml
+++ b/assetmaint/ofbiz-component.xml
@@ -41,6 +41,7 @@
 
 
 
 
 
 
-
+
 
 
diff --git a/ebay/ofbiz-component.xml b/ebay/ofbiz-component.xml
index a85dfb3..c7d9828 100644
--- a/ebay/ofbiz-component.xml
+++ b/ebay/ofbiz-component.xml
@@ -36,6 +36,7 @@ under the License.
 
 
 http://ofbiz.apache.org/dtds/ofbiz-component.xsd;>
 
 
-
+
 
diff --git a/lucene/ofbiz-component.xml b/lucene/ofbiz-component.xml
index 0c48323..a950b6d 100644
--- a/lucene/ofbiz-component.xml
+++ b/lucene/ofbiz-component.xml
@@ -38,6 +38,7 @@ under the License.
 
 
 
-
+
 
diff --git a/projectmgr/ofbiz-component.xml b/projectmgr/ofbiz-component.xml
index 29e4777..61b8a17 100644
--- a/projectmgr/ofbiz-component.xml
+++ b/projectmgr/ofbiz-component.xml
@@ -42,6 +42,7 @@ under the License.
 
 
 
-
\ No newline at end of file
+
diff --git a/webpos/ofbiz-component.xml b/webpos/ofbiz-component.xml
index 7046e0a..23623c4 100644
--- a/webpos/ofbiz-component.xml
+++ b/webpos/ofbiz-component.xml
@@ -46,6 +46,7 @@ under the License.
 
 

[ofbiz-framework] branch trunk updated: Improved: Default ordering of webapps titles in main menu (OFBIZ-12166)

2021-02-14 Thread jleroux
This is an automated email from the ASF dual-hosted git repository.

jleroux pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git


The following commit(s) were added to refs/heads/trunk by this push:
 new a2dac54  Improved: Default ordering of webapps titles in main menu 
(OFBIZ-12166)
a2dac54 is described below

commit a2dac5482cc7aa4049dce59e6551b5702549659a
Author: Jacques Le Roux 
AuthorDate: Sun Feb 14 21:11:58 2021 +0100

Improved: Default ordering of webapps titles in main menu (OFBIZ-12166)

[...] having more important apps in 1st places would be better [...]
the feature should be easily changed by custom projects [...]
documentation for that would be enough.

This 1st step sorts the applications and webtools. I believe webtools 
should not
be secondary but that needs to be discussed with other options.
---
 applications/accounting/ofbiz-component.xml|  1 +
 applications/content/ofbiz-component.xml   |  1 +
 applications/humanres/ofbiz-component.xml  |  1 +
 applications/manufacturing/ofbiz-component.xml |  1 +
 applications/marketing/ofbiz-component.xml |  2 ++
 applications/order/ofbiz-component.xml |  1 +
 applications/party/ofbiz-component.xml |  1 +
 applications/product/ofbiz-component.xml   | 18 ++
 applications/workeffort/ofbiz-component.xml|  1 +
 framework/webtools/ofbiz-component.xml |  1 +
 10 files changed, 20 insertions(+), 8 deletions(-)

diff --git a/applications/accounting/ofbiz-component.xml 
b/applications/accounting/ofbiz-component.xml
index 503f300..b174ce0 100644
--- a/applications/accounting/ofbiz-component.xml
+++ b/applications/accounting/ofbiz-component.xml
@@ -77,6 +77,7 @@ under the License.
 
 
 
 
 
 
-
+
 
 

buildbot exception in on ofbizTrunkFramework

2021-02-14 Thread buildbot
The Buildbot has detected a build exception on builder ofbizTrunkFramework 
while building ofbiz-framework. Full details are available at:
https://ci.apache.org/builders/ofbizTrunkFramework/builds/2105

Buildbot URL: https://ci.apache.org/

Buildslave for this Build: asf946_ubuntu

Build Reason: The AnyBranchScheduler scheduler named 'onTrunkFrameworkCommit' 
triggered this build
Build Source Stamp: [branch trunk] 568ac8927bd74d83cd099a5d0fd59dd06a595b26
Blamelist: Jacques Le Roux 

BUILD FAILED: exception build upload test-results part 1

Sincerely,
 -The Buildbot





[ofbiz-framework] branch trunk updated: Fixed: webapp position does not really work (OFBIZ-12176)

2021-02-14 Thread jleroux
This is an automated email from the ASF dual-hosted git repository.

jleroux pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git


The following commit(s) were added to refs/heads/trunk by this push:
 new 568ac89  Fixed: webapp position does not really work (OFBIZ-12176)
568ac89 is described below

commit 568ac8927bd74d83cd099a5d0fd59dd06a595b26
Author: Jacques Le Roux 
AuthorDate: Sun Feb 14 19:27:33 2021 +0100

Fixed: webapp position does not really work (OFBIZ-12176)

The current implementation of webapp position uses String as key.
You can't really order on String, you need numbers.

This is needed by OFBIZ-12166
---
 .../main/java/org/apache/ofbiz/webapp/WebAppCache.java | 18 +-
 1 file changed, 13 insertions(+), 5 deletions(-)

diff --git 
a/framework/webapp/src/main/java/org/apache/ofbiz/webapp/WebAppCache.java 
b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/WebAppCache.java
index 02a6969..8a66060 100644
--- a/framework/webapp/src/main/java/org/apache/ofbiz/webapp/WebAppCache.java
+++ b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/WebAppCache.java
@@ -25,6 +25,7 @@ import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Optional;
 import java.util.TreeMap;
+import java.util.concurrent.atomic.AtomicInteger;
 import java.util.function.Supplier;
 
 import org.apache.ofbiz.base.component.ComponentConfig;
@@ -54,8 +55,7 @@ public class WebAppCache {
 
 /**
  * Constructs an empty web application cache.
- * @param supplier the source from which components configurations
- *are retrieved
+ * @param supplier the source from which components configurations are 
retrieved
  */
 public WebAppCache(Supplier> supplier) {
 ccs = supplier;
@@ -90,7 +90,8 @@ public class WebAppCache {
 webInfos = serverWebApps.get(serverWebAppsKey);
 }
 if (webInfos == null) {
-TreeMap tm = ccs.get().stream()
+AtomicInteger emptyPosition = new AtomicInteger(999);
+TreeMap tm = ccs.get().stream()
 .flatMap(cc -> cc.getWebappInfos().stream())
 .filter(wInfo -> {
 if (wInfo.getAppBarDisplay()) {
@@ -102,10 +103,17 @@ public class WebAppCache {
 })
 // Keep only one WebappInfo per title (the last appearing 
one).
 .collect(TreeMap::new, (acc, wInfo) -> {
-String key = 
UtilValidate.isNotEmpty(wInfo.getPosition()) ? wInfo.getPosition() : 
wInfo.getTitle();
+String stringKey = 
UtilValidate.isNotEmpty(wInfo.getPosition()) ? wInfo.getPosition() : 
wInfo.getTitle();
+Integer key = null;
+try {
+key = Integer.valueOf(stringKey);
+key = (key != null) ? key : 
emptyPosition.incrementAndGet();
+} catch (NumberFormatException e) {
+key = emptyPosition.incrementAndGet();
+}
 acc.put(key, wInfo);
 },
-TreeMap::putAll);
+TreeMap::putAll);
 // Create the list of WebappInfos ordered by their title/position.
 webInfos = Collections.unmodifiableList(new 
ArrayList<>(tm.values()));
 synchronized (serverWebApps) {