[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager] Pushed new branch bugfix/CC-CHANNELMGR-1596
Michael Metternich pushed new branch bugfix/CC-CHANNELMGR-1596 at cms-community / hippo-addon-channel-manager --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-addon-channel-manager/tree/bugfix/CC-CHANNELMGR-1596 You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-repository][feature/REPO-1897] 3 commits: REPO-1897 [Backport 10.2] Provide (log4j1) Log4jInterceptor test utility class…
Ate Douma pushed to branch feature/REPO-1897 at cms-community / hippo-repository Commits: c449db1f by Ate Douma at 2017-11-17T18:43:04+01:00 REPO-1897 [Backport 10.2] Provide (log4j1) Log4jInterceptor test utility class to suppress and/or capture log events during unit tests (cherry picked from commit b7e24944c6f76f17e4ba9037d33121b62b423aa7) - - - - - 78715923 by Ate Douma at 2017-11-17T18:43:44+01:00 REPO-1897 prepare for backport: bump services version - - - - - ff133e69 by Ate Douma at 2017-11-17T18:44:58+01:00 REPO-1897 [Backport 10.2] Implement new LockManager service and replace all deprecated HippoLock and HippoLockManager usages This is a cherry-picked and squashed backport from REPO-1881 and REPO-1887: REPO-1811 Implement in-memory lock manager (cherry picked from commit dfa6f279653256cbeaabe6ceb59d4171b64c508f) REPO-1811 To the RepositoryImpl add a Journal ConnectionHelper accessor Via this Journal ConnectionHelper we can access the Journal DataSource via the ConnectionHelperDataSourceAccessor. Admittedly, a bit clumsy but we need access to the Journal DataSource because we need to know whether we are dealing with a database *and* whether we have a clustered setup : Only in that case, the lock mechanism has to be upgraded from in memory locking to db base locking because needs to be cluster wide (cherry picked from commit 4750450f8d1dc505d404fb32ce1eac002df9b707) REPO-1811 Support for a Database lock manager The Database lock manager interaction is pretty much exactly the same as the MemoryLockManager interaction. The biggest difference is that the DbLockManager creates database based locks and the MemoryLockManager creates MemoryLocks. Note that a DbLock is the same as the MemoryLock but only contains a #destroy implementation that releases the database lock. The DbLockManager is still work in progress (cherry picked from commit e0f19fab9cdecc4fc6cb15bc79d55ffa30fff8fb) REPO-1811 Fix the LockClusterTest setup (still ignored but the setup failed since we do not allow SNS below jcr:root any more) (cherry picked from commit 1dba0d49778da55568fcafee6ddff4fdc6563190) REPO-1811 Support database locking (cherry picked from commit 92c914efffe6eaacb79bc638f71576e1463b9aa0) REPO-1811 Support background jobs in the Memory or Db LockManager - All the background jobs are run by a single thread - By default they run every 5 seconds with an initial delay of 5 seconds - Every background job is wrapped in a synchronized runnable the synchronized on the LockManager instance: The reason for this is that we do not want background jobs to write concurrently to possibly the same records as other (background) jobs - We have the following background jobs: 1) UnlockStoppedThreadJanitor : releases database locks for records that were held by a thread that is not alive any more 2) DbResetExpiredLocksJanitor : Resets all database rows which have expired locks (rows with status RUNNING or ABORT and expirationTime has passed 3) DbLockRefresher: Refreshes the expiresTime of a lock to currentTime + refreshRateSeconds 4) LockThreadInterrupter : Interrupts the Thread that holds the lock that has been marked ABORT (cherry picked from commit cbf14aedcc6518e81c94104d705765b492a92188) REPO-1811 Make sure getLocks and isLocked works cluster wide in case of a database (cherry picked from commit 441beff40149a15603e58e4670f33b64b1274eeb) REPO-1811 Fix sql statement (cherry picked from commit d3d25849c9ea0525df7eaf9e2e18e3de1f27a11d) REPO-1811 Extract abstract test and add an abort test (cherry picked from commit 5ab1e55f7114e1cb24d671f076f7a7ed697f5c69) REPO-1811 use getHoldCount() instead of protected access (cherry picked from commit 7027fce32f09b750e7e9a8639ba4a8ca32fa2e3d) REPO-1811 improve feedback (cherry picked from commit 0bf87cb5a2897a598bdbaca9219fcc37067465d6) REPO-1811 use getHoldCount() instead of protected access (cherry picked from commit a268b5e6a7c4dab939e489a91d2afe88b82d69f9) REPO-1811 Fix abort statement (cherry picked from commit dac8d9cce79f4dcbaa564219cf725d6d108f45d8) REPO-1811 Encapsulate the localLocks object Since localLocks is a hashmap, all access to it should be synchronized. This can be easier achieved by encapsulating it and whenever needed by other classes, return a new object containing the same locks (cherry picked from commit cc3e10d9c50e4e0d1ecc0fbd0428c4915bcf0713) REPO-1811 Enhance abort tests (cherry picked from commit 43f170296b8c9027ca0b9f9a8f2464f3e9aa363c) REPO-1811 use auto closable in integration tests (cherry picked from commit 05143eddc4817c9fdb872cbd9c3be34a4543743d) REPO-1811 Correct the expiresTime parameter (cherry picked from commit
[HippoCMS-scm] [Git][cms-community/hippo-repository] Pushed new branch feature/REPO-1897
Ate Douma pushed new branch feature/REPO-1897 at cms-community / hippo-repository --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-repository/tree/feature/REPO-1897 You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-services-api] Pushed new branch feature/CMS-10987
Ate Douma pushed new branch feature/CMS-10987 at cms-community / hippo-services-api --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-services-api/tree/feature/CMS-10987 You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager] Pushed new branch feature/CC-CHANNELMGR-1512
Mathijs den Burger pushed new branch feature/CC-CHANNELMGR-1512 at cms-community / hippo-addon-channel-manager --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-addon-channel-manager/tree/feature/CC-CHANNELMGR-1512 You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-cms-release][release/12.0] CMS-10823 Use released hippo-plugin-relateddocs-parent-5.0.2
Arent-Jan Banck pushed to branch release/12.0 at cms-community / hippo-cms-release Commits: 9cc45a37 by Arent-Jan Banck at 2017-11-17T13:55:57+01:00 CMS-10823 Use released hippo-plugin-relateddocs-parent-5.0.2 - - - - - 1 changed file: - pom.xml Changes: = pom.xml = --- a/pom.xml +++ b/pom.xml @@ -70,7 +70,7 @@ 4.0.3 4.0.1 4.0.2 - 5.0.2-SNAPSHOT +5.0.2 4.0.1 4.0.2 5.0.2 View it on GitLab: https://code.onehippo.org/cms-community/hippo-cms-release/commit/9cc45a37c9d434c578a0e9daf5d9116a9f91cdc4 --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-cms-release/commit/9cc45a37c9d434c578a0e9daf5d9116a9f91cdc4 You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-plugin-relateddocs][release/5.0] 2 commits: HIPPLUG-1474 prepare release hippo-plugin-relateddocs-parent-5.0.2
Arent-Jan Banck pushed to branch release/5.0 at cms-community / hippo-plugin-relateddocs Commits: 52be451a by Arent-Jan Banck at 2017-11-17T13:55:57+01:00 HIPPLUG-1474 prepare release hippo-plugin-relateddocs-parent-5.0.2 - - - - - 47da8350 by Arent-Jan Banck at 2017-11-17T13:55:59+01:00 HIPPLUG-1474 prepare for next development iteration - - - - - 3 changed files: - addon-cms/pom.xml - hst/pom.xml - pom.xml Changes: = addon-cms/pom.xml = --- a/addon-cms/pom.xml +++ b/addon-cms/pom.xml @@ -18,7 +18,7 @@ hippo-plugin-relateddocs-parent org.onehippo.cms7 -5.0.2-SNAPSHOT +5.0.3-SNAPSHOT 4.0.0 = hst/pom.xml = --- a/hst/pom.xml +++ b/hst/pom.xml @@ -18,7 +18,7 @@ hippo-plugin-relateddocs-parent org.onehippo.cms7 -5.0.2-SNAPSHOT +5.0.3-SNAPSHOT 4.0.0 = pom.xml = --- a/pom.xml +++ b/pom.xml @@ -30,7 +30,7 @@ Hippo Plugin Related Documents Hippo Plugin Related Documents hippo-plugin-relateddocs-parent - 5.0.2-SNAPSHOT + 5.0.3-SNAPSHOT pom 2009 View it on GitLab: https://code.onehippo.org/cms-community/hippo-plugin-relateddocs/compare/09b924cff080255ca9a95b0b1c16b14f4f668423...47da83509ed3152f1d34f9c2aad9ba64039f39cf --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-plugin-relateddocs/compare/09b924cff080255ca9a95b0b1c16b14f4f668423...47da83509ed3152f1d34f9c2aad9ba64039f39cf You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-plugin-relateddocs] Pushed new tag hippo-plugin-relateddocs-parent-5.0.2
Arent-Jan Banck pushed new tag hippo-plugin-relateddocs-parent-5.0.2 at cms-community / hippo-plugin-relateddocs --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-plugin-relateddocs/tree/hippo-plugin-relateddocs-parent-5.0.2 You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-repository][release/5.0] REPO-1896 [Backport 12.0] Autoexport: repeated IllegalStateExceptions when changing the root node
Ate Douma pushed to branch release/5.0 at cms-community / hippo-repository Commits: a272f6f3 by Peter Centgraf at 2017-11-17T13:22:56+01:00 REPO-1896 [Backport 12.0] Autoexport: repeated IllegalStateExceptions when changing the root node (cherry picked from commit ab9c5417be609259a25f5a6ef22011ee071f3292) (cherry picked from commit e998b50996d6da24dc6ec0755671fbfd5bfa5b03) - - - - - 3 changed files: - engine/src/main/java/org/onehippo/cm/engine/autoexport/DefinitionMergeService.java - engine/src/test/resources/merge/add-property/in/diff/hcm-config/diff.yaml - + engine/src/test/resources/merge/add-property/out/exportSecond/hcm-config/main.yaml Changes: = engine/src/main/java/org/onehippo/cm/engine/autoexport/DefinitionMergeService.java = --- a/engine/src/main/java/org/onehippo/cm/engine/autoexport/DefinitionMergeService.java +++ b/engine/src/main/java/org/onehippo/cm/engine/autoexport/DefinitionMergeService.java @@ -1148,7 +1148,7 @@ public class DefinitionMergeService { /** * Get or create a definition in the local modules to contain data for jcrPath. * Note: this method performs a three-step check for what module to use similar to - * {@link #createNewContentSource(JcrPath, SortedMap)}. + * {@link #createNewContentSource(JcrPath, SortedMap)}, except we also need to handle the JCR root node here. * @param path the path for which we want a definition * @return a DefinitionNodeImpl corresponding to the jcrPath, which may or may not be a root and may or not may be * empty @@ -1158,6 +1158,11 @@ public class DefinitionMergeService { // what module should we put it in, according to normal auto-export config rules? final ModuleImpl defaultModule = getModuleByAutoExportConfig(path); +// for the JCR root node, the auto-export config is the only possible answer +if (path.isRoot()) { +parentNodeModule = defaultModule; +} + // where is the parent of this path initially defined? // if the caller already handed us a value, use it // this might be a spin-off of a recursiveCopy that hasn't been merged to the configNode tree yet! = engine/src/test/resources/merge/add-property/in/diff/hcm-config/diff.yaml = --- a/engine/src/test/resources/merge/add-property/in/diff/hcm-config/diff.yaml +++ b/engine/src/test/resources/merge/add-property/in/diff/hcm-config/diff.yaml @@ -1,5 +1,10 @@ definitions: config: +/: + jcr:mixinTypes: +operation: add +value: ['hippo:named'] + hippo:name: Root Node /otherTopmost: newProperty: value # REPO-1805 reproduction case: should reuse existing definition /topmost: = engine/src/test/resources/merge/add-property/out/exportSecond/hcm-config/main.yaml = --- /dev/null +++ b/engine/src/test/resources/merge/add-property/out/exportSecond/hcm-config/main.yaml @@ -0,0 +1,7 @@ +definitions: + config: +/: + jcr:mixinTypes: +operation: add +value: ['hippo:named'] + hippo:name: Root Node View it on GitLab: https://code.onehippo.org/cms-community/hippo-repository/commit/a272f6f3c5deeb6ce178c66b4e204da80edd21fc --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-repository/commit/a272f6f3c5deeb6ce178c66b4e204da80edd21fc You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-repository] Deleted branch feature/REPO-1894
Ate Douma deleted branch feature/REPO-1894 at cms-community / hippo-repository --- You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-repository][master] REPO-1894 Check for adding a property to the JCR root node in DefinitionMergeService
Ate Douma pushed to branch master at cms-community / hippo-repository Commits: e998b509 by Peter Centgraf at 2017-11-17T13:15:55+01:00 REPO-1894 Check for adding a property to the JCR root node in DefinitionMergeService (cherry picked from commit ab9c5417be609259a25f5a6ef22011ee071f3292) - - - - - 3 changed files: - engine/src/main/java/org/onehippo/cm/engine/autoexport/DefinitionMergeService.java - engine/src/test/resources/merge/add-property/in/diff/hcm-config/diff.yaml - + engine/src/test/resources/merge/add-property/out/exportSecond/hcm-config/main.yaml Changes: = engine/src/main/java/org/onehippo/cm/engine/autoexport/DefinitionMergeService.java = --- a/engine/src/main/java/org/onehippo/cm/engine/autoexport/DefinitionMergeService.java +++ b/engine/src/main/java/org/onehippo/cm/engine/autoexport/DefinitionMergeService.java @@ -1148,7 +1148,7 @@ public class DefinitionMergeService { /** * Get or create a definition in the local modules to contain data for jcrPath. * Note: this method performs a three-step check for what module to use similar to - * {@link #createNewContentSource(JcrPath, SortedMap)}. + * {@link #createNewContentSource(JcrPath, SortedMap)}, except we also need to handle the JCR root node here. * @param path the path for which we want a definition * @return a DefinitionNodeImpl corresponding to the jcrPath, which may or may not be a root and may or not may be * empty @@ -1158,6 +1158,11 @@ public class DefinitionMergeService { // what module should we put it in, according to normal auto-export config rules? final ModuleImpl defaultModule = getModuleByAutoExportConfig(path); +// for the JCR root node, the auto-export config is the only possible answer +if (path.isRoot()) { +parentNodeModule = defaultModule; +} + // where is the parent of this path initially defined? // if the caller already handed us a value, use it // this might be a spin-off of a recursiveCopy that hasn't been merged to the configNode tree yet! = engine/src/test/resources/merge/add-property/in/diff/hcm-config/diff.yaml = --- a/engine/src/test/resources/merge/add-property/in/diff/hcm-config/diff.yaml +++ b/engine/src/test/resources/merge/add-property/in/diff/hcm-config/diff.yaml @@ -1,5 +1,10 @@ definitions: config: +/: + jcr:mixinTypes: +operation: add +value: ['hippo:named'] + hippo:name: Root Node /otherTopmost: newProperty: value # REPO-1805 reproduction case: should reuse existing definition /topmost: = engine/src/test/resources/merge/add-property/out/exportSecond/hcm-config/main.yaml = --- /dev/null +++ b/engine/src/test/resources/merge/add-property/out/exportSecond/hcm-config/main.yaml @@ -0,0 +1,7 @@ +definitions: + config: +/: + jcr:mixinTypes: +operation: add +value: ['hippo:named'] + hippo:name: Root Node View it on GitLab: https://code.onehippo.org/cms-community/hippo-repository/commit/e998b50996d6da24dc6ec0755671fbfd5bfa5b03 --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-repository/commit/e998b50996d6da24dc6ec0755671fbfd5bfa5b03 You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager][feature/CC-CHANNELMGR-1513] CHANNELMGR-1568 Improve private method name in unit test
Mathijs den Burger pushed to branch feature/CC-CHANNELMGR-1513 at cms-community / hippo-addon-channel-manager Commits: 7ca64c24 by Mathijs den Burger at 2017-11-17T12:25:04+01:00 CHANNELMGR-1568 Improve private method name in unit test The document names should not be updated. Pass the reason so the method can also be used to assert the case where the slug already exists. - - - - - 1 changed file: - content-service/src/test/java/org/onehippo/cms/channelmanager/content/document/DocumentsServiceImplTest.java Changes: = content-service/src/test/java/org/onehippo/cms/channelmanager/content/document/DocumentsServiceImplTest.java = --- a/content-service/src/test/java/org/onehippo/cms/channelmanager/content/document/DocumentsServiceImplTest.java +++ b/content-service/src/test/java/org/onehippo/cms/channelmanager/content/document/DocumentsServiceImplTest.java @@ -1630,13 +1630,7 @@ public class DocumentsServiceImplTest { expect(FolderUtils.nodeExists(eq(folder), eq(encodedUrlName))).andReturn(true); replayAll(); -try { -documentsService.updateDocumentNames(uuid, document, session); -fail("No Exception"); -} catch (final ConflictException e) { -final ErrorInfo errorInfo = (ErrorInfo) e.getPayload(); -assertThat(errorInfo.getReason(), equalTo(Reason.SLUG_ALREADY_EXISTS)); -} +assertUpdateDocumentNamesFails(uuid, document, Reason.SLUG_ALREADY_EXISTS); } @Test @@ -1705,7 +1699,7 @@ public class DocumentsServiceImplTest { replayAll(); -assertDocumentNameIsUpdated(uuid, document); +assertUpdateDocumentNamesFails(uuid, document, Reason.NAME_ALREADY_EXISTS); } @Test @@ -1816,7 +1810,7 @@ public class DocumentsServiceImplTest { replayAll(); -assertDocumentNameIsUpdated(uuid, document); +assertUpdateDocumentNamesFails(uuid, document, Reason.NAME_ALREADY_EXISTS); } @Test(expected = NotFoundException.class) @@ -2049,14 +2043,13 @@ public class DocumentsServiceImplTest { return docType; } -private void assertDocumentNameIsUpdated(final String uuid, final Document document) throws ErrorWithPayloadException { +private void assertUpdateDocumentNamesFails(final String uuid, final Document document, final Reason reason) throws ErrorWithPayloadException { try { documentsService.updateDocumentNames(uuid, document, session); fail("No Exception"); } catch (final ConflictException e) { final ErrorInfo errorInfo = (ErrorInfo) e.getPayload(); -assertThat(errorInfo.getReason(), equalTo(Reason.NAME_ALREADY_EXISTS)); +assertThat(errorInfo.getReason(), equalTo(reason)); } } - } View it on GitLab: https://code.onehippo.org/cms-community/hippo-addon-channel-manager/commit/7ca64c24924a835f4ebb71ff3e060d3730c26ef1 --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-addon-channel-manager/commit/7ca64c24924a835f4ebb71ff3e060d3730c26ef1 You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-repository] Deleted branch feature/REPO-1872
Ate Douma deleted branch feature/REPO-1872 at cms-community / hippo-repository --- You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-cms-release][release/12.0] CMS-10823 bump repository version for REPO-1895
Ate Douma pushed to branch release/12.0 at cms-community / hippo-cms-release Commits: 09528c07 by Ate Douma at 2017-11-17T12:16:04+01:00 CMS-10823 bump repository version for REPO-1895 - - - - - 1 changed file: - pom.xml Changes: = pom.xml = --- a/pom.xml +++ b/pom.xml @@ -53,7 +53,7 @@ 4.0.0 5.0.2 5.0.1 -5.0.3 +5.0.4-SNAPSHOT 4.0.3 4.0.1 4.0.1 View it on GitLab: https://code.onehippo.org/cms-community/hippo-cms-release/commit/09528c073894d9289278e25c05795297dec7ee21 --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-cms-release/commit/09528c073894d9289278e25c05795297dec7ee21 You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-site-toolkit][release/5.0] HSTTWO-4167 (cherry pick merge fix) remove unused variable, add final, reuse 'titleKey' variable
Jeroen Hoffman pushed to branch release/5.0 at cms-community / hippo-site-toolkit Commits: 2208d4ff by Jeroen Hoffman at 2017-11-17T11:46:13+01:00 HSTTWO-4167 (cherry pick merge fix) remove unused variable, add final, reuse titleKey variable - - - - - 1 changed file: - client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java Changes: = client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java = --- a/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java +++ b/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java @@ -273,9 +273,8 @@ public class ParametersInfoProcessor { final MultimapfieldGroupProperties = LinkedHashMultimap.create(); for (final Class interfaceClass : getBreadthFirstInterfaceHierarchy(classType)) { -Multimap interfaceClassFieldGroupProperties = LinkedHashMultimap.create(); final FieldGroupList fieldGroupList = interfaceClass.getAnnotation(FieldGroupList.class); -Set uniquePropertiesForInterfaceClass = new HashSet<>(); +final Set uniquePropertiesForInterfaceClass = new HashSet<>(); if (fieldGroupList != null) { final FieldGroup[] fieldGroups = fieldGroupList.value(); if (fieldGroups != null && fieldGroups.length > 0) { @@ -290,10 +289,10 @@ public class ParametersInfoProcessor { final ContainerItemComponentPropertyRepresentation property = propertyMap.get(propertyName); if (!uniquePropertiesForInterfaceClass.add(propertyName)) { log.warn("Ignoring duplicate parameter '{}' in field group '{}' of parameters info interface '{}'", -propertyName, fieldGroup.titleKey(), classType.getCanonicalName()); +propertyName, titleKey, classType.getCanonicalName()); } else if (property == null) { -log.warn("Ignoring unknown parameter '{}' in parameters info interface '{}'", -propertyName, classType.getCanonicalName()); +log.warn("Ignoring unknown parameter '{}' in field group '{}' of parameters info interface '{}'", +propertyName, titleKey, classType.getCanonicalName()); } else if (fieldGroupProperties.containsValue(property)) { // valid if FieldGroup is (re)defined in inherited Info Class log.debug("Parameter '{}' in field group '{}' of parameters info interface '{}' was already added to list.", View it on GitLab: https://code.onehippo.org/cms-community/hippo-site-toolkit/commit/2208d4ffa2039bf8bd56065c11023960bfd8537d --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-site-toolkit/commit/2208d4ffa2039bf8bd56065c11023960bfd8537d You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-site-toolkit][master] 2 commits: HSTTWO-4168 [Fwd port to 12.1] Using Component Info inheritance leads to…
Jeroen Hoffman pushed to branch master at cms-community / hippo-site-toolkit Commits: 633a7e1e by Jeroen Hoffman at 2017-11-17T11:38:08+01:00 HSTTWO-4168 [Fwd port to 12.1] Using Component Info inheritance leads to Ignoring duplicate parameter warnings - - - - - e990b143 by Jeroen Hoffman at 2017-11-17T11:41:09+01:00 HSTTWO-4168 (merge fix) remove unused variable, add final, reuse titleKey variable - - - - - 2 changed files: - client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java - client-modules/page-composer/src/test/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessorTest.java Changes: = client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java = --- a/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java +++ b/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java @@ -20,6 +20,7 @@ import java.lang.reflect.Method; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; +import java.util.HashSet; import java.util.LinkedHashMap; import java.util.List; import java.util.Locale; @@ -273,6 +274,7 @@ public class ParametersInfoProcessor { for (final Class interfaceClass : getBreadthFirstInterfaceHierarchy(classType)) { final FieldGroupList fieldGroupList = interfaceClass.getAnnotation(FieldGroupList.class); +final Set uniquePropertiesForInterfaceClass = new HashSet<>(); if (fieldGroupList != null) { final FieldGroup[] fieldGroups = fieldGroupList.value(); if (fieldGroups != null && fieldGroups.length > 0) { @@ -285,13 +287,19 @@ public class ParametersInfoProcessor { } for (final String propertyName : fieldGroup.value()) { final ContainerItemComponentPropertyRepresentation property = propertyMap.get(propertyName); -if (property == null) { -log.warn("Ignoring unknown parameter '{}' in parameters info interface '{}'", -propertyName, classType.getCanonicalName()); -} else if (fieldGroupProperties.containsValue(property)) { +if (!uniquePropertiesForInterfaceClass.add(propertyName)) { log.warn("Ignoring duplicate parameter '{}' in field group '{}' of parameters info interface '{}'", -new Object[]{ propertyName, fieldGroup.titleKey(), classType.getCanonicalName() }); +propertyName, titleKey, classType.getCanonicalName()); +} else if (property == null) { +log.warn("Ignoring unknown parameter '{}' in field group '{}' of parameters info interface '{}'", +propertyName, titleKey, classType.getCanonicalName()); +} else if (fieldGroupProperties.containsValue(property)) { +// valid if FieldGroup is (re)defined in inherited Info Class +log.debug("Parameter '{}' in field group '{}' of parameters info interface '{}' was already added to list.", + propertyName, fieldGroup.titleKey(), classType.getCanonicalName()); } else { +log.debug("Adding parameter '{}' to field group '{}' of parameters info interface '{}'", +propertyName, titleKey, classType.getCanonicalName()); property.setGroupLabel(groupLabel); fieldGroupProperties.put(titleKey, property); } @@ -362,7 +370,7 @@ public class ParametersInfoProcessor { * hierarchy BREADTH FIRST traversal. Empty array if there are no resource bundles at all */ protected static final ResourceBundle[] getResourceBundles(final ParametersInfo parameterInfo, final Locale locale) { -final List resourceBundles = new ArrayList(); +final List resourceBundles = new ArrayList<>(); final ListbreadthFirstInterfaceHierarchy = getBreadthFirstInterfaceHierarchy(parameterInfo.type()); for (final Class clazz : breadthFirstInterfaceHierarchy) { = client-modules/page-composer/src/test/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessorTest.java = ---
[HippoCMS-scm] [Git][cms-community/hippo-site-toolkit][release/5.0] HSTTWO-4167 [Fwd port to 12.0] Using Component Info inheritance leads to…
Jeroen Hoffman pushed to branch release/5.0 at cms-community / hippo-site-toolkit Commits: d5613a4c by Jeroen Hoffman at 2017-11-17T11:08:43+01:00 HSTTWO-4167 [Fwd port to 12.0] Using Component Info inheritance leads to Ignoring duplicate parameter warnings - - - - - 2 changed files: - client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java - client-modules/page-composer/src/test/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessorTest.java Changes: = client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java = --- a/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java +++ b/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java @@ -20,6 +20,7 @@ import java.lang.reflect.Method; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; +import java.util.HashSet; import java.util.LinkedHashMap; import java.util.List; import java.util.Locale; @@ -272,7 +273,9 @@ public class ParametersInfoProcessor { final MultimapfieldGroupProperties = LinkedHashMultimap.create(); for (final Class interfaceClass : getBreadthFirstInterfaceHierarchy(classType)) { +Multimap interfaceClassFieldGroupProperties = LinkedHashMultimap.create(); final FieldGroupList fieldGroupList = interfaceClass.getAnnotation(FieldGroupList.class); +Set uniquePropertiesForInterfaceClass = new HashSet<>(); if (fieldGroupList != null) { final FieldGroup[] fieldGroups = fieldGroupList.value(); if (fieldGroups != null && fieldGroups.length > 0) { @@ -285,13 +288,19 @@ public class ParametersInfoProcessor { } for (final String propertyName : fieldGroup.value()) { final ContainerItemComponentPropertyRepresentation property = propertyMap.get(propertyName); -if (property == null) { +if (!uniquePropertiesForInterfaceClass.add(propertyName)) { +log.warn("Ignoring duplicate parameter '{}' in field group '{}' of parameters info interface '{}'", +propertyName, fieldGroup.titleKey(), classType.getCanonicalName()); +} else if (property == null) { log.warn("Ignoring unknown parameter '{}' in parameters info interface '{}'", propertyName, classType.getCanonicalName()); } else if (fieldGroupProperties.containsValue(property)) { -log.warn("Ignoring duplicate parameter '{}' in field group '{}' of parameters info interface '{}'", -new Object[]{ propertyName, fieldGroup.titleKey(), classType.getCanonicalName() }); +// valid if FieldGroup is (re)defined in inherited Info Class +log.debug("Parameter '{}' in field group '{}' of parameters info interface '{}' was already added to list.", + propertyName, fieldGroup.titleKey(), classType.getCanonicalName()); } else { +log.debug("Adding parameter '{}' to field group '{}' of parameters info interface '{}'", +propertyName, titleKey, classType.getCanonicalName()); property.setGroupLabel(groupLabel); fieldGroupProperties.put(titleKey, property); } @@ -362,7 +371,7 @@ public class ParametersInfoProcessor { * hierarchy BREADTH FIRST traversal. Empty array if there are no resource bundles at all */ protected static final ResourceBundle[] getResourceBundles(final ParametersInfo parameterInfo, final Locale locale) { -final List resourceBundles = new ArrayList(); +final List resourceBundles = new ArrayList<>(); final List breadthFirstInterfaceHierarchy = getBreadthFirstInterfaceHierarchy(parameterInfo.type()); for (final Class clazz : breadthFirstInterfaceHierarchy) { = client-modules/page-composer/src/test/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessorTest.java = --- a/client-modules/page-composer/src/test/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessorTest.java +++
[HippoCMS-scm] [Git][cms-community/hippo-site-toolkit] Deleted branch bugfix/HSTTWO-4163
Jeroen Hoffman deleted branch bugfix/HSTTWO-4163 at cms-community / hippo-site-toolkit --- You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn
[HippoCMS-scm] [Git][cms-community/hippo-site-toolkit][release/4.2] 6 commits: HSTTWO-4163 only warn about duplicate field group properties defined in the same class
Jeroen Hoffman pushed to branch release/4.2 at cms-community / hippo-site-toolkit Commits: 0a1e08b8 by Bert Leunis at 2017-11-09T16:18:43+01:00 HSTTWO-4163 only warn about duplicate field group properties defined in the same class - - - - - ca4bc4d6 by Bert Leunis at 2017-11-10T13:51:41+01:00 HSTTWO-4163 warning for duplicates in the same class, logging of duplicate properties overall now debug level - - - - - de1318df by Jeroen Hoffman at 2017-11-15T14:25:12+01:00 HSTTWO-4163 Merge branch release/4.2 into bugfix/HSTTWO-4163 - - - - - bf4f04bb by Jeroen Hoffman at 2017-11-15T15:33:53+01:00 HSTTWO-4163 reuse titleKey variable; add a final - - - - - f2c762a8 by Jeroen Hoffman at 2017-11-15T16:35:37+01:00 HSTTWO-4163 add debug statement for when adding a parameter to a field group - - - - - d39a04f7 by Jeroen Hoffman at 2017-11-17T10:47:58+01:00 HSTTWO-4163 Reintegrate branch bugfix/HSTTWO-4163 into release/4.2 - - - - - 2 changed files: - client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java - client-modules/page-composer/src/test/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessorTest.java Changes: = client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java = --- a/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java +++ b/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/model/ParametersInfoProcessor.java @@ -1,5 +1,5 @@ /* - * Copyright 2011-2016 Hippo B.V. (http://www.onehippo.com) + * Copyright 2011-2017 Hippo B.V. (http://www.onehippo.com) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -20,6 +20,7 @@ import java.lang.reflect.Method; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; +import java.util.HashSet; import java.util.LinkedHashMap; import java.util.List; import java.util.Locale; @@ -240,6 +241,7 @@ public class ParametersInfoProcessor { for (Class interfaceClass : getBreadthFirstInterfaceHierarchy(classType)) { final FieldGroupList fieldGroupList = interfaceClass.getAnnotation(FieldGroupList.class); +final Set uniquePropertiesForInterfaceClass = new HashSet<>(); if (fieldGroupList != null) { FieldGroup[] fieldGroups = fieldGroupList.value(); if (fieldGroups != null && fieldGroups.length > 0) { @@ -252,13 +254,19 @@ public class ParametersInfoProcessor { } for (final String propertyName : fieldGroup.value()) { final ContainerItemComponentPropertyRepresentation property = propertyMap.get(propertyName); -if (property == null) { -log.warn("Ignoring unknown parameter '{}' in parameters info interface '{}'", -propertyName, classType.getCanonicalName()); -} else if (fieldGroupProperties.containsValue(property)) { +if (!uniquePropertiesForInterfaceClass.add(propertyName)) { log.warn("Ignoring duplicate parameter '{}' in field group '{}' of parameters info interface '{}'", -new Object[]{ propertyName, fieldGroup.titleKey(), classType.getCanonicalName() }); +propertyName, titleKey, classType.getCanonicalName()); +} else if (property == null) { +log.warn("Ignoring unknown parameter '{}' in field group '{}' of parameters info interface '{}'", +propertyName, titleKey, classType.getCanonicalName()); +} else if (fieldGroupProperties.containsValue(property)) { +// valid if FieldGroup is (re)defined in inherited Info Class +log.debug("Parameter '{}' in field group '{}' of parameters info interface '{}' was already added to list.", + propertyName, titleKey, classType.getCanonicalName()); } else { +log.debug("Adding parameter '{}' to field group '{}' of parameters info interface '{}'", +propertyName, titleKey, classType.getCanonicalName()); property.setGroupLabel(groupLabel); fieldGroupProperties.put(titleKey, property); } @@ -329,7 +337,7 @@ public class ParametersInfoProcessor { * hierarchy
[HippoCMS-scm] [Git][cms-community/hippo-addon-channel-manager] Pushed new branch feature/CHANNELMGR-1578
Joeri de Gooijer pushed new branch feature/CHANNELMGR-1578 at cms-community / hippo-addon-channel-manager --- View it on GitLab: https://code.onehippo.org/cms-community/hippo-addon-channel-manager/tree/feature/CHANNELMGR-1578 You're receiving this email because of your account on code.onehippo.org. ___ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn