From f511436823b0cd007e7acd5abde523e0707ae43c Mon Sep 17 00:00:00 2001 From: Maciej Pichura <41297682+mpichura@users.noreply.github.com> Date: Thu, 8 Dec 2022 17:40:56 +0100 Subject: [PATCH 01/37] ACS-4032 create category (multiple categories pagination fix) (#1610) * ACS-4032: Some fixes and refactors after verification. Fixing pagination info on POST multiple entities response. * ACS-4032: Some fixes and refactors after verification. Fixing pagination info on POST multiple entities response. * Fixing a test STEP description Co-authored-by: Tom Page Co-authored-by: Tom Page --- .../alfresco/rest/requests/Categories.java | 2 +- .../categories/CreateCategoriesTests.java | 67 +++++++++++++++++++ .../alfresco/rest/rules/CreateRulesTests.java | 34 ++++++++++ .../rest/api/impl/CategoriesImpl.java | 12 +++- .../webscripts/ResourceWebScriptPost.java | 4 +- 5 files changed, 116 insertions(+), 3 deletions(-) diff --git a/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java b/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java index 460ae87a3f..e5a3843201 100644 --- a/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java +++ b/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java @@ -47,7 +47,7 @@ public class Categories extends ModelRequest } /** - * Retrieves a category with ID using GET call on using GET call on "/tags/{tagId}" + * Retrieves a category with ID using GET call on "/categories/{categoryId}" * * @return RestCategoryModel */ diff --git a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java index edfc95d36f..74200018f0 100644 --- a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java +++ b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java @@ -44,6 +44,7 @@ import org.alfresco.utility.model.FolderModel; import org.alfresco.utility.model.SiteModel; import org.alfresco.utility.model.TestGroup; import org.alfresco.utility.model.UserModel; +import org.apache.commons.lang3.StringUtils; import org.testng.annotations.BeforeClass; import org.testng.annotations.Test; @@ -84,6 +85,24 @@ public class CreateCategoriesTests extends RestTest createdCategory.assertThat().field(FIELD_HAS_CHILDREN).is(false); } + /** + * Check we get 400 error when attempting to create a category with empty name + */ + @Test(groups = {TestGroup.REST_API}) + public void testCreateCategoryWithoutName_andFail() + { + STEP("Create a category under root category (as admin)"); + final RestCategoryModel rootCategory = new RestCategoryModel(); + rootCategory.setId("-root-"); + final RestCategoryModel aCategory = new RestCategoryModel(); + aCategory.setName(StringUtils.EMPTY); + restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(rootCategory) + .createSingleCategory(aCategory); + restClient.assertStatusCodeIs(BAD_REQUEST).assertLastError().containsSummary("Category name must not be null or empty"); + } + /** * Check we can create several categories as children of a created category */ @@ -134,6 +153,54 @@ public class CreateCategoriesTests extends RestTest parentCategoryFromGet.assertThat().field(FIELD_HAS_CHILDREN).is(true); } + /** + * Check we can create over 100 categories as children of a created category and pagination information is proper. + */ + @Test(groups = {TestGroup.REST_API}) + public void testCreateOver100SubCategories() + { + STEP("Create a category under root category (as admin)"); + final RestCategoryModel rootCategory = new RestCategoryModel(); + rootCategory.setId("-root-"); + final RestCategoryModel aCategory = new RestCategoryModel(); + aCategory.setName(RandomData.getRandomName("Category")); + final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(rootCategory) + .createSingleCategory(aCategory); + restClient.assertStatusCodeIs(CREATED); + + createdCategory.assertThat().field(FIELD_NAME).is(aCategory.getName()) + .assertThat().field(FIELD_PARENT_ID).is(rootCategory.getId()) + .assertThat().field(FIELD_HAS_CHILDREN).is(false) + .assertThat().field(FIELD_ID).isNotEmpty(); + + STEP("Create more than a hundred categories under the previously created (as admin)"); + final int categoriesNumber = 120; + final List categoriesToCreate = getCategoriesToCreate(categoriesNumber); + final RestCategoryModelsCollection createdSubCategories = restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(createdCategory) + .createCategoriesList(categoriesToCreate); + restClient.assertStatusCodeIs(CREATED); + + createdSubCategories.assertThat() + .entriesListCountIs(categoriesToCreate.size()); + IntStream.range(0, categoriesNumber) + .forEach(i -> createdSubCategories.getEntries().get(i).onModel() + .assertThat().field(FIELD_NAME).is(categoriesToCreate.get(i).getName()) + .assertThat().field(FIELD_PARENT_ID).is(createdCategory.getId()) + .assertThat().field(FIELD_HAS_CHILDREN).is(false) + .assertThat().field(FIELD_ID).isNotEmpty() + ); + createdSubCategories.getPagination().assertThat().field("count").is(categoriesNumber) + .assertThat().field("totalItems").is(categoriesNumber) + .assertThat().field("maxItems").is(categoriesNumber) + .assertThat().field("skipCount").is(0) + .assertThat().field("hasMoreItems").is(false); + + } + /** * Check we cannot create a category as direct child of root category as non-admin user */ diff --git a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/rules/CreateRulesTests.java b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/rules/CreateRulesTests.java index cf4888952b..8b195e3ebd 100644 --- a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/rules/CreateRulesTests.java +++ b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/rules/CreateRulesTests.java @@ -56,6 +56,7 @@ import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.stream.Collectors; import java.util.stream.IntStream; import javax.json.Json; import javax.json.JsonObject; @@ -63,6 +64,7 @@ import javax.json.JsonObject; import org.alfresco.rest.model.RestActionBodyExecTemplateModel; import org.alfresco.rest.model.RestActionConstraintModel; import org.alfresco.rest.model.RestCompositeConditionDefinitionModel; +import org.alfresco.rest.model.RestPaginationModel; import org.alfresco.rest.model.RestRuleModel; import org.alfresco.rest.model.RestRuleModelsCollection; import org.alfresco.utility.constants.UserRole; @@ -267,6 +269,38 @@ public class CreateRulesTests extends RulesRestTest .assertThat().field("name").is(ruleNames.get(i))); } + /** Check we can create over 100 rules and get them all back in response. */ + @Test (groups = { TestGroup.REST_API, TestGroup.RULES }) + public void createOver100Rules() + { + STEP("Create a list of 120 rules in one POST request"); + final int ruleCount = 120; + final String ruleNamePrefix = "multiRule"; + final List ruleModels = IntStream.rangeClosed(1, ruleCount) + .mapToObj(i -> rulesUtils.createRuleModel(ruleNamePrefix + i)) + .collect(Collectors.toList()); + + final FolderModel aFolder = dataContent.usingUser(user).usingSite(site).createFolder(); + final RestRuleModelsCollection rules = restClient.authenticateUser(user).withPrivateAPI().usingNode(aFolder).usingDefaultRuleSet() + .createListOfRules(ruleModels); + + restClient.assertStatusCodeIs(CREATED); + + assertEquals("Unexpected number of rules received in response.", ruleCount, rules.getEntries().size()); + IntStream.range(0, ruleModels.size()).forEach(i -> + rules.getEntries().get(i).onModel() + .assertThat().field("id").isNotNull() + .assertThat().field("name").is(ruleNamePrefix + (i + 1))); + + rules.getPagination() + .assertThat().field("count").is(ruleCount) + .assertThat().field("totalItems").is(ruleCount) + .assertThat().field("maxItems").is(ruleCount) + .assertThat().field("skipCount").is(0) + .assertThat().field("hasMoreItems").is(false); + + } + /** Try to create several rules with an error in one of them. */ @Test (groups = { TestGroup.REST_API, TestGroup.RULES }) public void createRulesWithOneError() diff --git a/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java b/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java index 28f452ea31..8db2796b16 100644 --- a/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java +++ b/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java @@ -49,12 +49,14 @@ import org.alfresco.service.cmr.search.CategoryService; import org.alfresco.service.cmr.security.AuthorityService; import org.alfresco.service.namespace.RegexQNamePattern; import org.apache.commons.collections.CollectionUtils; +import org.apache.commons.lang3.StringUtils; @Experimental public class CategoriesImpl implements Categories { static final String NOT_A_VALID_CATEGORY = "Node id does not refer to a valid category"; static final String NO_PERMISSION_TO_CREATE_A_CATEGORY = "Current user does not have permission to create a category"; + private static final String NOT_NULL_OR_EMPTY = "Category name must not be null or empty"; private final AuthorityService authorityService; private final CategoryService categoryService; @@ -97,13 +99,21 @@ public class CategoriesImpl implements Categories throw new InvalidArgumentException(NOT_A_VALID_CATEGORY, new String[]{parentCategoryId}); } final List categoryNodeRefs = categories.stream() - .map(c -> categoryService.createCategory(parentNodeRef, c.getName())) + .map(c -> createCategoryNodeRef(parentNodeRef, c)) .collect(Collectors.toList()); return categoryNodeRefs.stream() .map(this::mapToCategory) .collect(Collectors.toList()); } + private NodeRef createCategoryNodeRef(NodeRef parentNodeRef, Category c) + { + if (StringUtils.isEmpty(c.getName())) { + throw new InvalidArgumentException(NOT_NULL_OR_EMPTY); + } + return categoryService.createCategory(parentNodeRef, c.getName()); + } + private boolean isNotACategory(NodeRef nodeRef) { return !nodes.isSubClass(nodeRef, ContentModel.TYPE_CATEGORY, false); diff --git a/remote-api/src/main/java/org/alfresco/rest/framework/webscripts/ResourceWebScriptPost.java b/remote-api/src/main/java/org/alfresco/rest/framework/webscripts/ResourceWebScriptPost.java index 5fcd23b332..1d3500a596 100644 --- a/remote-api/src/main/java/org/alfresco/rest/framework/webscripts/ResourceWebScriptPost.java +++ b/remote-api/src/main/java/org/alfresco/rest/framework/webscripts/ResourceWebScriptPost.java @@ -44,6 +44,7 @@ import org.alfresco.rest.framework.resource.actions.interfaces.MultiPartResource import org.alfresco.rest.framework.resource.actions.interfaces.MultiPartRelationshipResourceAction; import org.alfresco.rest.framework.resource.actions.interfaces.RelationshipResourceAction; import org.alfresco.rest.framework.resource.parameters.CollectionWithPagingInfo; +import org.alfresco.rest.framework.resource.parameters.Paging; import org.alfresco.rest.framework.resource.parameters.Params; import org.alfresco.rest.framework.resource.parameters.Params.RecognizedParams; import org.alfresco.rest.framework.tools.RecognizedParamsExtractor; @@ -377,7 +378,8 @@ public class ResourceWebScriptPost extends AbstractResourceWebScript implements { if (created !=null && created.size() > 1) { - return CollectionWithPagingInfo.asPagedCollection(created.toArray()); + final Paging pagingAll = Paging.valueOf(0, created.size()); + return CollectionWithPagingInfo.asPaged(pagingAll, created); } else { From 06a25a48daef7c32c6fd882bae56711266b7ee3e Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Thu, 8 Dec 2022 17:19:01 +0000 Subject: [PATCH 02/37] [maven-release-plugin][skip ci] prepare release 20.38 --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index cf4a3386a4..f3803596d2 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.38-SNAPSHOT + 20.38 diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 7318a2532d..e3d84940a0 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.38-SNAPSHOT + 20.38 diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 609655602e..d8ca010692 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.38-SNAPSHOT + 20.38 diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index e9192e384f..f25ec8fcb8 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.38-SNAPSHOT + 20.38 diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index ebf65c7b3f..eac7990678 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.38-SNAPSHOT + 20.38 diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index d70eac8adc..3561d37526 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.38-SNAPSHOT + 20.38 diff --git a/amps/pom.xml b/amps/pom.xml index 8a04186766..e21ad896a8 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38-SNAPSHOT + 20.38 diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index 9af36da4ba..8921b8edf9 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.38-SNAPSHOT + 20.38 diff --git a/core/pom.xml b/core/pom.xml index c3f86f82be..9b085ef85e 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38-SNAPSHOT + 20.38 diff --git a/data-model/pom.xml b/data-model/pom.xml index d1ab881e19..71b5565b24 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38-SNAPSHOT + 20.38 diff --git a/mmt/pom.xml b/mmt/pom.xml index 2db4e39189..4c9b66f0fc 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38-SNAPSHOT + 20.38 diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 2ff114b42c..42af4169bf 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.38-SNAPSHOT + 20.38 diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 3b738c9057..65f6ec95df 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.38-SNAPSHOT + 20.38 diff --git a/packaging/pom.xml b/packaging/pom.xml index 6bc332b0fd..fbe5788dfc 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38-SNAPSHOT + 20.38 diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 4069327bff..c100522a5c 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.38-SNAPSHOT + 20.38 diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 113072ab83..78e5f154ff 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.38-SNAPSHOT + 20.38 diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index c0a373d1c6..7dd74e82b1 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.38-SNAPSHOT + 20.38 diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index d6620f0da1..f94fc396f5 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.38-SNAPSHOT + 20.38 diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 701ab667dc..03c6b91881 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.38-SNAPSHOT + 20.38 diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 6087a467c0..7ba2c5d3ba 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.38-SNAPSHOT + 20.38 diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 6c9ef0a9ce..9f1c447447 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.38-SNAPSHOT + 20.38 diff --git a/pom.xml b/pom.xml index ec13bb64e9..ec65732b43 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.38-SNAPSHOT + 20.38 pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - HEAD + 20.38 diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 8dbe2825b2..dd071a3d9e 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38-SNAPSHOT + 20.38 diff --git a/repository/pom.xml b/repository/pom.xml index 61c8d1f079..3e75d5ced3 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38-SNAPSHOT + 20.38 From 5c434f7898bd4e96f5977d7ce525a790a25bb17e Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Thu, 8 Dec 2022 17:19:04 +0000 Subject: [PATCH 03/37] [maven-release-plugin][skip ci] prepare for next development iteration --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index f3803596d2..ec1ede461c 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.38 + 20.39-SNAPSHOT diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index e3d84940a0..112e7feb86 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.38 + 20.39-SNAPSHOT diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index d8ca010692..48dbd84c54 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.38 + 20.39-SNAPSHOT diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index f25ec8fcb8..51ff7f06a9 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.38 + 20.39-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index eac7990678..64fdb4a007 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.38 + 20.39-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 3561d37526..7d6784756a 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.38 + 20.39-SNAPSHOT diff --git a/amps/pom.xml b/amps/pom.xml index e21ad896a8..b58b1a3b3a 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38 + 20.39-SNAPSHOT diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index 8921b8edf9..8eac86238a 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.38 + 20.39-SNAPSHOT diff --git a/core/pom.xml b/core/pom.xml index 9b085ef85e..c74bdd832d 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38 + 20.39-SNAPSHOT diff --git a/data-model/pom.xml b/data-model/pom.xml index 71b5565b24..f478a6724d 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38 + 20.39-SNAPSHOT diff --git a/mmt/pom.xml b/mmt/pom.xml index 4c9b66f0fc..6aa5cabe04 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38 + 20.39-SNAPSHOT diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 42af4169bf..865dd86aea 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.38 + 20.39-SNAPSHOT diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 65f6ec95df..18f77474c2 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.38 + 20.39-SNAPSHOT diff --git a/packaging/pom.xml b/packaging/pom.xml index fbe5788dfc..cb5ccb7466 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38 + 20.39-SNAPSHOT diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index c100522a5c..8846185304 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.38 + 20.39-SNAPSHOT diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 78e5f154ff..7cb5b6b8fc 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.38 + 20.39-SNAPSHOT diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 7dd74e82b1..8092dc7c77 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.38 + 20.39-SNAPSHOT diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index f94fc396f5..dd9681b8a6 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.38 + 20.39-SNAPSHOT diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 03c6b91881..6a846563db 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.38 + 20.39-SNAPSHOT diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 7ba2c5d3ba..c43e8c74dc 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.38 + 20.39-SNAPSHOT diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 9f1c447447..f8632923f5 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.38 + 20.39-SNAPSHOT diff --git a/pom.xml b/pom.xml index ec65732b43..06942a350d 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.38 + 20.39-SNAPSHOT pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - 20.38 + HEAD diff --git a/remote-api/pom.xml b/remote-api/pom.xml index dd071a3d9e..891c1e8cbf 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38 + 20.39-SNAPSHOT diff --git a/repository/pom.xml b/repository/pom.xml index 3e75d5ced3..e8b00af387 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.38 + 20.39-SNAPSHOT From d9bbc9c62848c6199642e79edd12767578e099ec Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 9 Dec 2022 10:53:15 +0100 Subject: [PATCH 04/37] Bump alfresco-googledrive-repo-community (#1611) Bumps [alfresco-googledrive-repo-community](https://github.com/Alfresco/googledrive) from 3.3.1-DEV-LOG4J2 to 3.4.0-A1. - [Release notes](https://github.com/Alfresco/googledrive/releases) - [Changelog](https://github.com/Alfresco/googledrive/blob/master/docs/build-and-release-101.md) - [Commits](https://github.com/Alfresco/googledrive/compare/3.3.1-DEV-LOG4J2...3.4.0-A1) --- updated-dependencies: - dependency-name: org.alfresco.integrations:alfresco-googledrive-repo-community dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 06942a350d..e990f8658e 100644 --- a/pom.xml +++ b/pom.xml @@ -109,7 +109,7 @@ 2.7.0 1.1.4 - 3.3.1-DEV-LOG4J2 + 3.4.0-A1 1.6.0-A1 7.3.0 From eb7bcbfbfbb8b86c6e44c5212e8276cc8c8efbae Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Fri, 9 Dec 2022 10:34:02 +0000 Subject: [PATCH 05/37] [maven-release-plugin][skip ci] prepare release 20.39 --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index ec1ede461c..ccead6a5e9 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.39-SNAPSHOT + 20.39 diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 112e7feb86..29a68c1b95 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.39-SNAPSHOT + 20.39 diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 48dbd84c54..54c62de4db 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.39-SNAPSHOT + 20.39 diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 51ff7f06a9..c9499341e0 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.39-SNAPSHOT + 20.39 diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 64fdb4a007..ee2f1ec068 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.39-SNAPSHOT + 20.39 diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 7d6784756a..354cffbc95 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.39-SNAPSHOT + 20.39 diff --git a/amps/pom.xml b/amps/pom.xml index b58b1a3b3a..bebe5a8821 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39-SNAPSHOT + 20.39 diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index 8eac86238a..05c6da22e6 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.39-SNAPSHOT + 20.39 diff --git a/core/pom.xml b/core/pom.xml index c74bdd832d..393de03336 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39-SNAPSHOT + 20.39 diff --git a/data-model/pom.xml b/data-model/pom.xml index f478a6724d..884f746543 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39-SNAPSHOT + 20.39 diff --git a/mmt/pom.xml b/mmt/pom.xml index 6aa5cabe04..cab238c5b1 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39-SNAPSHOT + 20.39 diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 865dd86aea..f401b64a38 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.39-SNAPSHOT + 20.39 diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 18f77474c2..b55d83421a 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.39-SNAPSHOT + 20.39 diff --git a/packaging/pom.xml b/packaging/pom.xml index cb5ccb7466..c25cf5d6f5 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39-SNAPSHOT + 20.39 diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 8846185304..f6a4ff8063 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.39-SNAPSHOT + 20.39 diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 7cb5b6b8fc..eddfa8407b 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.39-SNAPSHOT + 20.39 diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 8092dc7c77..6a8de7228b 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.39-SNAPSHOT + 20.39 diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index dd9681b8a6..36e5af3e4d 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.39-SNAPSHOT + 20.39 diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 6a846563db..20960f51f4 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.39-SNAPSHOT + 20.39 diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index c43e8c74dc..ff425f9020 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.39-SNAPSHOT + 20.39 diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index f8632923f5..2fd4f1b082 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.39-SNAPSHOT + 20.39 diff --git a/pom.xml b/pom.xml index e990f8658e..f78e35b62d 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.39-SNAPSHOT + 20.39 pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - HEAD + 20.39 diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 891c1e8cbf..96f26fb558 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39-SNAPSHOT + 20.39 diff --git a/repository/pom.xml b/repository/pom.xml index e8b00af387..1795c260c1 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39-SNAPSHOT + 20.39 From 0f8349dc4cdeaaeabae850e4649c407d28f9909f Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Fri, 9 Dec 2022 10:34:04 +0000 Subject: [PATCH 06/37] [maven-release-plugin][skip ci] prepare for next development iteration --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index ccead6a5e9..db9279816f 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.39 + 20.40-SNAPSHOT diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 29a68c1b95..398862b744 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.39 + 20.40-SNAPSHOT diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 54c62de4db..f040d19d73 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.39 + 20.40-SNAPSHOT diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index c9499341e0..d6e75b8abb 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.39 + 20.40-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index ee2f1ec068..80f1d81962 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.39 + 20.40-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 354cffbc95..13685b7f52 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.39 + 20.40-SNAPSHOT diff --git a/amps/pom.xml b/amps/pom.xml index bebe5a8821..af7398f7e2 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39 + 20.40-SNAPSHOT diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index 05c6da22e6..d44b17a115 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.39 + 20.40-SNAPSHOT diff --git a/core/pom.xml b/core/pom.xml index 393de03336..c912cfa7ae 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39 + 20.40-SNAPSHOT diff --git a/data-model/pom.xml b/data-model/pom.xml index 884f746543..654a13c86a 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39 + 20.40-SNAPSHOT diff --git a/mmt/pom.xml b/mmt/pom.xml index cab238c5b1..9e3c06bcd6 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39 + 20.40-SNAPSHOT diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index f401b64a38..9dfbf1e850 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.39 + 20.40-SNAPSHOT diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index b55d83421a..65a0fccf14 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.39 + 20.40-SNAPSHOT diff --git a/packaging/pom.xml b/packaging/pom.xml index c25cf5d6f5..49495fb920 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39 + 20.40-SNAPSHOT diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index f6a4ff8063..666f589c04 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.39 + 20.40-SNAPSHOT diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index eddfa8407b..fbc66c3dae 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.39 + 20.40-SNAPSHOT diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 6a8de7228b..e785567b1c 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.39 + 20.40-SNAPSHOT diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index 36e5af3e4d..43a5f6db49 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.39 + 20.40-SNAPSHOT diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 20960f51f4..7280590db7 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.39 + 20.40-SNAPSHOT diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index ff425f9020..530386f507 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.39 + 20.40-SNAPSHOT diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 2fd4f1b082..cfedd3bab8 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.39 + 20.40-SNAPSHOT diff --git a/pom.xml b/pom.xml index f78e35b62d..b7d7520fb7 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.39 + 20.40-SNAPSHOT pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - 20.39 + HEAD diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 96f26fb558..9e11ae2823 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39 + 20.40-SNAPSHOT diff --git a/repository/pom.xml b/repository/pom.xml index 1795c260c1..bb9e2ee439 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.39 + 20.40-SNAPSHOT From ace6eca99b5ce780510dbb09935ccf9a7cbf4abf Mon Sep 17 00:00:00 2001 From: Alfresco CI User Date: Sun, 11 Dec 2022 00:03:34 +0000 Subject: [PATCH 07/37] [force] Force release for 2022-12-11. From 6bd50fda1ad3115cddbed0f8dbeaa19900cae047 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Sun, 11 Dec 2022 00:10:52 +0000 Subject: [PATCH 08/37] [maven-release-plugin][skip ci] prepare release 20.40 --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index db9279816f..c51e8d76d5 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.40-SNAPSHOT + 20.40 diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 398862b744..36c7462df4 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.40-SNAPSHOT + 20.40 diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index f040d19d73..68ec4bac53 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.40-SNAPSHOT + 20.40 diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index d6e75b8abb..c5ab1f3823 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.40-SNAPSHOT + 20.40 diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 80f1d81962..f370ec0cb9 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.40-SNAPSHOT + 20.40 diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 13685b7f52..befa50c54b 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.40-SNAPSHOT + 20.40 diff --git a/amps/pom.xml b/amps/pom.xml index af7398f7e2..2f6d2aab21 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40-SNAPSHOT + 20.40 diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index d44b17a115..c85a64147f 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.40-SNAPSHOT + 20.40 diff --git a/core/pom.xml b/core/pom.xml index c912cfa7ae..f98ef60fb0 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40-SNAPSHOT + 20.40 diff --git a/data-model/pom.xml b/data-model/pom.xml index 654a13c86a..ea28d1a294 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40-SNAPSHOT + 20.40 diff --git a/mmt/pom.xml b/mmt/pom.xml index 9e3c06bcd6..436954ed39 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40-SNAPSHOT + 20.40 diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 9dfbf1e850..a505db1f60 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.40-SNAPSHOT + 20.40 diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 65a0fccf14..67f16b86f8 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.40-SNAPSHOT + 20.40 diff --git a/packaging/pom.xml b/packaging/pom.xml index 49495fb920..802cee85c5 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40-SNAPSHOT + 20.40 diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 666f589c04..e3385bdabe 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.40-SNAPSHOT + 20.40 diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index fbc66c3dae..e7fb700f54 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.40-SNAPSHOT + 20.40 diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index e785567b1c..236214a684 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.40-SNAPSHOT + 20.40 diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index 43a5f6db49..e3553a72e6 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.40-SNAPSHOT + 20.40 diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 7280590db7..35214d0a4a 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.40-SNAPSHOT + 20.40 diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 530386f507..6f87c12e46 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.40-SNAPSHOT + 20.40 diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index cfedd3bab8..7d02220358 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.40-SNAPSHOT + 20.40 diff --git a/pom.xml b/pom.xml index b7d7520fb7..c2caecf444 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.40-SNAPSHOT + 20.40 pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - HEAD + 20.40 diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 9e11ae2823..00e0267f4b 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40-SNAPSHOT + 20.40 diff --git a/repository/pom.xml b/repository/pom.xml index bb9e2ee439..d590c2538e 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40-SNAPSHOT + 20.40 From c1198a0145e4a51d54058b71d70c1d87da85093f Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Sun, 11 Dec 2022 00:10:54 +0000 Subject: [PATCH 09/37] [maven-release-plugin][skip ci] prepare for next development iteration --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index c51e8d76d5..368fdadb2a 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.40 + 20.41-SNAPSHOT diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 36c7462df4..83f4b18ca1 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.40 + 20.41-SNAPSHOT diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 68ec4bac53..92d6cb86a9 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.40 + 20.41-SNAPSHOT diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index c5ab1f3823..a149001911 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.40 + 20.41-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index f370ec0cb9..0a07aa28ee 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.40 + 20.41-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index befa50c54b..dae56a6e0b 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.40 + 20.41-SNAPSHOT diff --git a/amps/pom.xml b/amps/pom.xml index 2f6d2aab21..d4dbb3a5fd 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40 + 20.41-SNAPSHOT diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index c85a64147f..ed0697c0b4 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.40 + 20.41-SNAPSHOT diff --git a/core/pom.xml b/core/pom.xml index f98ef60fb0..f95335b303 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40 + 20.41-SNAPSHOT diff --git a/data-model/pom.xml b/data-model/pom.xml index ea28d1a294..dcae4f74c3 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40 + 20.41-SNAPSHOT diff --git a/mmt/pom.xml b/mmt/pom.xml index 436954ed39..c84563075c 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40 + 20.41-SNAPSHOT diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index a505db1f60..24937dadcc 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.40 + 20.41-SNAPSHOT diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 67f16b86f8..70dc62b2ae 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.40 + 20.41-SNAPSHOT diff --git a/packaging/pom.xml b/packaging/pom.xml index 802cee85c5..a6f54d86f8 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40 + 20.41-SNAPSHOT diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index e3385bdabe..ef43555ad2 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.40 + 20.41-SNAPSHOT diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index e7fb700f54..11b8729383 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.40 + 20.41-SNAPSHOT diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 236214a684..312f92e976 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.40 + 20.41-SNAPSHOT diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index e3553a72e6..a5b26852cb 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.40 + 20.41-SNAPSHOT diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 35214d0a4a..258f4aa6fb 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.40 + 20.41-SNAPSHOT diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 6f87c12e46..21614ddd38 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.40 + 20.41-SNAPSHOT diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 7d02220358..0cae073a7c 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.40 + 20.41-SNAPSHOT diff --git a/pom.xml b/pom.xml index c2caecf444..e7e4878733 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.40 + 20.41-SNAPSHOT pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - 20.40 + HEAD diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 00e0267f4b..38a8d8cffb 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40 + 20.41-SNAPSHOT diff --git a/repository/pom.xml b/repository/pom.xml index d590c2538e..0b74a64168 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.40 + 20.41-SNAPSHOT From 0aae95b2554a53550251aa11260bf69c3b9a67f4 Mon Sep 17 00:00:00 2001 From: Maciej Pichura <41297682+mpichura@users.noreply.github.com> Date: Tue, 13 Dec 2022 17:13:02 +0100 Subject: [PATCH 10/37] ACS-4031 list category children (#1617) * ACS-4031: Get category children endpoint. * ACS-4031: Fix in E2E test. * ACS-4031: Adding more unit tests. * Fix test description Co-authored-by: Tom Page * Fix test description Co-authored-by: Tom Page * ACS-4031: Refactoring after code review. * ACS-4031: Updating E2E test after latest logic refactor. Co-authored-by: Tom Page --- .../alfresco/rest/requests/Categories.java | 18 +- .../categories/CreateCategoriesTests.java | 2 +- .../rest/categories/GetCategoriesTests.java | 143 ++++++++++++- .../org/alfresco/rest/api/Categories.java | 3 + .../api/categories/SubcategoriesRelation.java | 12 +- .../rest/api/impl/CategoriesImpl.java | 58 +++++- .../categories/SubcategoriesRelationTest.java | 105 ++++++++++ .../rest/api/impl/CategoriesImplTest.java | 189 +++++++++++++++++- 8 files changed, 501 insertions(+), 29 deletions(-) create mode 100644 remote-api/src/test/java/org/alfresco/rest/api/categories/SubcategoriesRelationTest.java diff --git a/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java b/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java index e5a3843201..27ed2f5bc7 100644 --- a/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java +++ b/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java @@ -33,7 +33,6 @@ import org.alfresco.rest.core.RestRequest; import org.alfresco.rest.core.RestWrapper; import org.alfresco.rest.model.RestCategoryModel; import org.alfresco.rest.model.RestCategoryModelsCollection; -import org.alfresco.rest.model.RestRuleModelsCollection; import org.springframework.http.HttpMethod; public class Categories extends ModelRequest @@ -75,9 +74,22 @@ public class Categories extends ModelRequest * @param restCategoryModel The categories to create. * @return Created category with additional data populated by the repository. */ - public RestCategoryModel createSingleCategory(RestCategoryModel restCategoryModel) { - RestRequest request = RestRequest.requestWithBody(HttpMethod.POST, restCategoryModel.toJson(), "categories/{categoryId}/subcategories", category.getId()); + public RestCategoryModel createSingleCategory(RestCategoryModel restCategoryModel) + { + RestRequest request = RestRequest + .requestWithBody(HttpMethod.POST, restCategoryModel.toJson(), "categories/{categoryId}/subcategories", category.getId()); return restWrapper.processModel(RestCategoryModel.class, request); } + /** + * Get parent category children. + * + * @return The list of child categories. + */ + public RestCategoryModelsCollection getCategoryChildren() + { + RestRequest request = RestRequest.simpleRequest(HttpMethod.GET, "categories/{categoryId}/subcategories", category.getId()); + return restWrapper.processModels(RestCategoryModelsCollection.class, request); + } + } diff --git a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java index 74200018f0..68e199dcf9 100644 --- a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java +++ b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java @@ -260,7 +260,7 @@ public class CreateCategoriesTests extends RestTest restClient.assertStatusCodeIs(BAD_REQUEST).assertLastError().containsSummary("Node id does not refer to a valid category"); } - private List getCategoriesToCreate(final int count) + static List getCategoriesToCreate(final int count) { return IntStream.range(0, count) .mapToObj(i -> { diff --git a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/GetCategoriesTests.java b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/GetCategoriesTests.java index d02312442b..a8d2da0340 100644 --- a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/GetCategoriesTests.java +++ b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/GetCategoriesTests.java @@ -28,11 +28,20 @@ package org.alfresco.rest.categories; import static org.alfresco.utility.report.log.Step.STEP; import static org.springframework.http.HttpStatus.BAD_REQUEST; +import static org.springframework.http.HttpStatus.CREATED; import static org.springframework.http.HttpStatus.NOT_FOUND; import static org.springframework.http.HttpStatus.OK; +import static org.testng.Assert.assertTrue; + +import java.util.List; +import java.util.stream.Collectors; +import java.util.stream.IntStream; import org.alfresco.rest.RestTest; +import org.alfresco.rest.core.RestResponse; import org.alfresco.rest.model.RestCategoryModel; +import org.alfresco.rest.model.RestCategoryModelsCollection; +import org.alfresco.utility.data.RandomData; import org.alfresco.utility.model.FolderModel; import org.alfresco.utility.model.SiteModel; import org.alfresco.utility.model.TestGroup; @@ -42,6 +51,10 @@ import org.testng.annotations.Test; public class GetCategoriesTests extends RestTest { + private static final List DEFAULT_ROOT_CATEGORIES = List.of("Software Document Classification", "Languages", "Regions", "Tags"); + private static final String ROOT = "-root-"; + private static final String NON_EXISTING_CATEGORY_ID = "non-existing-category-id"; + private UserModel user; @BeforeClass(alwaysRun = true) @@ -57,11 +70,29 @@ public class GetCategoriesTests extends RestTest @Test(groups = {TestGroup.REST_API}) public void testGetCategoryById() { - STEP("Get category with -root- as id (which does not exist)"); + STEP("Create a category under root category (as admin)"); final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId("-root-"); - restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategory(); - restClient.assertStatusCodeIs(NOT_FOUND); + rootCategory.setId(ROOT); + final RestCategoryModel aCategory = new RestCategoryModel(); + aCategory.setName(RandomData.getRandomName("Category")); + final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(rootCategory) + .createSingleCategory(aCategory); + restClient.assertStatusCodeIs(CREATED); + + createdCategory.assertThat() + .field("name").is(aCategory.getName()); + createdCategory.assertThat() + .field("parentId").is(rootCategory.getId()); + createdCategory.assertThat() + .field("hasChildren").is(false); + + STEP("Get the created category (as regular user)"); + final RestCategoryModel categoryFromGet = + restClient.authenticateUser(user).withCoreAPI().usingCategory(createdCategory).getCategory(); + restClient.assertStatusCodeIs(OK); + categoryFromGet.assertThat().isEqualTo(createdCategory); } /** @@ -70,15 +101,15 @@ public class GetCategoriesTests extends RestTest @Test(groups = {TestGroup.REST_API}) public void testGetCategoryByIdProvidingRootAsId() { - STEP("Get category with -root- as id (which does not exist)"); + STEP("Get category with -root- as id"); final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId("-root-"); + rootCategory.setId(ROOT); restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategory(); - restClient.assertStatusCodeIs(NOT_FOUND); + restClient.assertStatusCodeIs(BAD_REQUEST).assertLastError().containsSummary("Node id does not refer to a valid category"); } /** - * Check we get an error when passing as category id + * Check we get an error when passing folder node id as category id */ @Test(groups = {TestGroup.REST_API}) public void testGetCategoryByIdProvidingFolderAsId() @@ -91,7 +122,101 @@ public class GetCategoriesTests extends RestTest final RestCategoryModel rootCategory = new RestCategoryModel(); rootCategory.setId(folder.getNodeRef()); restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategory(); - restClient.assertStatusCodeIs(BAD_REQUEST); + restClient.assertStatusCodeIs(BAD_REQUEST).assertLastError().containsSummary("Node id does not refer to a valid category"); } + /** + * Check we get an error when passing non existing as category id + */ + @Test(groups = {TestGroup.REST_API}) + public void testGetCategoryByIdProvidingNonExistingId() + { + STEP("Get category with id which does not exist"); + final RestCategoryModel rootCategory = new RestCategoryModel(); + final String id = NON_EXISTING_CATEGORY_ID; + rootCategory.setId(id); + restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategory(); + restClient.assertStatusCodeIs(NOT_FOUND).assertLastError().containsSummary(id); + } + + /** + * Check we can get children category of a root category + */ + @Test(groups = {TestGroup.REST_API}) + public void testGetCategoryChildren() + { + STEP("Get category children with -root- as parent id"); + final RestCategoryModel rootCategory = new RestCategoryModel(); + rootCategory.setId(ROOT); + RestCategoryModelsCollection childCategoriesList = + restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategoryChildren(); + restClient.assertStatusCodeIs(OK); + + childCategoriesList.assertThat().entriesListIsNotEmpty(); + assertTrue(childCategoriesList.getEntries().stream() + .map(RestCategoryModel::onModel) + .map(RestCategoryModel::getName) + .collect(Collectors.toList()) + .containsAll(DEFAULT_ROOT_CATEGORIES)); + STEP("Create a new category under root and make sure it is returned as one of root's children"); + final RestCategoryModel aCategory = new RestCategoryModel(); + aCategory.setName((RandomData.getRandomName("newCategoryUnderRoot"))); + final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(rootCategory) + .createSingleCategory(aCategory); + restClient.assertStatusCodeIs(CREATED); + + childCategoriesList = restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategoryChildren(); + restClient.assertStatusCodeIs(OK); + assertTrue(childCategoriesList.getEntries().stream() + .map(RestCategoryModel::onModel) + .map(RestCategoryModel::getId) + .collect(Collectors.toList()) + .contains(createdCategory.getId())); + + STEP("Create 2 more categories under newCategoryUnderRoot and make sure they are returned as children"); + final int categoriesCount = 2; + final List categoriesToCreate = CreateCategoriesTests.getCategoriesToCreate(categoriesCount); + final RestCategoryModelsCollection createdSubCategories = restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(createdCategory) + .createCategoriesList(categoriesToCreate); + restClient.assertStatusCodeIs(CREATED); + childCategoriesList = restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategoryChildren(); + restClient.assertStatusCodeIs(OK); + childCategoriesList.getEntries().containsAll(createdSubCategories.getEntries()); + } + + /** + * Check we get an error when passing folder node id as parent category id when getting children. + */ + @Test(groups = {TestGroup.REST_API}) + public void testGetCategoryChildrenProvidingFolderAsId() + { + STEP("Create a site and a folder inside it"); + final SiteModel site = dataSite.usingUser(user).createPublicRandomSite(); + final FolderModel folder = dataContent.usingUser(user).usingSite(site).createFolder(); + + STEP("Get category children with folder id passed as parent id"); + final RestCategoryModel parentCategory = new RestCategoryModel(); + parentCategory.setId(folder.getNodeRef()); + restClient.authenticateUser(user).withCoreAPI().usingCategory(parentCategory).getCategoryChildren(); + restClient.assertStatusCodeIs(BAD_REQUEST).assertLastError().containsSummary("Node id does not refer to a valid category"); + } + + /** + * Check we get an error when passing a non-existent node id as parent category id when getting children. + */ + @Test(groups = {TestGroup.REST_API}) + public void testGetCategoryChildrenProvidingNonExistingParent() + { + + STEP("Get category with folder id passed as id"); + final RestCategoryModel parentCategory = new RestCategoryModel(); + final String parentId = NON_EXISTING_CATEGORY_ID; + parentCategory.setId(parentId); + restClient.authenticateUser(user).withCoreAPI().usingCategory(parentCategory).getCategoryChildren(); + restClient.assertStatusCodeIs(NOT_FOUND).assertLastError().containsSummary(parentId); + } } diff --git a/remote-api/src/main/java/org/alfresco/rest/api/Categories.java b/remote-api/src/main/java/org/alfresco/rest/api/Categories.java index 6c18d06fd2..7e03067e50 100644 --- a/remote-api/src/main/java/org/alfresco/rest/api/Categories.java +++ b/remote-api/src/main/java/org/alfresco/rest/api/Categories.java @@ -29,6 +29,7 @@ package org.alfresco.rest.api; import java.util.List; import org.alfresco.rest.api.model.Category; +import org.alfresco.rest.framework.resource.parameters.CollectionWithPagingInfo; import org.alfresco.rest.framework.resource.parameters.Parameters; import org.alfresco.service.Experimental; import org.alfresco.service.cmr.repository.NodeRef; @@ -39,4 +40,6 @@ public interface Categories Category getCategoryById(String id, Parameters params); List createSubcategories(String parentCategoryId, List categories, Parameters parameters); + + CollectionWithPagingInfo getCategoryChildren(String parentCategoryId, Parameters params); } diff --git a/remote-api/src/main/java/org/alfresco/rest/api/categories/SubcategoriesRelation.java b/remote-api/src/main/java/org/alfresco/rest/api/categories/SubcategoriesRelation.java index 1516ca44b8..bd3ccbce5d 100644 --- a/remote-api/src/main/java/org/alfresco/rest/api/categories/SubcategoriesRelation.java +++ b/remote-api/src/main/java/org/alfresco/rest/api/categories/SubcategoriesRelation.java @@ -35,10 +35,11 @@ import org.alfresco.rest.api.model.Category; import org.alfresco.rest.framework.WebApiDescription; import org.alfresco.rest.framework.resource.RelationshipResource; import org.alfresco.rest.framework.resource.actions.interfaces.RelationshipResourceAction; +import org.alfresco.rest.framework.resource.parameters.CollectionWithPagingInfo; import org.alfresco.rest.framework.resource.parameters.Parameters; @RelationshipResource(name = "subcategories", entityResource = CategoriesEntityResource.class, title = "Subcategories") -public class SubcategoriesRelation implements RelationshipResourceAction.Create +public class SubcategoriesRelation implements RelationshipResourceAction.Create, RelationshipResourceAction.Read { private final Categories categories; @@ -56,4 +57,13 @@ public class SubcategoriesRelation implements RelationshipResourceAction.Create< { return categories.createSubcategories(parentCategoryId, categoryList, parameters); } + + @WebApiDescription(title = "List category direct children", + description = "Lists direct children of a parent category", + successStatus = HttpServletResponse.SC_OK) + @Override + public CollectionWithPagingInfo readAll(String parentCategoryId, Parameters params) + { + return categories.getCategoryChildren(parentCategoryId, params); + } } diff --git a/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java b/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java index 8db2796b16..8f017d5b14 100644 --- a/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java +++ b/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java @@ -39,6 +39,8 @@ import org.alfresco.rest.api.model.Node; import org.alfresco.rest.framework.core.exceptions.EntityNotFoundException; import org.alfresco.rest.framework.core.exceptions.InvalidArgumentException; import org.alfresco.rest.framework.core.exceptions.PermissionDeniedException; +import org.alfresco.rest.framework.resource.parameters.CollectionWithPagingInfo; +import org.alfresco.rest.framework.resource.parameters.ListPage; import org.alfresco.rest.framework.resource.parameters.Parameters; import org.alfresco.service.Experimental; import org.alfresco.service.cmr.repository.ChildAssociationRef; @@ -74,8 +76,8 @@ public class CategoriesImpl implements Categories @Override public Category getCategoryById(final String id, final Parameters params) { - final NodeRef nodeRef = nodes.validateNode(id); - if (isNotACategory(nodeRef) || isRootCategory(nodeRef)) + final NodeRef nodeRef = getCategoryNodeRef(id); + if (isRootCategory(nodeRef)) { throw new InvalidArgumentException(NOT_A_VALID_CATEGORY, new String[]{id}); } @@ -90,14 +92,7 @@ public class CategoriesImpl implements Categories { throw new PermissionDeniedException(NO_PERMISSION_TO_CREATE_A_CATEGORY); } - final NodeRef parentNodeRef = PATH_ROOT.equals(parentCategoryId) ? - categoryService.getRootCategoryNodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE) - .orElseThrow(() -> new EntityNotFoundException(parentCategoryId)) : - nodes.validateNode(parentCategoryId); - if (isNotACategory(parentNodeRef)) - { - throw new InvalidArgumentException(NOT_A_VALID_CATEGORY, new String[]{parentCategoryId}); - } + final NodeRef parentNodeRef = getCategoryNodeRef(parentCategoryId); final List categoryNodeRefs = categories.stream() .map(c -> createCategoryNodeRef(parentNodeRef, c)) .collect(Collectors.toList()); @@ -106,6 +101,49 @@ public class CategoriesImpl implements Categories .collect(Collectors.toList()); } + @Override + public CollectionWithPagingInfo getCategoryChildren(String parentCategoryId, Parameters params) + { + final NodeRef parentNodeRef = getCategoryNodeRef(parentCategoryId); + final List childCategoriesAssocs = nodeService.getChildAssocs(parentNodeRef).stream() + .filter(ca -> ContentModel.ASSOC_SUBCATEGORIES.equals(ca.getTypeQName())) + .collect(Collectors.toList()); + final List categories = childCategoriesAssocs.stream() + .map(c -> mapToCategory(c.getChildRef())) + .collect(Collectors.toList()); + return ListPage.of(categories, params.getPaging()); + } + + /** + * This method gets category NodeRef for a given category id. + * If '-root-' is passed as category id, then it's retrieved as a call to {@link org.alfresco.service.cmr.search.CategoryService#getRootCategoryNodeRef} + * In all other cases it's retrieved as a node of a category type {@link #validateCategoryNode(String)} + * @param nodeId category node id + * @return NodRef of category node + */ + private NodeRef getCategoryNodeRef(String nodeId) + { + return PATH_ROOT.equals(nodeId) ? + categoryService.getRootCategoryNodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE) + .orElseThrow(() -> new EntityNotFoundException(nodeId)) : + validateCategoryNode(nodeId); + } + + /** + * Validates if the node exists and is a category. + * @param nodeId (presumably) category node id + * @return category NodeRef + */ + private NodeRef validateCategoryNode(String nodeId) + { + final NodeRef nodeRef = nodes.validateNode(nodeId); + if (isNotACategory(nodeRef)) + { + throw new InvalidArgumentException(NOT_A_VALID_CATEGORY, new String[]{nodeId}); + } + return nodeRef; + } + private NodeRef createCategoryNodeRef(NodeRef parentNodeRef, Category c) { if (StringUtils.isEmpty(c.getName())) { diff --git a/remote-api/src/test/java/org/alfresco/rest/api/categories/SubcategoriesRelationTest.java b/remote-api/src/test/java/org/alfresco/rest/api/categories/SubcategoriesRelationTest.java new file mode 100644 index 0000000000..7b1948f7d2 --- /dev/null +++ b/remote-api/src/test/java/org/alfresco/rest/api/categories/SubcategoriesRelationTest.java @@ -0,0 +1,105 @@ +/* + * #%L + * Alfresco Remote API + * %% + * Copyright (C) 2005 - 2022 Alfresco Software Limited + * %% + * This file is part of the Alfresco software. + * If the software was purchased under a paid Alfresco license, the terms of + * the paid license agreement will prevail. Otherwise, the software is + * provided under the following open source license terms: + * + * Alfresco is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Alfresco is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with Alfresco. If not, see . + * #L% + */ + +package org.alfresco.rest.api.categories; + +import static org.junit.Assert.assertEquals; +import static org.mockito.BDDMockito.given; +import static org.mockito.BDDMockito.then; + +import java.util.List; +import java.util.stream.Collectors; +import java.util.stream.IntStream; + +import org.alfresco.rest.api.Categories; +import org.alfresco.rest.api.model.Category; +import org.alfresco.rest.framework.resource.parameters.CollectionWithPagingInfo; +import org.alfresco.rest.framework.resource.parameters.Paging; +import org.alfresco.rest.framework.resource.parameters.Parameters; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.InjectMocks; +import org.mockito.Mock; +import org.mockito.junit.MockitoJUnitRunner; + +@RunWith(MockitoJUnitRunner.class) +public class SubcategoriesRelationTest +{ + private static final String PARENT_CATEGORY_ID = "parent-category-node-id"; + private static final String CATEGORY_ID = "category-node-id"; + private static final String CATEGORY_NAME = "categoryName"; + private static final String SUBCATEGORY_NAME_PREFIX = "childCategoryName"; + + @Mock + private Categories categoriesMock; + @Mock + private Parameters parametersMock; + + @InjectMocks + private SubcategoriesRelation objectUnderTest; + + @Test + public void testCreateSubcategory() + { + final Category categoryToCreate = Category.builder().name(CATEGORY_NAME).create(); + final Category category = Category.builder().name(CATEGORY_NAME).parentId(PARENT_CATEGORY_ID).hasChildren(false).id(CATEGORY_ID).create(); + final List categoriesToCreate = List.of(categoryToCreate); + given(categoriesMock.createSubcategories(PARENT_CATEGORY_ID, categoriesToCreate, parametersMock)).willReturn(List.of(category)); + + //when + List categories = objectUnderTest.create(PARENT_CATEGORY_ID, categoriesToCreate, parametersMock); + + then(categoriesMock).should().createSubcategories(PARENT_CATEGORY_ID, categoriesToCreate, parametersMock); + then(categoriesMock).shouldHaveNoMoreInteractions(); + assertEquals(List.of(category), categories); + } + + @Test + public void testGetCategoryChildren() { + final CollectionWithPagingInfo categoryChildren = getCategories(3); + given(categoriesMock.getCategoryChildren(PARENT_CATEGORY_ID, parametersMock)).willReturn(categoryChildren); + + //when + final CollectionWithPagingInfo returnedChildren = objectUnderTest.readAll(PARENT_CATEGORY_ID, parametersMock); + + then(categoriesMock).should().getCategoryChildren(PARENT_CATEGORY_ID, parametersMock); + then(categoriesMock).shouldHaveNoMoreInteractions(); + assertEquals(categoryChildren, returnedChildren); + } + + private CollectionWithPagingInfo getCategories(final int count) + { + return CollectionWithPagingInfo.asPaged(Paging.DEFAULT, + IntStream.range(0, count) + .mapToObj(i -> Category.builder().name(SUBCATEGORY_NAME_PREFIX + "-" + i) + .parentId(PARENT_CATEGORY_ID) + .hasChildren(false) + .id(CATEGORY_ID + "-" + i) + .create()) + .collect(Collectors.toList()) + ); + } +} diff --git a/remote-api/src/test/java/org/alfresco/rest/api/impl/CategoriesImplTest.java b/remote-api/src/test/java/org/alfresco/rest/api/impl/CategoriesImplTest.java index 7787e19812..482977366e 100644 --- a/remote-api/src/test/java/org/alfresco/rest/api/impl/CategoriesImplTest.java +++ b/remote-api/src/test/java/org/alfresco/rest/api/impl/CategoriesImplTest.java @@ -31,10 +31,15 @@ import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertThrows; import static org.mockito.BDDMockito.given; import static org.mockito.BDDMockito.then; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.times; +import java.util.ArrayList; import java.util.Collections; import java.util.List; import java.util.Optional; +import java.util.stream.Collectors; +import java.util.stream.IntStream; import org.alfresco.model.ContentModel; import org.alfresco.rest.api.Nodes; @@ -43,6 +48,7 @@ import org.alfresco.rest.api.model.Node; import org.alfresco.rest.framework.core.exceptions.EntityNotFoundException; import org.alfresco.rest.framework.core.exceptions.InvalidArgumentException; import org.alfresco.rest.framework.core.exceptions.PermissionDeniedException; +import org.alfresco.rest.framework.resource.parameters.CollectionWithPagingInfo; import org.alfresco.rest.framework.resource.parameters.Parameters; import org.alfresco.service.cmr.repository.ChildAssociationRef; import org.alfresco.service.cmr.repository.NodeRef; @@ -231,7 +237,6 @@ public class CategoriesImplTest final NodeRef parentCategoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PATH_ROOT); given(categoryServiceMock.getRootCategoryNodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE)) .willReturn(Optional.of(parentCategoryNodeRef)); - given(nodesMock.isSubClass(parentCategoryNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(true); final NodeRef categoryNodeRef = prepareCategoryNodeRef(); given(categoryServiceMock.createCategory(parentCategoryNodeRef, CATEGORY_NAME)).willReturn(categoryNodeRef); given(nodesMock.getNode(CATEGORY_ID)).willReturn(prepareCategoryNode()); @@ -246,7 +251,6 @@ public class CategoriesImplTest then(authorityServiceMock).should().hasAdminAuthority(); then(authorityServiceMock).shouldHaveNoMoreInteractions(); - then(nodesMock).should().isSubClass(parentCategoryNodeRef, ContentModel.TYPE_CATEGORY, false); then(nodesMock).should().getNode(CATEGORY_ID); then(nodesMock).shouldHaveNoMoreInteractions(); then(nodeServiceMock).should().getPrimaryParent(categoryNodeRef); @@ -366,12 +370,151 @@ public class CategoriesImplTest then(categoryServiceMock).shouldHaveNoInteractions(); } + @Test + public void testGetRootCategoryChildren() + { + final NodeRef parentCategoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PATH_ROOT); + given(categoryServiceMock.getRootCategoryNodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE)) + .willReturn(Optional.of(parentCategoryNodeRef)); + final int childrenCount = 3; + final List childAssociationRefMocks = prepareChildAssocMocks(childrenCount, parentCategoryNodeRef); + given(nodeServiceMock.getChildAssocs(parentCategoryNodeRef)).willReturn(childAssociationRefMocks); + childAssociationRefMocks.forEach(this::prepareCategoryNodeMocks); + + //when + final CollectionWithPagingInfo categoryChildren = objectUnderTest.getCategoryChildren(PATH_ROOT, parametersMock); + + then(categoryServiceMock).should().getRootCategoryNodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE); + then(categoryServiceMock).shouldHaveNoMoreInteractions(); + then(nodeServiceMock).should().getChildAssocs(parentCategoryNodeRef); + childAssociationRefMocks.forEach(ca -> { + then(nodesMock).should().getNode(ca.getChildRef().getId()); + then(nodeServiceMock).should() + .getChildAssocs(ca.getChildRef(), RegexQNamePattern.MATCH_ALL, RegexQNamePattern.MATCH_ALL, false); + then(nodeServiceMock).should().getPrimaryParent(ca.getChildRef()); + }); + then(nodeServiceMock).should(times(childrenCount)).getParentAssocs(parentCategoryNodeRef); + + then(nodesMock).shouldHaveNoMoreInteractions(); + then(nodeServiceMock).shouldHaveNoMoreInteractions(); + + then(authorityServiceMock).shouldHaveNoInteractions(); + + assertEquals(childAssociationRefMocks.size(), categoryChildren.getTotalItems().intValue()); + final List categoryChildrenList = new ArrayList<>(categoryChildren.getCollection()); + assertEquals(childAssociationRefMocks.size(), categoryChildrenList.size()); + IntStream.range(0, childrenCount).forEach(i -> doCategoryAssertions(categoryChildrenList.get(i), i, PATH_ROOT)); + } + + @Test + public void testGetCategoryChildren() + { + final NodeRef parentCategoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PARENT_ID); + given(nodesMock.validateNode(PARENT_ID)).willReturn(parentCategoryNodeRef); + given(nodesMock.isSubClass(parentCategoryNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(true); + final int childrenCount = 3; + final List childAssociationRefMocks = prepareChildAssocMocks(childrenCount, parentCategoryNodeRef); + given(nodeServiceMock.getChildAssocs(parentCategoryNodeRef)).willReturn(childAssociationRefMocks); + childAssociationRefMocks.forEach(this::prepareCategoryNodeMocks); + + //when + final CollectionWithPagingInfo categoryChildren = objectUnderTest.getCategoryChildren(PARENT_ID, parametersMock); + + then(nodesMock).should().validateNode(PARENT_ID); + then(nodesMock).should().isSubClass(parentCategoryNodeRef, ContentModel.TYPE_CATEGORY, false); + then(nodeServiceMock).should().getChildAssocs(parentCategoryNodeRef); + childAssociationRefMocks.forEach(ca -> { + then(nodesMock).should().getNode(ca.getChildRef().getId()); + then(nodeServiceMock).should() + .getChildAssocs(ca.getChildRef(), RegexQNamePattern.MATCH_ALL, RegexQNamePattern.MATCH_ALL, false); + then(nodeServiceMock).should().getPrimaryParent(ca.getChildRef()); + }); + then(nodeServiceMock).should(times(childrenCount)).getParentAssocs(parentCategoryNodeRef); + + then(nodesMock).shouldHaveNoMoreInteractions(); + then(nodeServiceMock).shouldHaveNoMoreInteractions(); + + then(authorityServiceMock).shouldHaveNoInteractions(); + then(categoryServiceMock).shouldHaveNoInteractions(); + + assertEquals(childAssociationRefMocks.size(), categoryChildren.getTotalItems().intValue()); + final List categoryChildrenList = new ArrayList<>(categoryChildren.getCollection()); + assertEquals(childAssociationRefMocks.size(), categoryChildrenList.size()); + IntStream.range(0, childrenCount).forEach(i -> doCategoryAssertions(categoryChildrenList.get(i), i, PARENT_ID)); + } + + @Test + public void testGetCategoryChildren_noChildren() + { + final NodeRef parentCategoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PARENT_ID); + given(nodesMock.validateNode(PARENT_ID)).willReturn(parentCategoryNodeRef); + given(nodesMock.isSubClass(parentCategoryNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(true); + + given(nodeServiceMock.getChildAssocs(parentCategoryNodeRef)).willReturn(Collections.emptyList()); + + + //when + final CollectionWithPagingInfo categoryChildren = objectUnderTest.getCategoryChildren(PARENT_ID, parametersMock); + + then(nodesMock).should().validateNode(PARENT_ID); + then(nodesMock).should().isSubClass(parentCategoryNodeRef, ContentModel.TYPE_CATEGORY, false); + then(nodesMock).shouldHaveNoMoreInteractions(); + then(nodeServiceMock).should().getChildAssocs(parentCategoryNodeRef); + then(nodeServiceMock).shouldHaveNoMoreInteractions(); + + then(authorityServiceMock).shouldHaveNoInteractions(); + then(categoryServiceMock).shouldHaveNoInteractions(); + + assertEquals(0, categoryChildren.getTotalItems().intValue()); + } + + @Test + public void testGetCategoryChildren_wrongParentNodeType() + { + final NodeRef parentCategoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PARENT_ID); + given(nodesMock.validateNode(PARENT_ID)).willReturn(parentCategoryNodeRef); + given(nodesMock.isSubClass(parentCategoryNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(false); + + //when + assertThrows(InvalidArgumentException.class, () -> objectUnderTest.getCategoryChildren(PARENT_ID, parametersMock)); + + then(nodesMock).should().validateNode(PARENT_ID); + then(nodesMock).should().isSubClass(parentCategoryNodeRef, ContentModel.TYPE_CATEGORY, false); + then(nodesMock).shouldHaveNoMoreInteractions(); + + then(nodeServiceMock).shouldHaveNoInteractions(); + then(categoryServiceMock).shouldHaveNoInteractions(); + then(authorityServiceMock).shouldHaveNoInteractions(); + } + + @Test + public void testGetCategoryChildren_nonExistingParentNode() + { + given(nodesMock.validateNode(PARENT_ID)).willThrow(EntityNotFoundException.class); + + //when + assertThrows(EntityNotFoundException.class, () -> objectUnderTest.getCategoryChildren(PARENT_ID, parametersMock)); + + + then(nodesMock).should().validateNode(PARENT_ID); + then(nodesMock).shouldHaveNoMoreInteractions(); + + then(nodeServiceMock).shouldHaveNoInteractions(); + then(categoryServiceMock).shouldHaveNoInteractions(); + then(authorityServiceMock).shouldHaveNoInteractions(); + } + private Node prepareCategoryNode() { - final Node categoryNode = new Node(); - categoryNode.setName(CATEGORY_NAME); - categoryNode.setNodeId(CATEGORY_ID); final NodeRef parentNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PARENT_ID); + return prepareCategoryNode(CATEGORY_NAME, CATEGORY_ID, parentNodeRef); + } + + private Node prepareCategoryNode(final String name, final String id, final NodeRef parentNodeRef) + { + final Node categoryNode = new Node(); + categoryNode.setName(name); + categoryNode.setNodeId(id); categoryNode.setParentId(parentNodeRef); return categoryNode; } @@ -387,4 +530,40 @@ public class CategoriesImplTest .name(CATEGORY_NAME) .create()); } + + private List prepareChildAssocMocks(final int count, NodeRef parentCategoryNodeRef) + { + return IntStream.range(0, count).mapToObj(i -> { + ChildAssociationRef dummyChildAssocMock = mock(ChildAssociationRef.class); + given(dummyChildAssocMock.getTypeQName()).willReturn(ContentModel.ASSOC_SUBCATEGORIES); + given(dummyChildAssocMock.getChildRef()) + .willReturn(new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, CATEGORY_ID + "-" + i)); + given(dummyChildAssocMock.getParentRef()).willReturn(parentCategoryNodeRef); + return dummyChildAssocMock; + }) + .collect(Collectors.toList()); + } + + private void prepareCategoryNodeMocks(ChildAssociationRef childAssociationRef) + { + final NodeRef childRef = childAssociationRef.getChildRef(); + final String id = childRef.getId(); + final String name = id.replace(CATEGORY_ID, CATEGORY_NAME); + final NodeRef parentRef = childAssociationRef.getParentRef(); + given(nodesMock.getNode(id)).willReturn(prepareCategoryNode(name, id, parentRef)); + final ChildAssociationRef parentAssoc = new ChildAssociationRef(null, parentRef, null, childRef); + given(nodeServiceMock.getPrimaryParent(childRef)).willReturn(parentAssoc); + given(nodeServiceMock.getParentAssocs(parentRef)).willReturn(List.of(parentAssoc)); + } + + private void doCategoryAssertions(final Category category, final int index, final String parentId) + { + final Category expectedCategory = Category.builder() + .id(CATEGORY_ID + "-" + index) + .name(CATEGORY_NAME + "-" + index) + .parentId(parentId) + .hasChildren(false) + .create(); + assertEquals(expectedCategory, category); + } } From 78e1d5863c550bbc992a824b4f02318d38a7b556 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Tue, 13 Dec 2022 16:59:52 +0000 Subject: [PATCH 11/37] [maven-release-plugin][skip ci] prepare release 20.41 --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index 368fdadb2a..33ce6e4003 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.41-SNAPSHOT + 20.41 diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 83f4b18ca1..2d54d649f1 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.41-SNAPSHOT + 20.41 diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 92d6cb86a9..8b5a62998c 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.41-SNAPSHOT + 20.41 diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index a149001911..27d13e11cc 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.41-SNAPSHOT + 20.41 diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 0a07aa28ee..5fde803f04 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.41-SNAPSHOT + 20.41 diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index dae56a6e0b..dd2276466d 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.41-SNAPSHOT + 20.41 diff --git a/amps/pom.xml b/amps/pom.xml index d4dbb3a5fd..722339470a 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41-SNAPSHOT + 20.41 diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index ed0697c0b4..579e37d263 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.41-SNAPSHOT + 20.41 diff --git a/core/pom.xml b/core/pom.xml index f95335b303..962df1fe29 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41-SNAPSHOT + 20.41 diff --git a/data-model/pom.xml b/data-model/pom.xml index dcae4f74c3..5071aa9491 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41-SNAPSHOT + 20.41 diff --git a/mmt/pom.xml b/mmt/pom.xml index c84563075c..ac9dc977ff 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41-SNAPSHOT + 20.41 diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 24937dadcc..bb6147efaf 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.41-SNAPSHOT + 20.41 diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 70dc62b2ae..d125121b33 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.41-SNAPSHOT + 20.41 diff --git a/packaging/pom.xml b/packaging/pom.xml index a6f54d86f8..a3cf710825 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41-SNAPSHOT + 20.41 diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index ef43555ad2..01eef10683 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.41-SNAPSHOT + 20.41 diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 11b8729383..486ab21ae0 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.41-SNAPSHOT + 20.41 diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 312f92e976..bba74d68ad 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.41-SNAPSHOT + 20.41 diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index a5b26852cb..90d0cf4c7b 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.41-SNAPSHOT + 20.41 diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 258f4aa6fb..f37cb96198 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.41-SNAPSHOT + 20.41 diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 21614ddd38..72d768bdd6 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.41-SNAPSHOT + 20.41 diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 0cae073a7c..2e3d1ca166 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.41-SNAPSHOT + 20.41 diff --git a/pom.xml b/pom.xml index e7e4878733..d21b0787bd 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.41-SNAPSHOT + 20.41 pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - HEAD + 20.41 diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 38a8d8cffb..3545cb22ba 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41-SNAPSHOT + 20.41 diff --git a/repository/pom.xml b/repository/pom.xml index 0b74a64168..ab03e07a63 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41-SNAPSHOT + 20.41 From 28114338c849c8d408de6df417d9a46dea4f1994 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Tue, 13 Dec 2022 16:59:55 +0000 Subject: [PATCH 12/37] [maven-release-plugin][skip ci] prepare for next development iteration --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index 33ce6e4003..26c263290d 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.41 + 20.42-SNAPSHOT diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 2d54d649f1..29a0c49068 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.41 + 20.42-SNAPSHOT diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 8b5a62998c..c69b5716d6 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.41 + 20.42-SNAPSHOT diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 27d13e11cc..2d9a56cfb1 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.41 + 20.42-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 5fde803f04..065bcc80e8 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.41 + 20.42-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index dd2276466d..73eb6a0cd5 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.41 + 20.42-SNAPSHOT diff --git a/amps/pom.xml b/amps/pom.xml index 722339470a..4e7ce0e44b 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41 + 20.42-SNAPSHOT diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index 579e37d263..a1399af469 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.41 + 20.42-SNAPSHOT diff --git a/core/pom.xml b/core/pom.xml index 962df1fe29..5e46c5e81e 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41 + 20.42-SNAPSHOT diff --git a/data-model/pom.xml b/data-model/pom.xml index 5071aa9491..fa5ff74124 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41 + 20.42-SNAPSHOT diff --git a/mmt/pom.xml b/mmt/pom.xml index ac9dc977ff..41f5c3b54b 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41 + 20.42-SNAPSHOT diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index bb6147efaf..ae009d282b 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.41 + 20.42-SNAPSHOT diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index d125121b33..60a796c59c 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.41 + 20.42-SNAPSHOT diff --git a/packaging/pom.xml b/packaging/pom.xml index a3cf710825..672c650093 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41 + 20.42-SNAPSHOT diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 01eef10683..62581c7351 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.41 + 20.42-SNAPSHOT diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 486ab21ae0..db63ac2b4f 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.41 + 20.42-SNAPSHOT diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index bba74d68ad..780bdd72ae 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.41 + 20.42-SNAPSHOT diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index 90d0cf4c7b..a8711fa220 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.41 + 20.42-SNAPSHOT diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index f37cb96198..5cfbe671cb 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.41 + 20.42-SNAPSHOT diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 72d768bdd6..a7de223758 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.41 + 20.42-SNAPSHOT diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 2e3d1ca166..be0333a9e1 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.41 + 20.42-SNAPSHOT diff --git a/pom.xml b/pom.xml index d21b0787bd..0f427f430f 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.41 + 20.42-SNAPSHOT pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - 20.41 + HEAD diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 3545cb22ba..9aab758d9f 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41 + 20.42-SNAPSHOT diff --git a/repository/pom.xml b/repository/pom.xml index ab03e07a63..e7a79ccbba 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.41 + 20.42-SNAPSHOT From 88b6a8e5b37a6e46d4eb5fb4e0ef08410f0cda87 Mon Sep 17 00:00:00 2001 From: George Evangelopoulos Date: Wed, 14 Dec 2022 16:00:59 +0000 Subject: [PATCH 13/37] ACS-4030: Delete category endpoint (#1618) * ACS-4030: Delete category endpoint implementation and tests --- .../alfresco/rest/requests/Categories.java | 12 ++ .../categories/DeleteCategoriesTests.java | 133 ++++++++++++++++++ .../org/alfresco/rest/api/Categories.java | 4 +- .../categories/CategoriesEntityResource.java | 11 +- .../rest/api/impl/CategoriesImpl.java | 18 +++ .../rest/api/impl/CategoriesImplTest.java | 86 +++++++++++ 6 files changed, 262 insertions(+), 2 deletions(-) create mode 100644 packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/DeleteCategoriesTests.java diff --git a/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java b/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java index 27ed2f5bc7..33697d5a65 100644 --- a/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java +++ b/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java @@ -92,4 +92,16 @@ public class Categories extends ModelRequest return restWrapper.processModels(RestCategoryModelsCollection.class, request); } + /** + * Delete category. + * + * - DELETE /categories/{categoryId} + */ + public void deleteCategory() + { + RestRequest request = RestRequest. + simpleRequest(HttpMethod.DELETE, "/categories/{categoryId}", category.getId()); + restWrapper.processEmptyModel(request); + } + } diff --git a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/DeleteCategoriesTests.java b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/DeleteCategoriesTests.java new file mode 100644 index 0000000000..e0b11e582c --- /dev/null +++ b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/DeleteCategoriesTests.java @@ -0,0 +1,133 @@ +/* + * #%L + * Alfresco Remote API + * %% + * Copyright (C) 2005 - 2022 Alfresco Software Limited + * %% + * This file is part of the Alfresco software. + * If the software was purchased under a paid Alfresco license, the terms of + * the paid license agreement will prevail. Otherwise, the software is + * provided under the following open source license terms: + * + * Alfresco is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Alfresco is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with Alfresco. If not, see . + * #L% + */ + +package org.alfresco.rest.categories; + +import org.alfresco.rest.RestTest; +import org.alfresco.rest.model.RestCategoryModel; +import org.alfresco.utility.data.RandomData; +import org.alfresco.utility.model.FolderModel; +import org.alfresco.utility.model.SiteModel; +import org.alfresco.utility.model.TestGroup; +import org.alfresco.utility.model.UserModel; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import static org.alfresco.utility.report.log.Step.STEP; +import static org.springframework.http.HttpStatus.BAD_REQUEST; +import static org.springframework.http.HttpStatus.CREATED; +import static org.springframework.http.HttpStatus.FORBIDDEN; +import static org.springframework.http.HttpStatus.NOT_FOUND; +import static org.springframework.http.HttpStatus.NO_CONTENT; + +public class DeleteCategoriesTests extends RestTest { + + private UserModel user; + + + @BeforeClass(alwaysRun = true) + public void dataPreparation() throws Exception + { + STEP("Create a user"); + user = dataUser.createRandomTestUser(); + } + + /** + * Check we can delete a category. + */ + @Test(groups = {TestGroup.REST_API}) + public void testDeleteCategory() + { + STEP("Create a category and send a request to delete it."); + RestCategoryModel aCategory = createCategory(); + restClient.authenticateUser(dataUser.getAdminUser()).withCoreAPI().usingCategory(aCategory).deleteCategory(); + restClient.assertStatusCodeIs(NO_CONTENT); + + STEP("Ensure that the category has been deleted by sending a GET request and receiving 404."); + restClient.authenticateUser(user).withCoreAPI().usingCategory(aCategory).getCategory(); + restClient.assertStatusCodeIs(NOT_FOUND); + } + + /** + * Check we get an error when trying to delete a category as a non-admin user. + */ + @Test(groups = {TestGroup.REST_API}) + public void testDeleteCategoryAsRegularUser_andFail() + { + RestCategoryModel aCategory = createCategory(); + restClient.authenticateUser(user).withCoreAPI().usingCategory(aCategory).deleteCategory(); + restClient.assertStatusCodeIs(FORBIDDEN).assertLastError().containsSummary("Current user does not have permission to delete a category"); + } + + /** + * Check we receive 404 error when trying to delete a category with a non-existent node id. + */ + @Test(groups = {TestGroup.REST_API}) + public void testDeleteNonExistentCategory() + { + STEP("Get category with non-existent id"); + final RestCategoryModel rootCategory = new RestCategoryModel(); + final String id = "non-existing-dummy-id"; + rootCategory.setId(id); + + STEP("Attempt to delete category with non-existent id and receive 404"); + restClient.authenticateUser(dataUser.getAdminUser()).withCoreAPI().usingCategory(rootCategory).deleteCategory(); + restClient.assertStatusCodeIs(NOT_FOUND); + } + + /** + * Attempt to delete a category when providing a node id that doesn't belong to a category + */ + @Test(groups = {TestGroup.REST_API}) + public void testDeleteCategory_givenNonCategoryNodeId() + { + STEP("Create a site and a folder inside it"); + final SiteModel site = dataSite.usingUser(user).createPublicRandomSite(); + final FolderModel folder = dataContent.usingUser(user).usingSite(site).createFolder(); + String id = folder.getNodeRef(); + + STEP("Create a category, set its id to the folder id and attempt to delete it"); + final RestCategoryModel aCategory = new RestCategoryModel(); + aCategory.setId(id); + restClient.authenticateUser(dataUser.getAdminUser()).withCoreAPI().usingCategory(aCategory).deleteCategory(); + restClient.assertStatusCodeIs(BAD_REQUEST).assertLastError().containsSummary("Node id does not refer to a valid category"); + } + + public RestCategoryModel createCategory() + { + final RestCategoryModel rootCategory = new RestCategoryModel(); + rootCategory.setId("-root-"); + final RestCategoryModel aCategory = new RestCategoryModel(); + aCategory.setName(RandomData.getRandomName("Category")); + final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(rootCategory) + .createSingleCategory(aCategory); + restClient.assertStatusCodeIs(CREATED); + + return createdCategory; + } +} diff --git a/remote-api/src/main/java/org/alfresco/rest/api/Categories.java b/remote-api/src/main/java/org/alfresco/rest/api/Categories.java index 7e03067e50..a3babc5905 100644 --- a/remote-api/src/main/java/org/alfresco/rest/api/Categories.java +++ b/remote-api/src/main/java/org/alfresco/rest/api/Categories.java @@ -32,7 +32,6 @@ import org.alfresco.rest.api.model.Category; import org.alfresco.rest.framework.resource.parameters.CollectionWithPagingInfo; import org.alfresco.rest.framework.resource.parameters.Parameters; import org.alfresco.service.Experimental; -import org.alfresco.service.cmr.repository.NodeRef; @Experimental public interface Categories @@ -42,4 +41,7 @@ public interface Categories List createSubcategories(String parentCategoryId, List categories, Parameters parameters); CollectionWithPagingInfo getCategoryChildren(String parentCategoryId, Parameters params); + + void deleteCategoryById(String id, Parameters params); + } diff --git a/remote-api/src/main/java/org/alfresco/rest/api/categories/CategoriesEntityResource.java b/remote-api/src/main/java/org/alfresco/rest/api/categories/CategoriesEntityResource.java index 3bde251ca0..df8483958f 100644 --- a/remote-api/src/main/java/org/alfresco/rest/api/categories/CategoriesEntityResource.java +++ b/remote-api/src/main/java/org/alfresco/rest/api/categories/CategoriesEntityResource.java @@ -41,7 +41,8 @@ import org.alfresco.rest.framework.resource.parameters.Parameters; * @author mpichura */ @EntityResource(name = "categories", title = "Categories") -public class CategoriesEntityResource implements EntityResourceAction.ReadById +public class CategoriesEntityResource implements EntityResourceAction.ReadById, + EntityResourceAction.Delete { private final Categories categories; @@ -58,4 +59,12 @@ public class CategoriesEntityResource implements EntityResourceAction.ReadById objectUnderTest.deleteCategoryById(CATEGORY_ID, parametersMock)); + + then(authorityServiceMock).should().hasAdminAuthority(); + then(authorityServiceMock).shouldHaveNoMoreInteractions(); + + then(nodesMock).shouldHaveNoInteractions(); + then(nodeServiceMock).shouldHaveNoInteractions(); + } + + @Test + public void testDeleteCategoryById_nonCategoryId() + { + given(authorityServiceMock.hasAdminAuthority()).willReturn(true); + final NodeRef categoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, CATEGORY_ID); + given(nodesMock.validateNode(CATEGORY_ID)).willReturn(categoryNodeRef); + given(nodesMock.isSubClass(categoryNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(false); + + //when + assertThrows(InvalidArgumentException.class, () -> objectUnderTest.deleteCategoryById(CATEGORY_ID, parametersMock)); + + then(authorityServiceMock).should().hasAdminAuthority(); + then(authorityServiceMock).shouldHaveNoMoreInteractions(); + + then(nodesMock).should().validateNode(CATEGORY_ID); + then(nodesMock).should().isSubClass(categoryNodeRef, ContentModel.TYPE_CATEGORY, false); + then(nodesMock).shouldHaveNoMoreInteractions(); + } + + @Test + public void testDeleteCategoryById_rootCategory() + { + given(authorityServiceMock.hasAdminAuthority()).willReturn(true); + final NodeRef categoryRootNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, CAT_ROOT_NODE_ID); + given(nodesMock.validateNode(CAT_ROOT_NODE_ID)).willReturn(categoryRootNodeRef); + given(nodesMock.isSubClass(categoryRootNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(true); + given(categoryChildAssociationRefMock.getQName()).willReturn(ContentModel.ASPECT_GEN_CLASSIFIABLE); + given(nodeServiceMock.getParentAssocs(categoryRootNodeRef)).willReturn(List.of(categoryChildAssociationRefMock)); + + //when + assertThrows(InvalidArgumentException.class, () -> objectUnderTest.deleteCategoryById(CAT_ROOT_NODE_ID, parametersMock)); + + then(authorityServiceMock).should().hasAdminAuthority(); + then(authorityServiceMock).shouldHaveNoMoreInteractions(); + + then(nodesMock).should().validateNode(CAT_ROOT_NODE_ID); + then(nodesMock).should().isSubClass(categoryRootNodeRef, ContentModel.TYPE_CATEGORY, false); + then(nodesMock).shouldHaveNoMoreInteractions(); + + then(nodeServiceMock).should().getParentAssocs(categoryRootNodeRef); + then(nodeServiceMock).shouldHaveNoMoreInteractions(); + } + @Test public void testCreateCategoryUnderRoot() { From eea23b0d2af7251301f043bada46206f05bcbdf1 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Wed, 14 Dec 2022 16:39:48 +0000 Subject: [PATCH 14/37] [maven-release-plugin][skip ci] prepare release 20.42 --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index 26c263290d..10a19554aa 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.42-SNAPSHOT + 20.42 diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 29a0c49068..d792380348 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.42-SNAPSHOT + 20.42 diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index c69b5716d6..ff85d048bf 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.42-SNAPSHOT + 20.42 diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 2d9a56cfb1..b811aa8454 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.42-SNAPSHOT + 20.42 diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 065bcc80e8..ddf55b8237 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.42-SNAPSHOT + 20.42 diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 73eb6a0cd5..344267b3cb 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.42-SNAPSHOT + 20.42 diff --git a/amps/pom.xml b/amps/pom.xml index 4e7ce0e44b..ea0b45fbd5 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42-SNAPSHOT + 20.42 diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index a1399af469..e7aae1a396 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.42-SNAPSHOT + 20.42 diff --git a/core/pom.xml b/core/pom.xml index 5e46c5e81e..b4ca36ba3a 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42-SNAPSHOT + 20.42 diff --git a/data-model/pom.xml b/data-model/pom.xml index fa5ff74124..8f9a2821b4 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42-SNAPSHOT + 20.42 diff --git a/mmt/pom.xml b/mmt/pom.xml index 41f5c3b54b..73ba659d33 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42-SNAPSHOT + 20.42 diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index ae009d282b..792f4c7df8 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.42-SNAPSHOT + 20.42 diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 60a796c59c..7b93f10363 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.42-SNAPSHOT + 20.42 diff --git a/packaging/pom.xml b/packaging/pom.xml index 672c650093..d288c41388 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42-SNAPSHOT + 20.42 diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 62581c7351..e65872243b 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.42-SNAPSHOT + 20.42 diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index db63ac2b4f..48c08571c1 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.42-SNAPSHOT + 20.42 diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 780bdd72ae..186b12d68a 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.42-SNAPSHOT + 20.42 diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index a8711fa220..a3cffb0f74 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.42-SNAPSHOT + 20.42 diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 5cfbe671cb..3d7fc1f1de 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.42-SNAPSHOT + 20.42 diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index a7de223758..5fc29ae097 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.42-SNAPSHOT + 20.42 diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index be0333a9e1..6bc954edfc 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.42-SNAPSHOT + 20.42 diff --git a/pom.xml b/pom.xml index 0f427f430f..c6b4bd4f4d 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.42-SNAPSHOT + 20.42 pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - HEAD + 20.42 diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 9aab758d9f..68398cb4e2 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42-SNAPSHOT + 20.42 diff --git a/repository/pom.xml b/repository/pom.xml index e7a79ccbba..5f4e6f3755 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42-SNAPSHOT + 20.42 From 1749b2d74bd8927ccd0aa8b2df076ba351a499d2 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Wed, 14 Dec 2022 16:39:51 +0000 Subject: [PATCH 15/37] [maven-release-plugin][skip ci] prepare for next development iteration --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index 10a19554aa..79313cbc68 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.42 + 20.43-SNAPSHOT diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index d792380348..78f94d83ad 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.42 + 20.43-SNAPSHOT diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index ff85d048bf..fb43dc97c0 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.42 + 20.43-SNAPSHOT diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index b811aa8454..848a11e3c1 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.42 + 20.43-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index ddf55b8237..61362c2674 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.42 + 20.43-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 344267b3cb..0576c4de62 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.42 + 20.43-SNAPSHOT diff --git a/amps/pom.xml b/amps/pom.xml index ea0b45fbd5..aee55682c9 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42 + 20.43-SNAPSHOT diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index e7aae1a396..e182a2e286 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.42 + 20.43-SNAPSHOT diff --git a/core/pom.xml b/core/pom.xml index b4ca36ba3a..5328b7b040 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42 + 20.43-SNAPSHOT diff --git a/data-model/pom.xml b/data-model/pom.xml index 8f9a2821b4..460f55319a 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42 + 20.43-SNAPSHOT diff --git a/mmt/pom.xml b/mmt/pom.xml index 73ba659d33..fe8fa67eed 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42 + 20.43-SNAPSHOT diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 792f4c7df8..d4b6107e11 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.42 + 20.43-SNAPSHOT diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 7b93f10363..5832fcf4e5 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.42 + 20.43-SNAPSHOT diff --git a/packaging/pom.xml b/packaging/pom.xml index d288c41388..52a99f1bb9 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42 + 20.43-SNAPSHOT diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index e65872243b..22ca93ef8c 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.42 + 20.43-SNAPSHOT diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 48c08571c1..806062578f 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.42 + 20.43-SNAPSHOT diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 186b12d68a..3b22c0abc7 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.42 + 20.43-SNAPSHOT diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index a3cffb0f74..32204df148 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.42 + 20.43-SNAPSHOT diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 3d7fc1f1de..d79a9a5668 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.42 + 20.43-SNAPSHOT diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 5fc29ae097..826a6fc3b8 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.42 + 20.43-SNAPSHOT diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 6bc954edfc..16c5b0a671 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.42 + 20.43-SNAPSHOT diff --git a/pom.xml b/pom.xml index c6b4bd4f4d..231fda916b 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.42 + 20.43-SNAPSHOT pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - 20.42 + HEAD diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 68398cb4e2..2252a69836 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42 + 20.43-SNAPSHOT diff --git a/repository/pom.xml b/repository/pom.xml index 5f4e6f3755..1f93258b61 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.42 + 20.43-SNAPSHOT From 077752ad862a2aa438788d676deedca7b4cb4fca Mon Sep 17 00:00:00 2001 From: kcichonczyk <88378534+kcichonczyk@users.noreply.github.com> Date: Thu, 15 Dec 2022 14:28:46 +0100 Subject: [PATCH 16/37] bumped IE version to 2.0.6 (ACS-4054) (#1628) --- amps/ags/rm-community/rm-community-repo/.env | 2 +- packaging/tests/environment/.env | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/amps/ags/rm-community/rm-community-repo/.env b/amps/ags/rm-community/rm-community-repo/.env index fc37bc79cc..9c612ce1fb 100644 --- a/amps/ags/rm-community/rm-community-repo/.env +++ b/amps/ags/rm-community/rm-community-repo/.env @@ -1,3 +1,3 @@ -SOLR6_TAG=2.0.6-A4 +SOLR6_TAG=2.0.6 POSTGRES_TAG=14.4 ACTIVEMQ_TAG=5.17.1-jre11-rockylinux8 diff --git a/packaging/tests/environment/.env b/packaging/tests/environment/.env index fc37bc79cc..9c612ce1fb 100644 --- a/packaging/tests/environment/.env +++ b/packaging/tests/environment/.env @@ -1,3 +1,3 @@ -SOLR6_TAG=2.0.6-A4 +SOLR6_TAG=2.0.6 POSTGRES_TAG=14.4 ACTIVEMQ_TAG=5.17.1-jre11-rockylinux8 From c66bb48258ae1b0d0e102257f12cd683392d4315 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Thu, 15 Dec 2022 14:09:41 +0000 Subject: [PATCH 17/37] [maven-release-plugin][skip ci] prepare release 20.43 --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index 79313cbc68..f187925531 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.43-SNAPSHOT + 20.43 diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 78f94d83ad..0367dcffd6 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.43-SNAPSHOT + 20.43 diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index fb43dc97c0..16ea53ed11 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.43-SNAPSHOT + 20.43 diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 848a11e3c1..24006bc0b8 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.43-SNAPSHOT + 20.43 diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 61362c2674..5e9f1efb10 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.43-SNAPSHOT + 20.43 diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 0576c4de62..5963fa4ec4 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.43-SNAPSHOT + 20.43 diff --git a/amps/pom.xml b/amps/pom.xml index aee55682c9..c5cd14fac6 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43-SNAPSHOT + 20.43 diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index e182a2e286..cd0b4e1032 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.43-SNAPSHOT + 20.43 diff --git a/core/pom.xml b/core/pom.xml index 5328b7b040..58c86ed6cf 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43-SNAPSHOT + 20.43 diff --git a/data-model/pom.xml b/data-model/pom.xml index 460f55319a..bcc11c0cb7 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43-SNAPSHOT + 20.43 diff --git a/mmt/pom.xml b/mmt/pom.xml index fe8fa67eed..b8aa27d0b7 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43-SNAPSHOT + 20.43 diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index d4b6107e11..a303dc88ca 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.43-SNAPSHOT + 20.43 diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 5832fcf4e5..85de34785d 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.43-SNAPSHOT + 20.43 diff --git a/packaging/pom.xml b/packaging/pom.xml index 52a99f1bb9..2a0ace7faa 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43-SNAPSHOT + 20.43 diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 22ca93ef8c..ebe6f786b7 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.43-SNAPSHOT + 20.43 diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 806062578f..22baecdb4d 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.43-SNAPSHOT + 20.43 diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 3b22c0abc7..35c6148754 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.43-SNAPSHOT + 20.43 diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index 32204df148..ba454714c3 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.43-SNAPSHOT + 20.43 diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index d79a9a5668..23a9c5ca32 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.43-SNAPSHOT + 20.43 diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 826a6fc3b8..bb24d83976 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.43-SNAPSHOT + 20.43 diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 16c5b0a671..5c2a0127ad 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.43-SNAPSHOT + 20.43 diff --git a/pom.xml b/pom.xml index 231fda916b..c4b9e7d7ff 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.43-SNAPSHOT + 20.43 pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - HEAD + 20.43 diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 2252a69836..bd29ea4eb4 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43-SNAPSHOT + 20.43 diff --git a/repository/pom.xml b/repository/pom.xml index 1f93258b61..4b369aa367 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43-SNAPSHOT + 20.43 From 54843fa3360c179ca00f9df7eac712464fc99b2f Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Thu, 15 Dec 2022 14:09:45 +0000 Subject: [PATCH 18/37] [maven-release-plugin][skip ci] prepare for next development iteration --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index f187925531..888b712a23 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.43 + 20.44-SNAPSHOT diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 0367dcffd6..ad9bc250c7 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.43 + 20.44-SNAPSHOT diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 16ea53ed11..56b9198151 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.43 + 20.44-SNAPSHOT diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 24006bc0b8..20c2e54439 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.43 + 20.44-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 5e9f1efb10..1a0f08ca5a 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.43 + 20.44-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 5963fa4ec4..358e1b5fcc 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.43 + 20.44-SNAPSHOT diff --git a/amps/pom.xml b/amps/pom.xml index c5cd14fac6..db9e91fa56 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43 + 20.44-SNAPSHOT diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index cd0b4e1032..99ea308f1f 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.43 + 20.44-SNAPSHOT diff --git a/core/pom.xml b/core/pom.xml index 58c86ed6cf..afe5433e42 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43 + 20.44-SNAPSHOT diff --git a/data-model/pom.xml b/data-model/pom.xml index bcc11c0cb7..48d941b053 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43 + 20.44-SNAPSHOT diff --git a/mmt/pom.xml b/mmt/pom.xml index b8aa27d0b7..04111ac757 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43 + 20.44-SNAPSHOT diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index a303dc88ca..90284b8166 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.43 + 20.44-SNAPSHOT diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 85de34785d..3733b75c0d 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.43 + 20.44-SNAPSHOT diff --git a/packaging/pom.xml b/packaging/pom.xml index 2a0ace7faa..8606e74580 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43 + 20.44-SNAPSHOT diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index ebe6f786b7..4b0567c7a4 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.43 + 20.44-SNAPSHOT diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 22baecdb4d..8ba46a8060 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.43 + 20.44-SNAPSHOT diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 35c6148754..8b4f10c16c 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.43 + 20.44-SNAPSHOT diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index ba454714c3..9d6fb1a283 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.43 + 20.44-SNAPSHOT diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 23a9c5ca32..978b5930be 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.43 + 20.44-SNAPSHOT diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index bb24d83976..9b3c7298e2 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.43 + 20.44-SNAPSHOT diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 5c2a0127ad..a301f19b3c 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.43 + 20.44-SNAPSHOT diff --git a/pom.xml b/pom.xml index c4b9e7d7ff..f3dd18ab29 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.43 + 20.44-SNAPSHOT pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - 20.43 + HEAD diff --git a/remote-api/pom.xml b/remote-api/pom.xml index bd29ea4eb4..9d13b5f37f 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43 + 20.44-SNAPSHOT diff --git a/repository/pom.xml b/repository/pom.xml index 4b369aa367..497c2de8ba 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.43 + 20.44-SNAPSHOT From cdbe3292e026684e137bf2048aad8fb03e22aae5 Mon Sep 17 00:00:00 2001 From: Damian Ujma <92095156+damianujma@users.noreply.github.com> Date: Fri, 16 Dec 2022 11:27:02 +0100 Subject: [PATCH 19/37] ACS-3841 Add missing logs for WebDAV TAS tests (#1629) * ACS-3841 Add missing logs * ACS-3841 Reformat code + fix grep --- packaging/tests/scripts/output_tests_run.sh | 2 +- .../java/org/alfresco/webdav/WebDavTest.java | 22 ++++++++++++++++++- 2 files changed, 22 insertions(+), 2 deletions(-) diff --git a/packaging/tests/scripts/output_tests_run.sh b/packaging/tests/scripts/output_tests_run.sh index ca1c9355c4..cd7c630cbf 100755 --- a/packaging/tests/scripts/output_tests_run.sh +++ b/packaging/tests/scripts/output_tests_run.sh @@ -4,4 +4,4 @@ TAS_DIRECTORY=$1 cd ${TAS_DIRECTORY} -cat target/reports/alfresco-tas.log | grep "*** STARTING" +cat target/reports/alfresco-tas.log | grep -a "*** STARTING" diff --git a/packaging/tests/tas-webdav/src/test/java/org/alfresco/webdav/WebDavTest.java b/packaging/tests/tas-webdav/src/test/java/org/alfresco/webdav/WebDavTest.java index f75eed0f92..ca71c0ab91 100644 --- a/packaging/tests/tas-webdav/src/test/java/org/alfresco/webdav/WebDavTest.java +++ b/packaging/tests/tas-webdav/src/test/java/org/alfresco/webdav/WebDavTest.java @@ -1,17 +1,25 @@ package org.alfresco.webdav; +import java.lang.reflect.Method; + import org.alfresco.utility.data.DataContent; import org.alfresco.utility.data.DataSite; import org.alfresco.utility.data.DataUser; +import org.alfresco.utility.LogFactory; import org.alfresco.utility.network.ServerHealth; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.testng.AbstractTestNGSpringContextTests; +import org.slf4j.Logger; +import org.testng.annotations.AfterMethod; +import org.testng.annotations.BeforeMethod; import org.testng.annotations.BeforeSuite; @ContextConfiguration("classpath:alfresco-webdav-context.xml") public abstract class WebDavTest extends AbstractTestNGSpringContextTests { + private static final Logger LOG = LogFactory.getLogger(); + @Autowired protected DataSite dataSite; @@ -36,4 +44,16 @@ public abstract class WebDavTest extends AbstractTestNGSpringContextTests // The webdav protocol is enabled by default. //webDavProtocol.assertThat().protocolIsEnabled(); } -} + + @BeforeMethod(alwaysRun=true) + public void showStartTestInfo(Method method) + { + LOG.info(String.format("*** STARTING Test: [%s] ***", method.getName())); + } + + @AfterMethod(alwaysRun=true) + public void showEndTestInfo(Method method) + { + LOG.info(String.format("*** ENDING Test: [%s] ***", method.getName())); + } +} \ No newline at end of file From c50c10ef2be7abf0bb2650a5f6f16136c7c16af0 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Fri, 16 Dec 2022 11:03:01 +0000 Subject: [PATCH 20/37] [maven-release-plugin][skip ci] prepare release 20.44 --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index 888b712a23..c6bf92cb82 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.44-SNAPSHOT + 20.44 diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index ad9bc250c7..ef7555b543 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.44-SNAPSHOT + 20.44 diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 56b9198151..2315c232d0 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.44-SNAPSHOT + 20.44 diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 20c2e54439..33e638e67f 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.44-SNAPSHOT + 20.44 diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 1a0f08ca5a..77964c55a5 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.44-SNAPSHOT + 20.44 diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 358e1b5fcc..4faca3575b 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.44-SNAPSHOT + 20.44 diff --git a/amps/pom.xml b/amps/pom.xml index db9e91fa56..f43489216f 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44-SNAPSHOT + 20.44 diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index 99ea308f1f..8babf3877d 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.44-SNAPSHOT + 20.44 diff --git a/core/pom.xml b/core/pom.xml index afe5433e42..fd1711699a 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44-SNAPSHOT + 20.44 diff --git a/data-model/pom.xml b/data-model/pom.xml index 48d941b053..0120c86828 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44-SNAPSHOT + 20.44 diff --git a/mmt/pom.xml b/mmt/pom.xml index 04111ac757..35a23714ab 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44-SNAPSHOT + 20.44 diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 90284b8166..a20293f466 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.44-SNAPSHOT + 20.44 diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 3733b75c0d..4db77a1fc8 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.44-SNAPSHOT + 20.44 diff --git a/packaging/pom.xml b/packaging/pom.xml index 8606e74580..c6b909edfa 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44-SNAPSHOT + 20.44 diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 4b0567c7a4..24cb42cf12 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.44-SNAPSHOT + 20.44 diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 8ba46a8060..435fa196ed 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.44-SNAPSHOT + 20.44 diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 8b4f10c16c..a2b0a0c898 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.44-SNAPSHOT + 20.44 diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index 9d6fb1a283..3deaf7748c 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.44-SNAPSHOT + 20.44 diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 978b5930be..e2714a6803 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.44-SNAPSHOT + 20.44 diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 9b3c7298e2..9c7b594bcb 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.44-SNAPSHOT + 20.44 diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index a301f19b3c..e04ca1d860 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.44-SNAPSHOT + 20.44 diff --git a/pom.xml b/pom.xml index f3dd18ab29..447129e45a 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.44-SNAPSHOT + 20.44 pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - HEAD + 20.44 diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 9d13b5f37f..fba54fa23f 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44-SNAPSHOT + 20.44 diff --git a/repository/pom.xml b/repository/pom.xml index 497c2de8ba..df4c90722d 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44-SNAPSHOT + 20.44 From 60a04b0402bdeff903c341e0a36d646e3939da6f Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Fri, 16 Dec 2022 11:03:04 +0000 Subject: [PATCH 21/37] [maven-release-plugin][skip ci] prepare for next development iteration --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index c6bf92cb82..7ea46aa1b7 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.44 + 20.45-SNAPSHOT diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index ef7555b543..b60e5ec611 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.44 + 20.45-SNAPSHOT diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 2315c232d0..e0f6bf31e4 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.44 + 20.45-SNAPSHOT diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 33e638e67f..4743beb7e7 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.44 + 20.45-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 77964c55a5..8e85cc0f94 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.44 + 20.45-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 4faca3575b..ce5a6d46bd 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.44 + 20.45-SNAPSHOT diff --git a/amps/pom.xml b/amps/pom.xml index f43489216f..a9d1866061 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44 + 20.45-SNAPSHOT diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index 8babf3877d..90d7cf5448 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.44 + 20.45-SNAPSHOT diff --git a/core/pom.xml b/core/pom.xml index fd1711699a..4d48e8b4e3 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44 + 20.45-SNAPSHOT diff --git a/data-model/pom.xml b/data-model/pom.xml index 0120c86828..9ca95416cc 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44 + 20.45-SNAPSHOT diff --git a/mmt/pom.xml b/mmt/pom.xml index 35a23714ab..f075a4c335 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44 + 20.45-SNAPSHOT diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index a20293f466..51e2ecc6d3 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.44 + 20.45-SNAPSHOT diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 4db77a1fc8..37c25ae4d7 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.44 + 20.45-SNAPSHOT diff --git a/packaging/pom.xml b/packaging/pom.xml index c6b909edfa..59ec7e5d0e 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44 + 20.45-SNAPSHOT diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 24cb42cf12..9a596006c7 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.44 + 20.45-SNAPSHOT diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 435fa196ed..6eeacfc3e9 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.44 + 20.45-SNAPSHOT diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index a2b0a0c898..6bea3a195a 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.44 + 20.45-SNAPSHOT diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index 3deaf7748c..3580670ea2 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.44 + 20.45-SNAPSHOT diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index e2714a6803..149a190861 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.44 + 20.45-SNAPSHOT diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 9c7b594bcb..c6510867a2 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.44 + 20.45-SNAPSHOT diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index e04ca1d860..1c8075a60c 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.44 + 20.45-SNAPSHOT diff --git a/pom.xml b/pom.xml index 447129e45a..9e6845e241 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.44 + 20.45-SNAPSHOT pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - 20.44 + HEAD diff --git a/remote-api/pom.xml b/remote-api/pom.xml index fba54fa23f..0c485a45a4 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44 + 20.45-SNAPSHOT diff --git a/repository/pom.xml b/repository/pom.xml index df4c90722d..3b22b8a836 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.44 + 20.45-SNAPSHOT From cea3e37dd5acbb97f67ed707a7dfe26fb91ea47e Mon Sep 17 00:00:00 2001 From: krdabrowski <98942253+krdabrowski@users.noreply.github.com> Date: Fri, 16 Dec 2022 12:36:06 +0100 Subject: [PATCH 22/37] ACS-4029: Update a category name - PUT /categories/{categoryId} (#1621) * ACS-4029: Update a category name - PUT /categories/{categoryId} --- .../rest/model/RestCategoryModel.java | 47 ++++ .../alfresco/rest/requests/Categories.java | 15 +- .../rest/categories/CategoriesRestTest.java | 91 +++++++ .../categories/CreateCategoriesTests.java | 69 ++--- .../categories/DeleteCategoriesTests.java | 55 +--- .../rest/categories/GetCategoriesTests.java | 53 +--- .../categories/UpdateCategoriesTests.java | 214 +++++++++++++++ .../org/alfresco/rest/api/Categories.java | 15 +- .../categories/CategoriesEntityResource.java | 42 ++- .../api/categories/SubcategoriesRelation.java | 9 +- .../rest/api/impl/CategoriesImpl.java | 88 +++++-- .../org/alfresco/rest/api/model/Category.java | 1 - .../CategoriesEntityResourceTest.java | 15 ++ .../rest/api/impl/CategoriesImplTest.java | 249 ++++++++++++++++-- 14 files changed, 776 insertions(+), 187 deletions(-) create mode 100644 packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CategoriesRestTest.java create mode 100644 packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/UpdateCategoriesTests.java diff --git a/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/model/RestCategoryModel.java b/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/model/RestCategoryModel.java index 5c94132075..e25c56e22a 100644 --- a/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/model/RestCategoryModel.java +++ b/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/model/RestCategoryModel.java @@ -128,5 +128,52 @@ This must be unique within the parent category. ", count=" + count + '}'; } + + public static Builder builder() + { + return new Builder(); + } + + public static class Builder + { + private String id; + private String name; + private String parentId; + private boolean hasChildren; + + public Builder id(String id) + { + this.id = id; + return this; + } + + public Builder name(String name) + { + this.name = name; + return this; + } + + public Builder parentId(String parentId) + { + this.parentId = parentId; + return this; + } + + public Builder hasChildren(boolean hasChildren) + { + this.hasChildren = hasChildren; + return this; + } + + public RestCategoryModel create() + { + final RestCategoryModel category = new RestCategoryModel(); + category.setId(id); + category.setName(name); + category.setParentId(parentId); + category.setHasChildren(hasChildren); + return category; + } + } } diff --git a/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java b/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java index 33697d5a65..9dbdb38ab1 100644 --- a/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java +++ b/packaging/tests/tas-restapi/src/main/java/org/alfresco/rest/requests/Categories.java @@ -71,7 +71,7 @@ public class Categories extends ModelRequest /** * Create single category. * - * @param restCategoryModel The categories to create. + * @param restCategoryModel The category to create. * @return Created category with additional data populated by the repository. */ public RestCategoryModel createSingleCategory(RestCategoryModel restCategoryModel) @@ -93,8 +93,19 @@ public class Categories extends ModelRequest } /** - * Delete category. + * Update single category. + * - PUT /categories/{categoryId} * + * @param restCategoryModel The categories to update. + * @return Created category with additional data populated by the repository. + */ + public RestCategoryModel updateCategory(RestCategoryModel restCategoryModel) + { + RestRequest request = RestRequest.requestWithBody(HttpMethod.PUT, restCategoryModel.toJson(), "categories/{categoryId}", category.getId()); + return restWrapper.processModel(RestCategoryModel.class, request); + } + /** + * Delete category. * - DELETE /categories/{categoryId} */ public void deleteCategory() diff --git a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CategoriesRestTest.java b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CategoriesRestTest.java new file mode 100644 index 0000000000..660729bfb6 --- /dev/null +++ b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CategoriesRestTest.java @@ -0,0 +1,91 @@ +/* + * #%L + * Alfresco Remote API + * %% + * Copyright (C) 2005 - 2022 Alfresco Software Limited + * %% + * This file is part of the Alfresco software. + * If the software was purchased under a paid Alfresco license, the terms of + * the paid license agreement will prevail. Otherwise, the software is + * provided under the following open source license terms: + * + * Alfresco is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Alfresco is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with Alfresco. If not, see . + * #L% + */ + +package org.alfresco.rest.categories; + +import static org.alfresco.utility.data.RandomData.getRandomName; +import static org.alfresco.utility.report.log.Step.STEP; +import static org.springframework.http.HttpStatus.CREATED; + +import org.alfresco.rest.RestTest; +import org.alfresco.rest.model.RestCategoryModel; +import org.alfresco.utility.model.UserModel; +import org.testng.annotations.BeforeClass; + +abstract class CategoriesRestTest extends RestTest +{ + protected static final String ROOT_CATEGORY_ID = "-root-"; + protected static final String CATEGORY_NAME_PREFIX = "CategoryName"; + protected static final String FIELD_NAME = "name"; + protected static final String FIELD_ID = "id"; + protected static final String FIELD_PARENT_ID = "parentId"; + protected static final String FIELD_HAS_CHILDREN = "hasChildren"; + + protected UserModel user; + + @BeforeClass(alwaysRun = true) + public void dataPreparation() throws Exception + { + STEP("Create a user"); + user = dataUser.createRandomTestUser(); + } + + protected RestCategoryModel prepareCategoryUnderRoot() + { + return prepareCategoryUnder(ROOT_CATEGORY_ID); + } + + protected RestCategoryModel prepareCategoryUnder(final String parentId) + { + final RestCategoryModel parentCategory = createCategoryModelWithId(parentId); + final RestCategoryModel categoryModel = createCategoryModelWithName(getRandomName(CATEGORY_NAME_PREFIX)); + final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(parentCategory) + .createSingleCategory(categoryModel); + restClient.assertStatusCodeIs(CREATED); + + return createdCategory; + } + + protected RestCategoryModel createCategoryModelWithId(final String id) + { + return createCategoryModelWithIdAndName(id, null); + } + + protected RestCategoryModel createCategoryModelWithName(final String name) + { + return createCategoryModelWithIdAndName(null, name); + } + + protected RestCategoryModel createCategoryModelWithIdAndName(final String id, final String name) + { + return RestCategoryModel.builder() + .id(id) + .name(name) + .create(); + } +} diff --git a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java index 68e199dcf9..92ccb56d44 100644 --- a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java +++ b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/CreateCategoriesTests.java @@ -36,32 +36,17 @@ import java.util.List; import java.util.stream.Collectors; import java.util.stream.IntStream; -import org.alfresco.rest.RestTest; import org.alfresco.rest.model.RestCategoryModel; import org.alfresco.rest.model.RestCategoryModelsCollection; import org.alfresco.utility.data.RandomData; import org.alfresco.utility.model.FolderModel; import org.alfresco.utility.model.SiteModel; import org.alfresco.utility.model.TestGroup; -import org.alfresco.utility.model.UserModel; import org.apache.commons.lang3.StringUtils; -import org.testng.annotations.BeforeClass; import org.testng.annotations.Test; -public class CreateCategoriesTests extends RestTest +public class CreateCategoriesTests extends CategoriesRestTest { - private static final String FIELD_NAME = "name"; - private static final String FIELD_PARENT_ID = "parentId"; - private static final String FIELD_HAS_CHILDREN = "hasChildren"; - private static final String FIELD_ID = "id"; - private UserModel user; - - @BeforeClass(alwaysRun = true) - public void dataPreparation() throws Exception - { - STEP("Create a user"); - user = dataUser.createRandomTestUser(); - } /** * Check we can create a category as direct child of root category @@ -70,10 +55,8 @@ public class CreateCategoriesTests extends RestTest public void testCreateCategoryUnderRoot() { STEP("Create a category under root category (as admin)"); - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId("-root-"); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setName(RandomData.getRandomName("Category")); + final RestCategoryModel rootCategory = createCategoryModelWithId(ROOT_CATEGORY_ID); + final RestCategoryModel aCategory = createCategoryModelWithName(RandomData.getRandomName("Category")); final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) .withCoreAPI() .usingCategory(rootCategory) @@ -92,10 +75,8 @@ public class CreateCategoriesTests extends RestTest public void testCreateCategoryWithoutName_andFail() { STEP("Create a category under root category (as admin)"); - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId("-root-"); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setName(StringUtils.EMPTY); + final RestCategoryModel rootCategory = createCategoryModelWithId(ROOT_CATEGORY_ID); + final RestCategoryModel aCategory = createCategoryModelWithName(StringUtils.EMPTY); restClient.authenticateUser(dataUser.getAdminUser()) .withCoreAPI() .usingCategory(rootCategory) @@ -110,10 +91,8 @@ public class CreateCategoriesTests extends RestTest public void testCreateSeveralSubCategories() { STEP("Create a category under root category (as admin)"); - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId("-root-"); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setName(RandomData.getRandomName("Category")); + final RestCategoryModel rootCategory = createCategoryModelWithId(ROOT_CATEGORY_ID); + final RestCategoryModel aCategory = createCategoryModelWithName(RandomData.getRandomName("Category")); final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) .withCoreAPI() .usingCategory(rootCategory) @@ -160,10 +139,8 @@ public class CreateCategoriesTests extends RestTest public void testCreateOver100SubCategories() { STEP("Create a category under root category (as admin)"); - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId("-root-"); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setName(RandomData.getRandomName("Category")); + final RestCategoryModel rootCategory = createCategoryModelWithId(ROOT_CATEGORY_ID); + final RestCategoryModel aCategory = createCategoryModelWithName(RandomData.getRandomName("Category")); final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) .withCoreAPI() .usingCategory(rootCategory) @@ -208,15 +185,13 @@ public class CreateCategoriesTests extends RestTest public void testCreateCategoryUnderRootAsRegularUser_andFail() { STEP("Create a category under root category (as user)"); - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId("-root-"); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setName(RandomData.getRandomName("Category")); + final RestCategoryModel rootCategory = createCategoryModelWithId(ROOT_CATEGORY_ID); + final RestCategoryModel aCategory = createCategoryModelWithName(RandomData.getRandomName("Category")); restClient.authenticateUser(user) .withCoreAPI() .usingCategory(rootCategory) .createSingleCategory(aCategory); - restClient.assertStatusCodeIs(FORBIDDEN).assertLastError().containsSummary("Current user does not have permission to create a category"); + restClient.assertStatusCodeIs(FORBIDDEN).assertLastError().containsSummary("Current user does not have permission to manage a category"); } /** @@ -226,11 +201,9 @@ public class CreateCategoriesTests extends RestTest public void testCreateCategoryUnderNonExistingParent_andFail() { STEP("Create a category under non existing category node (as admin)"); - final RestCategoryModel rootCategory = new RestCategoryModel(); final String id = "non-existing-node-id"; - rootCategory.setId(id); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setName(RandomData.getRandomName("Category")); + final RestCategoryModel rootCategory = createCategoryModelWithId(id); + final RestCategoryModel aCategory = createCategoryModelWithName(RandomData.getRandomName("Category")); restClient.authenticateUser(dataUser.getAdminUser()) .withCoreAPI() .usingCategory(rootCategory) @@ -249,10 +222,8 @@ public class CreateCategoriesTests extends RestTest final FolderModel folder = dataContent.usingUser(user).usingSite(site).createFolder(); STEP("Create a category under folder node (as admin)"); - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId(folder.getNodeRef()); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setName(RandomData.getRandomName("Category")); + final RestCategoryModel rootCategory = createCategoryModelWithId(folder.getNodeRef()); + final RestCategoryModel aCategory = createCategoryModelWithName(RandomData.getRandomName("Category")); restClient.authenticateUser(dataUser.getAdminUser()) .withCoreAPI() .usingCategory(rootCategory) @@ -263,11 +234,7 @@ public class CreateCategoriesTests extends RestTest static List getCategoriesToCreate(final int count) { return IntStream.range(0, count) - .mapToObj(i -> { - final RestCategoryModel aSubCategory = new RestCategoryModel(); - aSubCategory.setName((RandomData.getRandomName("SubCategory"))); - return aSubCategory; - }) - .collect(Collectors.toList()); + .mapToObj(i -> RestCategoryModel.builder().name(RandomData.getRandomName("SubCategory")).create()) + .collect(Collectors.toList()); } } diff --git a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/DeleteCategoriesTests.java b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/DeleteCategoriesTests.java index e0b11e582c..779876017b 100644 --- a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/DeleteCategoriesTests.java +++ b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/DeleteCategoriesTests.java @@ -26,34 +26,20 @@ package org.alfresco.rest.categories; -import org.alfresco.rest.RestTest; -import org.alfresco.rest.model.RestCategoryModel; -import org.alfresco.utility.data.RandomData; -import org.alfresco.utility.model.FolderModel; -import org.alfresco.utility.model.SiteModel; -import org.alfresco.utility.model.TestGroup; -import org.alfresco.utility.model.UserModel; -import org.testng.annotations.BeforeClass; -import org.testng.annotations.Test; - import static org.alfresco.utility.report.log.Step.STEP; import static org.springframework.http.HttpStatus.BAD_REQUEST; -import static org.springframework.http.HttpStatus.CREATED; import static org.springframework.http.HttpStatus.FORBIDDEN; import static org.springframework.http.HttpStatus.NOT_FOUND; import static org.springframework.http.HttpStatus.NO_CONTENT; -public class DeleteCategoriesTests extends RestTest { +import org.alfresco.rest.model.RestCategoryModel; +import org.alfresco.utility.model.FolderModel; +import org.alfresco.utility.model.SiteModel; +import org.alfresco.utility.model.TestGroup; +import org.testng.annotations.Test; - private UserModel user; - - - @BeforeClass(alwaysRun = true) - public void dataPreparation() throws Exception - { - STEP("Create a user"); - user = dataUser.createRandomTestUser(); - } +public class DeleteCategoriesTests extends CategoriesRestTest +{ /** * Check we can delete a category. @@ -62,7 +48,7 @@ public class DeleteCategoriesTests extends RestTest { public void testDeleteCategory() { STEP("Create a category and send a request to delete it."); - RestCategoryModel aCategory = createCategory(); + RestCategoryModel aCategory = prepareCategoryUnderRoot(); restClient.authenticateUser(dataUser.getAdminUser()).withCoreAPI().usingCategory(aCategory).deleteCategory(); restClient.assertStatusCodeIs(NO_CONTENT); @@ -77,9 +63,9 @@ public class DeleteCategoriesTests extends RestTest { @Test(groups = {TestGroup.REST_API}) public void testDeleteCategoryAsRegularUser_andFail() { - RestCategoryModel aCategory = createCategory(); + RestCategoryModel aCategory = prepareCategoryUnderRoot(); restClient.authenticateUser(user).withCoreAPI().usingCategory(aCategory).deleteCategory(); - restClient.assertStatusCodeIs(FORBIDDEN).assertLastError().containsSummary("Current user does not have permission to delete a category"); + restClient.assertStatusCodeIs(FORBIDDEN).assertLastError().containsSummary("Current user does not have permission to manage a category"); } /** @@ -89,9 +75,8 @@ public class DeleteCategoriesTests extends RestTest { public void testDeleteNonExistentCategory() { STEP("Get category with non-existent id"); - final RestCategoryModel rootCategory = new RestCategoryModel(); final String id = "non-existing-dummy-id"; - rootCategory.setId(id); + final RestCategoryModel rootCategory = createCategoryModelWithId(id); STEP("Attempt to delete category with non-existent id and receive 404"); restClient.authenticateUser(dataUser.getAdminUser()).withCoreAPI().usingCategory(rootCategory).deleteCategory(); @@ -110,24 +95,8 @@ public class DeleteCategoriesTests extends RestTest { String id = folder.getNodeRef(); STEP("Create a category, set its id to the folder id and attempt to delete it"); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setId(id); + final RestCategoryModel aCategory = createCategoryModelWithId(id); restClient.authenticateUser(dataUser.getAdminUser()).withCoreAPI().usingCategory(aCategory).deleteCategory(); restClient.assertStatusCodeIs(BAD_REQUEST).assertLastError().containsSummary("Node id does not refer to a valid category"); } - - public RestCategoryModel createCategory() - { - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId("-root-"); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setName(RandomData.getRandomName("Category")); - final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) - .withCoreAPI() - .usingCategory(rootCategory) - .createSingleCategory(aCategory); - restClient.assertStatusCodeIs(CREATED); - - return createdCategory; - } } diff --git a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/GetCategoriesTests.java b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/GetCategoriesTests.java index a8d2da0340..ac1e7c666e 100644 --- a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/GetCategoriesTests.java +++ b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/GetCategoriesTests.java @@ -35,35 +35,20 @@ import static org.testng.Assert.assertTrue; import java.util.List; import java.util.stream.Collectors; -import java.util.stream.IntStream; -import org.alfresco.rest.RestTest; -import org.alfresco.rest.core.RestResponse; import org.alfresco.rest.model.RestCategoryModel; import org.alfresco.rest.model.RestCategoryModelsCollection; import org.alfresco.utility.data.RandomData; import org.alfresco.utility.model.FolderModel; import org.alfresco.utility.model.SiteModel; import org.alfresco.utility.model.TestGroup; -import org.alfresco.utility.model.UserModel; -import org.testng.annotations.BeforeClass; import org.testng.annotations.Test; -public class GetCategoriesTests extends RestTest +public class GetCategoriesTests extends CategoriesRestTest { private static final List DEFAULT_ROOT_CATEGORIES = List.of("Software Document Classification", "Languages", "Regions", "Tags"); - private static final String ROOT = "-root-"; private static final String NON_EXISTING_CATEGORY_ID = "non-existing-category-id"; - private UserModel user; - - @BeforeClass(alwaysRun = true) - public void dataPreparation() throws Exception - { - STEP("Create a user"); - user = dataUser.createRandomTestUser(); - } - /** * Check we can get a category which we just created in as direct child of root category */ @@ -71,22 +56,17 @@ public class GetCategoriesTests extends RestTest public void testGetCategoryById() { STEP("Create a category under root category (as admin)"); - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId(ROOT); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setName(RandomData.getRandomName("Category")); + final RestCategoryModel rootCategory = createCategoryModelWithId(ROOT_CATEGORY_ID); + final RestCategoryModel aCategory = createCategoryModelWithName(RandomData.getRandomName("Category")); final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) .withCoreAPI() .usingCategory(rootCategory) .createSingleCategory(aCategory); restClient.assertStatusCodeIs(CREATED); - createdCategory.assertThat() - .field("name").is(aCategory.getName()); - createdCategory.assertThat() - .field("parentId").is(rootCategory.getId()); - createdCategory.assertThat() - .field("hasChildren").is(false); + createdCategory.assertThat().field("name").is(aCategory.getName()); + createdCategory.assertThat().field("parentId").is(rootCategory.getId()); + createdCategory.assertThat().field("hasChildren").is(false); STEP("Get the created category (as regular user)"); final RestCategoryModel categoryFromGet = @@ -102,8 +82,7 @@ public class GetCategoriesTests extends RestTest public void testGetCategoryByIdProvidingRootAsId() { STEP("Get category with -root- as id"); - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId(ROOT); + final RestCategoryModel rootCategory = createCategoryModelWithId(ROOT_CATEGORY_ID); restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategory(); restClient.assertStatusCodeIs(BAD_REQUEST).assertLastError().containsSummary("Node id does not refer to a valid category"); } @@ -119,8 +98,7 @@ public class GetCategoriesTests extends RestTest final FolderModel folder = dataContent.usingUser(user).usingSite(site).createFolder(); STEP("Get category with folder id passed as id"); - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId(folder.getNodeRef()); + final RestCategoryModel rootCategory = createCategoryModelWithId(folder.getNodeRef()); restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategory(); restClient.assertStatusCodeIs(BAD_REQUEST).assertLastError().containsSummary("Node id does not refer to a valid category"); } @@ -132,9 +110,8 @@ public class GetCategoriesTests extends RestTest public void testGetCategoryByIdProvidingNonExistingId() { STEP("Get category with id which does not exist"); - final RestCategoryModel rootCategory = new RestCategoryModel(); final String id = NON_EXISTING_CATEGORY_ID; - rootCategory.setId(id); + final RestCategoryModel rootCategory = createCategoryModelWithId(id); restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategory(); restClient.assertStatusCodeIs(NOT_FOUND).assertLastError().containsSummary(id); } @@ -146,8 +123,7 @@ public class GetCategoriesTests extends RestTest public void testGetCategoryChildren() { STEP("Get category children with -root- as parent id"); - final RestCategoryModel rootCategory = new RestCategoryModel(); - rootCategory.setId(ROOT); + final RestCategoryModel rootCategory = createCategoryModelWithId(ROOT_CATEGORY_ID); RestCategoryModelsCollection childCategoriesList = restClient.authenticateUser(user).withCoreAPI().usingCategory(rootCategory).getCategoryChildren(); restClient.assertStatusCodeIs(OK); @@ -159,8 +135,7 @@ public class GetCategoriesTests extends RestTest .collect(Collectors.toList()) .containsAll(DEFAULT_ROOT_CATEGORIES)); STEP("Create a new category under root and make sure it is returned as one of root's children"); - final RestCategoryModel aCategory = new RestCategoryModel(); - aCategory.setName((RandomData.getRandomName("newCategoryUnderRoot"))); + final RestCategoryModel aCategory = createCategoryModelWithName(RandomData.getRandomName("newCategoryUnderRoot")); final RestCategoryModel createdCategory = restClient.authenticateUser(dataUser.getAdminUser()) .withCoreAPI() .usingCategory(rootCategory) @@ -199,8 +174,7 @@ public class GetCategoriesTests extends RestTest final FolderModel folder = dataContent.usingUser(user).usingSite(site).createFolder(); STEP("Get category children with folder id passed as parent id"); - final RestCategoryModel parentCategory = new RestCategoryModel(); - parentCategory.setId(folder.getNodeRef()); + final RestCategoryModel parentCategory = createCategoryModelWithId(folder.getNodeRef()); restClient.authenticateUser(user).withCoreAPI().usingCategory(parentCategory).getCategoryChildren(); restClient.assertStatusCodeIs(BAD_REQUEST).assertLastError().containsSummary("Node id does not refer to a valid category"); } @@ -213,9 +187,8 @@ public class GetCategoriesTests extends RestTest { STEP("Get category with folder id passed as id"); - final RestCategoryModel parentCategory = new RestCategoryModel(); final String parentId = NON_EXISTING_CATEGORY_ID; - parentCategory.setId(parentId); + final RestCategoryModel parentCategory = createCategoryModelWithId(parentId); restClient.authenticateUser(user).withCoreAPI().usingCategory(parentCategory).getCategoryChildren(); restClient.assertStatusCodeIs(NOT_FOUND).assertLastError().containsSummary(parentId); } diff --git a/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/UpdateCategoriesTests.java b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/UpdateCategoriesTests.java new file mode 100644 index 0000000000..f439c07b6a --- /dev/null +++ b/packaging/tests/tas-restapi/src/test/java/org/alfresco/rest/categories/UpdateCategoriesTests.java @@ -0,0 +1,214 @@ +/* + * #%L + * Alfresco Remote API + * %% + * Copyright (C) 2005 - 2022 Alfresco Software Limited + * %% + * This file is part of the Alfresco software. + * If the software was purchased under a paid Alfresco license, the terms of + * the paid license agreement will prevail. Otherwise, the software is + * provided under the following open source license terms: + * + * Alfresco is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Alfresco is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with Alfresco. If not, see . + * #L% + */ + +package org.alfresco.rest.categories; + +import static org.alfresco.utility.data.RandomData.getRandomName; +import static org.alfresco.utility.report.log.Step.STEP; +import static org.springframework.http.HttpStatus.BAD_REQUEST; +import static org.springframework.http.HttpStatus.FORBIDDEN; +import static org.springframework.http.HttpStatus.NOT_FOUND; +import static org.springframework.http.HttpStatus.OK; + +import org.alfresco.rest.model.RestCategoryModel; +import org.alfresco.utility.model.FolderModel; +import org.alfresco.utility.model.SiteModel; +import org.alfresco.utility.model.TestGroup; +import org.alfresco.utility.model.UserModel; +import org.testng.annotations.Test; + +public class UpdateCategoriesTests extends CategoriesRestTest +{ + private static final String CATEGORY_NEW_NAME_PREFIX = "NewCategoryName"; + private static final String IGNORE_FIELD_NAME = FIELD_NAME; + + /** + * Update a category (direct child of root category) + */ + @Test(groups = { TestGroup.REST_API}) + public void testUpdateCategory_asAdmin() + { + STEP("Prepare as admin a category under root category"); + final RestCategoryModel createdCategory = prepareCategoryUnderRoot(); + + STEP("Update as admin newly created category"); + final String categoryNewName = getRandomName(CATEGORY_NEW_NAME_PREFIX); + final RestCategoryModel fixedCategoryModel = createCategoryModelWithName(categoryNewName); + final RestCategoryModel updatedCategory = restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(createdCategory) + .updateCategory(fixedCategoryModel); + + restClient.assertStatusCodeIs(OK); + updatedCategory.assertThat().isEqualTo(createdCategory, IGNORE_FIELD_NAME); + updatedCategory.assertThat().field(FIELD_NAME).isNot(createdCategory.getName()); + updatedCategory.assertThat().field(FIELD_NAME).is(categoryNewName); + } + + /** + * Update a subcategory of root's child category + */ + @Test(groups = { TestGroup.REST_API}) + public void testUpdateSubcategory_asAdmin() + { + STEP("Prepare as admin a category under root category"); + final RestCategoryModel createdCategory = prepareCategoryUnderRoot(); + + STEP("Prepare as admin a subcategory of root's child category"); + final RestCategoryModel createdSubcategory = prepareCategoryUnder(createdCategory.getId()); + + STEP("Update as admin newly created subcategory"); + final String categoryNewName = getRandomName(CATEGORY_NEW_NAME_PREFIX); + final RestCategoryModel fixedCategoryModel = createCategoryModelWithName(categoryNewName); + final RestCategoryModel updatedCategory = restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(createdSubcategory) + .updateCategory(fixedCategoryModel); + + restClient.assertStatusCodeIs(OK); + updatedCategory.assertThat().isEqualTo(createdSubcategory, IGNORE_FIELD_NAME); + updatedCategory.assertThat().field(FIELD_NAME).is(categoryNewName); + } + + /** + * Try to update a category as a user and expect 403 (Forbidden) in response + */ + @Test(groups = { TestGroup.REST_API}) + public void testUpdateCategory_asUserAndExpect403() + { + STEP("Prepare as admin a category under root category"); + final RestCategoryModel createdCategory = prepareCategoryUnderRoot(); + + STEP("Try to update as user newly created category"); + final RestCategoryModel fixedCategoryModel = createCategoryModelWithName(getRandomName(CATEGORY_NEW_NAME_PREFIX)); + restClient.authenticateUser(user) + .withCoreAPI() + .usingCategory(createdCategory) + .updateCategory(fixedCategoryModel); + + restClient.assertStatusCodeIs(FORBIDDEN); + } + + /** + * Try to update a non-existing category and receive 404 (Not Found) + */ + @Test(groups = { TestGroup.REST_API}) + public void testUpdateCategory_usingNonExistingCategoryAndExpect404() + { + STEP("Create a fake parent category"); + final RestCategoryModel nonExistingCategory = createCategoryModelWithIdAndName("non-existing-dummy-id", getRandomName(CATEGORY_NAME_PREFIX)); + + STEP("Try to update as admin fake category"); + final RestCategoryModel fixedCategoryModel = createCategoryModelWithName(getRandomName(CATEGORY_NEW_NAME_PREFIX)); + restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(nonExistingCategory) + .updateCategory(fixedCategoryModel); + + restClient.assertStatusCodeIs(NOT_FOUND); + } + + /** + * Try to update a non-category (folder) node and receive 400 (Bad Request) + */ + @Test(groups = { TestGroup.REST_API}) + public void testUpdateCategory_usingFolderNodeAndExpect400() + { + STEP("Prepare a site and a folder inside it"); + final UserModel user = dataUser.createRandomTestUser(); + final SiteModel site = dataSite.usingUser(user).createPublicRandomSite(); + final FolderModel folder = dataContent.usingUser(user).usingSite(site).createFolder(); + final RestCategoryModel categoryWithFolderId = createCategoryModelWithIdAndName(folder.getNodeRef(), getRandomName(CATEGORY_NAME_PREFIX)); + + STEP("Try to update as admin folder node as category"); + final RestCategoryModel fixedCategoryModel = createCategoryModelWithName(getRandomName(CATEGORY_NEW_NAME_PREFIX)); + restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(categoryWithFolderId) + .updateCategory(fixedCategoryModel); + + restClient.assertStatusCodeIs(BAD_REQUEST); + } + + /** + * Try to update a root category and receive 400 (Bad Request) + */ + @Test(groups = { TestGroup.REST_API}) + public void testUpdateCategory_usingRootCategoryAndExpect400() + { + STEP("Create root category model"); + final RestCategoryModel rootCategoryModel = createCategoryModelWithId(ROOT_CATEGORY_ID); + + STEP("Try to update as admin root category"); + final RestCategoryModel fixedCategoryModel = createCategoryModelWithName(getRandomName(CATEGORY_NEW_NAME_PREFIX)); + restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(rootCategoryModel) + .updateCategory(fixedCategoryModel); + + restClient.assertStatusCodeIs(BAD_REQUEST); + } + + /** + * Try to update a category with an empty name and receive 400 (Bad Request) + */ + @Test(groups = { TestGroup.REST_API}) + public void testUpdateCategory_withEmptyNameAndExpect400() + { + STEP("Prepare as admin a category under root category"); + final RestCategoryModel createdCategory = prepareCategoryUnderRoot(); + + STEP("Try to update as admin newly created category with a category without name"); + final RestCategoryModel fixedCategoryModel = createCategoryModelWithName(null); + restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(createdCategory) + .updateCategory(fixedCategoryModel); + + restClient.assertStatusCodeIs(BAD_REQUEST); + } + + /** + * Try to update a category with an invalid, but not important ID in body and receive 200 (OK) + */ + @Test(groups = { TestGroup.REST_API}) + public void testUpdateCategory_withIgnoredInvalidIdInBodyAndExpect200() + { + STEP("Prepare as admin a category under root category"); + final RestCategoryModel createdCategory = prepareCategoryUnderRoot(); + + STEP("Try to update as admin newly created category with a category with invalid ID and receive 200"); + final String categoryNewName = getRandomName(CATEGORY_NEW_NAME_PREFIX); + final RestCategoryModel fixedCategoryModel = createCategoryModelWithIdAndName("non-existing-dummy-id", categoryNewName); + final RestCategoryModel updatedCategory = restClient.authenticateUser(dataUser.getAdminUser()) + .withCoreAPI() + .usingCategory(createdCategory) + .updateCategory(fixedCategoryModel); + + restClient.assertStatusCodeIs(OK); + updatedCategory.assertThat().field(FIELD_NAME).is(categoryNewName); + } +} diff --git a/remote-api/src/main/java/org/alfresco/rest/api/Categories.java b/remote-api/src/main/java/org/alfresco/rest/api/Categories.java index a3babc5905..c5714f7acb 100644 --- a/remote-api/src/main/java/org/alfresco/rest/api/Categories.java +++ b/remote-api/src/main/java/org/alfresco/rest/api/Categories.java @@ -36,12 +36,21 @@ import org.alfresco.service.Experimental; @Experimental public interface Categories { - Category getCategoryById(String id, Parameters params); + Category getCategoryById(String id, Parameters parameters); List createSubcategories(String parentCategoryId, List categories, Parameters parameters); - CollectionWithPagingInfo getCategoryChildren(String parentCategoryId, Parameters params); + CollectionWithPagingInfo getCategoryChildren(String parentCategoryId, Parameters parameters); - void deleteCategoryById(String id, Parameters params); + /** + * Update category by ID. Currently, it's possible only to update the name of category. + * + * @param id Category ID. + * @param fixedCategoryModel Fixed category model. + * @return Updated category. + */ + Category updateCategoryById(String id, Category fixedCategoryModel); + + void deleteCategoryById(String id, Parameters parameters); } diff --git a/remote-api/src/main/java/org/alfresco/rest/api/categories/CategoriesEntityResource.java b/remote-api/src/main/java/org/alfresco/rest/api/categories/CategoriesEntityResource.java index df8483958f..23b79067ac 100644 --- a/remote-api/src/main/java/org/alfresco/rest/api/categories/CategoriesEntityResource.java +++ b/remote-api/src/main/java/org/alfresco/rest/api/categories/CategoriesEntityResource.java @@ -42,7 +42,8 @@ import org.alfresco.rest.framework.resource.parameters.Parameters; */ @EntityResource(name = "categories", title = "Categories") public class CategoriesEntityResource implements EntityResourceAction.ReadById, - EntityResourceAction.Delete + EntityResourceAction.Update, + EntityResourceAction.Delete { private final Categories categories; @@ -51,20 +52,45 @@ public class CategoriesEntityResource implements EntityResourceAction.ReadById, RelationshipResourceAction.Read +public class SubcategoriesRelation implements RelationshipResourceAction.Create, + RelationshipResourceAction.Read { private final Categories categories; @@ -49,6 +50,9 @@ public class SubcategoriesRelation implements RelationshipResourceAction.Create< this.categories = categories; } + /** + * POST /categories/{categoryId}/subcategories + */ @WebApiDescription(title = "Create a category", description = "Creates one or more categories under a parent category", successStatus = HttpServletResponse.SC_CREATED) @@ -58,6 +62,9 @@ public class SubcategoriesRelation implements RelationshipResourceAction.Create< return categories.createSubcategories(parentCategoryId, categoryList, parameters); } + /** + * GET /categories/{categoryId}/subcategories + */ @WebApiDescription(title = "List category direct children", description = "Lists direct children of a parent category", successStatus = HttpServletResponse.SC_OK) diff --git a/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java b/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java index f00cede7a9..515e2263e4 100644 --- a/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java +++ b/remote-api/src/main/java/org/alfresco/rest/api/impl/CategoriesImpl.java @@ -49,6 +49,7 @@ import org.alfresco.service.cmr.repository.NodeService; import org.alfresco.service.cmr.repository.StoreRef; import org.alfresco.service.cmr.search.CategoryService; import org.alfresco.service.cmr.security.AuthorityService; +import org.alfresco.service.namespace.QName; import org.alfresco.service.namespace.RegexQNamePattern; import org.apache.commons.collections.CollectionUtils; import org.apache.commons.lang3.StringUtils; @@ -57,9 +58,9 @@ import org.apache.commons.lang3.StringUtils; public class CategoriesImpl implements Categories { static final String NOT_A_VALID_CATEGORY = "Node id does not refer to a valid category"; - static final String NO_PERMISSION_TO_CREATE_A_CATEGORY = "Current user does not have permission to create a category"; - static final String NO_PERMISSION_TO_DELETE_A_CATEGORY = "Current user does not have permission to delete a category"; - private static final String NOT_NULL_OR_EMPTY = "Category name must not be null or empty"; + static final String NO_PERMISSION_TO_MANAGE_A_CATEGORY = "Current user does not have permission to manage a category"; + static final String NOT_NULL_OR_EMPTY = "Category name must not be null or empty"; + static final String FIELD_NOT_MATCH = "Category field: %s does not match the original one"; private final AuthorityService authorityService; private final CategoryService categoryService; @@ -89,10 +90,7 @@ public class CategoriesImpl implements Categories @Override public List createSubcategories(String parentCategoryId, List categories, Parameters parameters) { - if (!authorityService.hasAdminAuthority()) - { - throw new PermissionDeniedException(NO_PERMISSION_TO_CREATE_A_CATEGORY); - } + verifyAdminAuthority(); final NodeRef parentNodeRef = getCategoryNodeRef(parentCategoryId); final List categoryNodeRefs = categories.stream() .map(c -> createCategoryNodeRef(parentNodeRef, c)) @@ -116,15 +114,26 @@ public class CategoriesImpl implements Categories } @Override - public void deleteCategoryById(String id, Parameters params) + public Category updateCategoryById(final String id, final Category fixedCategoryModel) { - if (!authorityService.hasAdminAuthority()) + verifyAdminAuthority(); + final NodeRef categoryNodeRef = getCategoryNodeRef(id); + if (isRootCategory(categoryNodeRef)) { - throw new PermissionDeniedException(NO_PERMISSION_TO_DELETE_A_CATEGORY); + throw new InvalidArgumentException(NOT_A_VALID_CATEGORY, new String[]{id}); } - final NodeRef nodeRef = nodes.validateNode(id); - if (isNotACategory(nodeRef) || isRootCategory(nodeRef)) + verifyCategoryFields(fixedCategoryModel); + + return mapToCategory(changeCategoryName(categoryNodeRef, fixedCategoryModel.getName())); + } + + @Override + public void deleteCategoryById(String id, Parameters parameters) + { + verifyAdminAuthority(); + final NodeRef nodeRef = getCategoryNodeRef(id); + if (isRootCategory(nodeRef)) { throw new InvalidArgumentException(NOT_A_VALID_CATEGORY, new String[]{id}); } @@ -132,6 +141,14 @@ public class CategoriesImpl implements Categories nodeService.deleteNode(nodeRef); } + private void verifyAdminAuthority() + { + if (!authorityService.hasAdminAuthority()) + { + throw new PermissionDeniedException(NO_PERMISSION_TO_MANAGE_A_CATEGORY); + } + } + /** * This method gets category NodeRef for a given category id. * If '-root-' is passed as category id, then it's retrieved as a call to {@link org.alfresco.service.cmr.search.CategoryService#getRootCategoryNodeRef} @@ -164,17 +181,10 @@ public class CategoriesImpl implements Categories private NodeRef createCategoryNodeRef(NodeRef parentNodeRef, Category c) { - if (StringUtils.isEmpty(c.getName())) { - throw new InvalidArgumentException(NOT_NULL_OR_EMPTY); - } + verifyCategoryFields(c); return categoryService.createCategory(parentNodeRef, c.getName()); } - private boolean isNotACategory(NodeRef nodeRef) - { - return !nodes.isSubClass(nodeRef, ContentModel.TYPE_CATEGORY, false); - } - private Category mapToCategory(NodeRef nodeRef) { final Node categoryNode = nodes.getNode(nodeRef.getId()); @@ -188,6 +198,11 @@ public class CategoriesImpl implements Categories .create(); } + private boolean isNotACategory(NodeRef nodeRef) + { + return !nodes.isSubClass(nodeRef, ContentModel.TYPE_CATEGORY, false); + } + private boolean isRootCategory(final NodeRef nodeRef) { final List parentAssocs = nodeService.getParentAssocs(nodeRef); @@ -199,4 +214,37 @@ public class CategoriesImpl implements Categories final NodeRef parentRef = nodeService.getPrimaryParent(nodeRef).getParentRef(); return isRootCategory(parentRef) ? PATH_ROOT : parentRef.getId(); } + + /** + * Change category qualified name. + * + * @param categoryNodeRef Category node reference. + * @param newName New name. + * @return Updated category. + */ + private NodeRef changeCategoryName(final NodeRef categoryNodeRef, final String newName) + { + final ChildAssociationRef parentAssociation = nodeService.getPrimaryParent(categoryNodeRef); + if (parentAssociation == null) + { + throw new InvalidArgumentException(NOT_A_VALID_CATEGORY, new String[]{categoryNodeRef.getId()}); + } + + nodeService.setProperty(categoryNodeRef, ContentModel.PROP_NAME, newName); + final QName newQName = QName.createQName(parentAssociation.getQName().getNamespaceURI(), QName.createValidLocalName(newName)); + return nodeService.moveNode(parentAssociation.getChildRef(), parentAssociation.getParentRef(), parentAssociation.getTypeQName(), newQName).getChildRef(); + } + + /** + * Verify if fixed category name is not empty. + * + * @param fixedCategoryModel Fixed category model. + */ + private void verifyCategoryFields(final Category fixedCategoryModel) + { + if (StringUtils.isEmpty(fixedCategoryModel.getName())) + { + throw new InvalidArgumentException(NOT_NULL_OR_EMPTY); + } + } } diff --git a/remote-api/src/main/java/org/alfresco/rest/api/model/Category.java b/remote-api/src/main/java/org/alfresco/rest/api/model/Category.java index d9b3b6d959..b2f6eeb851 100644 --- a/remote-api/src/main/java/org/alfresco/rest/api/model/Category.java +++ b/remote-api/src/main/java/org/alfresco/rest/api/model/Category.java @@ -137,5 +137,4 @@ public class Category return category; } } - } diff --git a/remote-api/src/test/java/org/alfresco/rest/api/categories/CategoriesEntityResourceTest.java b/remote-api/src/test/java/org/alfresco/rest/api/categories/CategoriesEntityResourceTest.java index 4988ae4f32..56d2e72eca 100644 --- a/remote-api/src/test/java/org/alfresco/rest/api/categories/CategoriesEntityResourceTest.java +++ b/remote-api/src/test/java/org/alfresco/rest/api/categories/CategoriesEntityResourceTest.java @@ -26,7 +26,9 @@ package org.alfresco.rest.api.categories; +import static org.assertj.core.api.Assertions.assertThat; import static org.junit.Assert.assertEquals; +import static org.mockito.ArgumentMatchers.any; import static org.mockito.BDDMockito.given; import static org.mockito.BDDMockito.then; @@ -65,4 +67,17 @@ public class CategoriesEntityResourceTest then(categoriesMock).shouldHaveNoMoreInteractions(); assertEquals(categoryMock, category); } + + @Test + public void testUpdateCategoryById() + { + given(categoriesMock.updateCategoryById(any(), any())).willReturn(categoryMock); + + // when + final Category actualCategory = objectUnderTest.update(CATEGORY_ID, categoryMock, parametersMock); + + then(categoriesMock).should().updateCategoryById(CATEGORY_ID, categoryMock); + then(categoriesMock).shouldHaveNoMoreInteractions(); + assertThat(actualCategory).isNotNull(); + } } diff --git a/remote-api/src/test/java/org/alfresco/rest/api/impl/CategoriesImplTest.java b/remote-api/src/test/java/org/alfresco/rest/api/impl/CategoriesImplTest.java index f4e5dd6f62..ccd35b5b17 100644 --- a/remote-api/src/test/java/org/alfresco/rest/api/impl/CategoriesImplTest.java +++ b/remote-api/src/test/java/org/alfresco/rest/api/impl/CategoriesImplTest.java @@ -27,8 +27,15 @@ package org.alfresco.rest.api.impl; import static org.alfresco.rest.api.Nodes.PATH_ROOT; +import static org.alfresco.rest.api.impl.CategoriesImpl.NOT_A_VALID_CATEGORY; +import static org.alfresco.rest.api.impl.CategoriesImpl.NOT_NULL_OR_EMPTY; +import static org.assertj.core.api.Assertions.assertThat; +import static org.assertj.core.api.Assertions.assertThatExceptionOfType; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertThrows; +import static org.mockito.ArgumentMatchers.any; +import static org.mockito.ArgumentMatchers.anyBoolean; +import static org.mockito.ArgumentMatchers.eq; import static org.mockito.BDDMockito.given; import static org.mockito.BDDMockito.then; import static org.mockito.Mockito.mock; @@ -56,7 +63,9 @@ import org.alfresco.service.cmr.repository.NodeService; import org.alfresco.service.cmr.repository.StoreRef; import org.alfresco.service.cmr.search.CategoryService; import org.alfresco.service.cmr.security.AuthorityService; +import org.alfresco.service.namespace.QName; import org.alfresco.service.namespace.RegexQNamePattern; +import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; import org.mockito.InjectMocks; @@ -70,6 +79,8 @@ public class CategoriesImplTest private static final String CATEGORY_NAME = "categoryName"; private static final String PARENT_ID = "parent-node-id"; private static final String CAT_ROOT_NODE_ID = "cat-root-node-id"; + private static final NodeRef CATEGORY_NODE_REF = createNodeRefWithId(CATEGORY_ID); + private static final Category CATEGORY = createDefaultCategoryWithName(CATEGORY_NAME); @Mock private Nodes nodesMock; @@ -89,12 +100,19 @@ public class CategoriesImplTest @InjectMocks private CategoriesImpl objectUnderTest; + @Before + public void setUp() throws Exception + { + given(authorityServiceMock.hasAdminAuthority()).willReturn(true); + given(nodesMock.validateNode(eq(CATEGORY_ID))).willReturn(CATEGORY_NODE_REF); + given(nodesMock.isSubClass(any(), any(), anyBoolean())).willReturn(true); + } + @Test public void shouldNotGetRootCategoryById() { final NodeRef categoryRootNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, CAT_ROOT_NODE_ID); given(nodesMock.validateNode(CAT_ROOT_NODE_ID)).willReturn(categoryRootNodeRef); - given(nodesMock.isSubClass(categoryRootNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(true); given(categoryChildAssociationRefMock.getQName()).willReturn(ContentModel.ASPECT_GEN_CLASSIFIABLE); given(nodeServiceMock.getParentAssocs(categoryRootNodeRef)).willReturn(List.of(categoryChildAssociationRefMock)); @@ -107,7 +125,7 @@ public class CategoriesImplTest then(nodeServiceMock).should().getParentAssocs(categoryRootNodeRef); then(nodeServiceMock).shouldHaveNoMoreInteractions(); then(categoryServiceMock).shouldHaveNoInteractions(); - then(authorityServiceMock).shouldHaveNoMoreInteractions(); + then(authorityServiceMock).shouldHaveNoInteractions(); } @Test @@ -115,7 +133,6 @@ public class CategoriesImplTest { final NodeRef categoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, CATEGORY_ID); given(nodesMock.validateNode(CATEGORY_ID)).willReturn(categoryNodeRef); - given(nodesMock.isSubClass(categoryNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(true); final Node categoryNode = new Node(); categoryNode.setName(CATEGORY_NAME); categoryNode.setNodeId(CATEGORY_ID); @@ -158,7 +175,6 @@ public class CategoriesImplTest { final NodeRef categoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, CATEGORY_ID); given(nodesMock.validateNode(CATEGORY_ID)).willReturn(categoryNodeRef); - given(nodesMock.isSubClass(categoryNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(true); final Node categoryNode = new Node(); categoryNode.setName(CATEGORY_NAME); categoryNode.setNodeId(CATEGORY_ID); @@ -319,11 +335,10 @@ public class CategoriesImplTest @Test public void testCreateCategoryUnderRoot() { - given(authorityServiceMock.hasAdminAuthority()).willReturn(true); final NodeRef parentCategoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PATH_ROOT); given(categoryServiceMock.getRootCategoryNodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE)) .willReturn(Optional.of(parentCategoryNodeRef)); - final NodeRef categoryNodeRef = prepareCategoryNodeRef(); + final NodeRef categoryNodeRef = createNodeRefWithId(CATEGORY_ID); given(categoryServiceMock.createCategory(parentCategoryNodeRef, CATEGORY_NAME)).willReturn(categoryNodeRef); given(nodesMock.getNode(CATEGORY_ID)).willReturn(prepareCategoryNode()); final ChildAssociationRef parentAssoc = new ChildAssociationRef(null, parentCategoryNodeRef, null, categoryNodeRef); @@ -361,11 +376,9 @@ public class CategoriesImplTest @Test public void testCreateCategory() { - given(authorityServiceMock.hasAdminAuthority()).willReturn(true); final NodeRef parentCategoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PARENT_ID); given(nodesMock.validateNode(PARENT_ID)).willReturn(parentCategoryNodeRef); - given(nodesMock.isSubClass(parentCategoryNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(true); - final NodeRef categoryNodeRef = prepareCategoryNodeRef(); + final NodeRef categoryNodeRef = createNodeRefWithId(CATEGORY_ID); given(categoryServiceMock.createCategory(parentCategoryNodeRef, CATEGORY_NAME)).willReturn(categoryNodeRef); given(nodesMock.getNode(CATEGORY_ID)).willReturn(prepareCategoryNode()); final ChildAssociationRef parentAssoc = new ChildAssociationRef(null, parentCategoryNodeRef, null, categoryNodeRef); @@ -420,7 +433,6 @@ public class CategoriesImplTest @Test public void testCreateCategories_wrongParentNodeType() { - given(authorityServiceMock.hasAdminAuthority()).willReturn(true); final NodeRef parentCategoryNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PARENT_ID); given(nodesMock.validateNode(PARENT_ID)).willReturn(parentCategoryNodeRef); given(nodesMock.isSubClass(parentCategoryNodeRef, ContentModel.TYPE_CATEGORY, false)).willReturn(false); @@ -441,7 +453,6 @@ public class CategoriesImplTest @Test public void testCreateCategories_nonExistingParentNode() { - given(authorityServiceMock.hasAdminAuthority()).willReturn(true); given(nodesMock.validateNode(PARENT_ID)).willThrow(EntityNotFoundException.class); //when @@ -590,10 +601,177 @@ public class CategoriesImplTest then(authorityServiceMock).shouldHaveNoInteractions(); } - private Node prepareCategoryNode() + @Test + public void testUpdateCategoryById() { - final NodeRef parentNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PARENT_ID); - return prepareCategoryNode(CATEGORY_NAME, CATEGORY_ID, parentNodeRef); + final String categoryNewName = "categoryNewName"; + final Category fixedCategory = createCategoryOnlyWithName(categoryNewName); + final QName categoryQName = createCmQNameOf(CATEGORY_NAME); + final NodeRef parentCategoryNodeRef = createNodeRefWithId(PARENT_ID); + final ChildAssociationRef parentAssociation = createAssociationOf(parentCategoryNodeRef, CATEGORY_NODE_REF, categoryQName); + given(nodesMock.getNode(any())).willReturn(prepareCategoryNode(categoryNewName)); + given(nodeServiceMock.getPrimaryParent(any())).willReturn(parentAssociation); + given(nodeServiceMock.moveNode(any(), any(), any(), any())).willReturn(createAssociationOf(parentCategoryNodeRef, CATEGORY_NODE_REF, createCmQNameOf(categoryNewName))); + + // when + final Category actualCategory = objectUnderTest.updateCategoryById(CATEGORY_ID, fixedCategory); + + then(authorityServiceMock).should().hasAdminAuthority(); + then(authorityServiceMock).shouldHaveNoMoreInteractions(); + then(nodesMock).should().validateNode(CATEGORY_ID); + then(nodesMock).should().isSubClass(CATEGORY_NODE_REF, ContentModel.TYPE_CATEGORY, false); + then(nodesMock).should().getNode(CATEGORY_ID); + then(nodesMock).shouldHaveNoMoreInteractions(); + then(nodeServiceMock).should().getParentAssocs(CATEGORY_NODE_REF); + then(nodeServiceMock).should().getChildAssocs(CATEGORY_NODE_REF, RegexQNamePattern.MATCH_ALL, RegexQNamePattern.MATCH_ALL, false); + then(nodeServiceMock).should().setProperty(CATEGORY_NODE_REF, ContentModel.PROP_NAME, categoryNewName); + then(nodeServiceMock).should(times(2)).getPrimaryParent(CATEGORY_NODE_REF); + final QName expectedNewQName = createCmQNameOf(categoryNewName); + then(nodeServiceMock).should().moveNode(CATEGORY_NODE_REF, parentCategoryNodeRef, ContentModel.ASSOC_SUBCATEGORIES, expectedNewQName); + then(nodeServiceMock).should().getParentAssocs(parentCategoryNodeRef); + then(nodeServiceMock).shouldHaveNoMoreInteractions(); + then(categoryServiceMock).shouldHaveNoInteractions(); + final Category expectedCategory = createDefaultCategoryWithName(categoryNewName); + assertThat(actualCategory) + .isNotNull().usingRecursiveComparison() + .isEqualTo(expectedCategory); + } + + @Test + public void testUpdateCategoryById_noPermission() + { + given(authorityServiceMock.hasAdminAuthority()).willReturn(false); + + // when + assertThatExceptionOfType(PermissionDeniedException.class).isThrownBy(() -> objectUnderTest.updateCategoryById(CATEGORY_ID, CATEGORY)); + + then(nodesMock).shouldHaveNoInteractions(); + then(nodeServiceMock).shouldHaveNoInteractions(); + } + + @Test + public void testUpdateCategoryById_categoryNodeNotFound() + { + given(nodesMock.validateNode(any(String.class))).willThrow(EntityNotFoundException.class); + + // when + assertThatExceptionOfType(EntityNotFoundException.class).isThrownBy(() -> objectUnderTest.updateCategoryById(CATEGORY_ID, CATEGORY)); + + then(nodeServiceMock).shouldHaveNoInteractions(); + } + + @Test + public void testUpdateCategoryById_notACategory() + { + given(nodesMock.isSubClass(any(), any(), eq(false))).willReturn(false); + + // when + assertThatExceptionOfType(InvalidArgumentException.class).isThrownBy(() -> objectUnderTest.updateCategoryById(CATEGORY_ID, CATEGORY)) + .withMessageContaining(NOT_A_VALID_CATEGORY); + + then(nodeServiceMock).shouldHaveNoInteractions(); + } + + @Test + public void testUpdateCategoryById_isRootCategory() + { + given(categoryServiceMock.getRootCategoryNodeRef(any())).willReturn(Optional.of(createNodeRefWithId(PATH_ROOT))); + given(nodeServiceMock.getParentAssocs(any())).willReturn(List.of(categoryChildAssociationRefMock)); + given(categoryChildAssociationRefMock.getQName()).willReturn(ContentModel.ASPECT_GEN_CLASSIFIABLE); + + // when + assertThatExceptionOfType(InvalidArgumentException.class).isThrownBy(() -> objectUnderTest.updateCategoryById(PATH_ROOT, CATEGORY)) + .withMessageContaining(NOT_A_VALID_CATEGORY); + + then(categoryServiceMock).should().getRootCategoryNodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE); + then(categoryServiceMock).shouldHaveNoMoreInteractions(); + } + + private List getInvalidCategoryNames() + { + final List invalidNames = new ArrayList<>(); + invalidNames.add(null); + invalidNames.add(""); + return invalidNames; + } + + @Test + public void testUpdateCategoryById_emptyName() + { + for (String invalidName : getInvalidCategoryNames()) + { + final Category categoryWithoutName = createCategoryOnlyWithName(invalidName); + + // when + assertThatExceptionOfType(InvalidArgumentException.class).isThrownBy(() -> objectUnderTest.updateCategoryById(CATEGORY_ID, categoryWithoutName)) + .withMessageContaining(NOT_NULL_OR_EMPTY); + } + } + + @Test + public void testUpdateCategoryById_notMatchingIdField() + { + final String categoryNewName = "categoryNewName"; + final Category categoryWithInvalidId = createCategoryOnlyWithName(categoryNewName); + categoryWithInvalidId.setId("different-" + CATEGORY_ID); + final QName categoryQName = createCmQNameOf(CATEGORY_NAME); + final NodeRef parentCategoryNodeRef = createNodeRefWithId(PARENT_ID); + final ChildAssociationRef parentAssociation = createAssociationOf(parentCategoryNodeRef, CATEGORY_NODE_REF, categoryQName); + given(nodesMock.getNode(any())).willReturn(prepareCategoryNode(categoryNewName)); + given(nodeServiceMock.getPrimaryParent(any())).willReturn(parentAssociation); + given(nodeServiceMock.moveNode(any(), any(), any(), any())).willReturn(createAssociationOf(parentCategoryNodeRef, CATEGORY_NODE_REF, createCmQNameOf(categoryNewName))); + + // when + final Category actualCategory = objectUnderTest.updateCategoryById(CATEGORY_ID, categoryWithInvalidId); + + final Category expectedCategory = createDefaultCategoryWithName(categoryNewName); + assertThat(actualCategory) + .isNotNull().usingRecursiveComparison() + .isEqualTo(expectedCategory); + } + + @Test + public void testUpdateCategoryById_notMatchingParentIdField() + { + final String categoryNewName = "categoryNewName"; + final Category categoryWithInvalidParentId = createCategoryOnlyWithName(categoryNewName); + categoryWithInvalidParentId.setParentId("different-" + PARENT_ID); + final QName categoryQName = createCmQNameOf(CATEGORY_NAME); + final NodeRef parentCategoryNodeRef = createNodeRefWithId(PARENT_ID); + final ChildAssociationRef parentAssociation = createAssociationOf(parentCategoryNodeRef, CATEGORY_NODE_REF, categoryQName); + given(nodesMock.getNode(any())).willReturn(prepareCategoryNode(categoryNewName)); + given(nodeServiceMock.getPrimaryParent(any())).willReturn(parentAssociation); + given(nodeServiceMock.moveNode(any(), any(), any(), any())).willReturn(createAssociationOf(parentCategoryNodeRef, CATEGORY_NODE_REF, createCmQNameOf(categoryNewName))); + + // when + final Category actualCategory = objectUnderTest.updateCategoryById(CATEGORY_ID, categoryWithInvalidParentId); + + final Category expectedCategory = createDefaultCategoryWithName(categoryNewName); + assertThat(actualCategory) + .isNotNull().usingRecursiveComparison() + .isEqualTo(expectedCategory); + } + + @Test + public void testUpdateCategoryById_notMatchingHasChildrenField() + { + final String categoryNewName = "categoryNewName"; + final Category categoryWithInvalidHasChildren = createCategoryOnlyWithName(categoryNewName); + categoryWithInvalidHasChildren.setHasChildren(true); + final QName categoryQName = createCmQNameOf(CATEGORY_NAME); + final NodeRef parentCategoryNodeRef = createNodeRefWithId(PARENT_ID); + final ChildAssociationRef parentAssociation = createAssociationOf(parentCategoryNodeRef, CATEGORY_NODE_REF, categoryQName); + given(nodesMock.getNode(any())).willReturn(prepareCategoryNode(categoryNewName)); + given(nodeServiceMock.getPrimaryParent(any())).willReturn(parentAssociation); + given(nodeServiceMock.moveNode(any(), any(), any(), any())).willReturn(createAssociationOf(parentCategoryNodeRef, CATEGORY_NODE_REF, createCmQNameOf(categoryNewName))); + + // when + final Category actualCategory = objectUnderTest.updateCategoryById(CATEGORY_ID, categoryWithInvalidHasChildren); + + final Category expectedCategory = createDefaultCategoryWithName(categoryNewName); + assertThat(actualCategory) + .isNotNull().usingRecursiveComparison() + .isEqualTo(expectedCategory); } private Node prepareCategoryNode(final String name, final String id, final NodeRef parentNodeRef) @@ -605,9 +783,15 @@ public class CategoriesImplTest return categoryNode; } - private NodeRef prepareCategoryNodeRef() + private Node prepareCategoryNode(final String name) { - return new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, CATEGORY_ID); + final NodeRef parentNodeRef = new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, PARENT_ID); + return prepareCategoryNode(name, CATEGORY_ID, parentNodeRef); + } + + private Node prepareCategoryNode() + { + return prepareCategoryNode(CATEGORY_NAME); } private List prepareCategories() @@ -626,8 +810,7 @@ public class CategoriesImplTest .willReturn(new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, CATEGORY_ID + "-" + i)); given(dummyChildAssocMock.getParentRef()).willReturn(parentCategoryNodeRef); return dummyChildAssocMock; - }) - .collect(Collectors.toList()); + }).collect(Collectors.toList()); } private void prepareCategoryNodeMocks(ChildAssociationRef childAssociationRef) @@ -652,4 +835,34 @@ public class CategoriesImplTest .create(); assertEquals(expectedCategory, category); } + + private static NodeRef createNodeRefWithId(final String id) + { + return new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, id); + } + + private static Category createCategoryOnlyWithName(final String name) + { + return Category.builder().name(name).create(); + } + + private static Category createDefaultCategoryWithName(final String name) + { + return Category.builder() + .id(CATEGORY_ID) + .name(name) + .parentId(PARENT_ID) + .hasChildren(false) + .create(); + } + + private static QName createCmQNameOf(final String name) + { + return QName.createQName(ContentModel.TYPE_CATEGORY.getNamespaceURI(), QName.createValidLocalName(name)); + } + + private static ChildAssociationRef createAssociationOf(final NodeRef parentNode, final NodeRef childNode, final QName childNodeName) + { + return new ChildAssociationRef(ContentModel.ASSOC_SUBCATEGORIES, parentNode, childNodeName, childNode); + } } From 8c21806cf42849c9df00638c2c7198c5cebb02f1 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Fri, 16 Dec 2022 12:10:31 +0000 Subject: [PATCH 23/37] [maven-release-plugin][skip ci] prepare release 20.45 --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index 7ea46aa1b7..99b95a2332 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.45-SNAPSHOT + 20.45 diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index b60e5ec611..88f946054a 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.45-SNAPSHOT + 20.45 diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index e0f6bf31e4..aaf15d245e 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.45-SNAPSHOT + 20.45 diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 4743beb7e7..07a117d8b5 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.45-SNAPSHOT + 20.45 diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 8e85cc0f94..49da0ea082 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.45-SNAPSHOT + 20.45 diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index ce5a6d46bd..21f3216ae3 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.45-SNAPSHOT + 20.45 diff --git a/amps/pom.xml b/amps/pom.xml index a9d1866061..9b525c3755 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45-SNAPSHOT + 20.45 diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index 90d7cf5448..5776db3059 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.45-SNAPSHOT + 20.45 diff --git a/core/pom.xml b/core/pom.xml index 4d48e8b4e3..d2215c9bb2 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45-SNAPSHOT + 20.45 diff --git a/data-model/pom.xml b/data-model/pom.xml index 9ca95416cc..1d816abc8b 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45-SNAPSHOT + 20.45 diff --git a/mmt/pom.xml b/mmt/pom.xml index f075a4c335..3ec15e7a0a 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45-SNAPSHOT + 20.45 diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 51e2ecc6d3..a77f8c8d4b 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.45-SNAPSHOT + 20.45 diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 37c25ae4d7..fd1164fd82 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.45-SNAPSHOT + 20.45 diff --git a/packaging/pom.xml b/packaging/pom.xml index 59ec7e5d0e..e7cb386437 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45-SNAPSHOT + 20.45 diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 9a596006c7..c23a37668f 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.45-SNAPSHOT + 20.45 diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 6eeacfc3e9..d3bc32d65f 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.45-SNAPSHOT + 20.45 diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 6bea3a195a..f124b5f294 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.45-SNAPSHOT + 20.45 diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index 3580670ea2..be76236b5f 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.45-SNAPSHOT + 20.45 diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 149a190861..cc07d0d518 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.45-SNAPSHOT + 20.45 diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index c6510867a2..e9b9304de8 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.45-SNAPSHOT + 20.45 diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 1c8075a60c..e8072e382c 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.45-SNAPSHOT + 20.45 diff --git a/pom.xml b/pom.xml index 9e6845e241..d35c1f0d1a 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.45-SNAPSHOT + 20.45 pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - HEAD + 20.45 diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 0c485a45a4..4766e6629a 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45-SNAPSHOT + 20.45 diff --git a/repository/pom.xml b/repository/pom.xml index 3b22b8a836..89a9a7cd87 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45-SNAPSHOT + 20.45 From ea400226ba2002465c9916f9146a55911b1cb82c Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Fri, 16 Dec 2022 12:10:33 +0000 Subject: [PATCH 24/37] [maven-release-plugin][skip ci] prepare for next development iteration --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index 99b95a2332..e8ee49606f 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.45 + 20.46-SNAPSHOT diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 88f946054a..8316b4e1a8 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.45 + 20.46-SNAPSHOT diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index aaf15d245e..9508725b53 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.45 + 20.46-SNAPSHOT diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 07a117d8b5..cad8e1039d 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.45 + 20.46-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 49da0ea082..4d8a5bff49 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.45 + 20.46-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 21f3216ae3..87d7894549 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.45 + 20.46-SNAPSHOT diff --git a/amps/pom.xml b/amps/pom.xml index 9b525c3755..db0e4a047e 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45 + 20.46-SNAPSHOT diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index 5776db3059..a80516e152 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.45 + 20.46-SNAPSHOT diff --git a/core/pom.xml b/core/pom.xml index d2215c9bb2..cf90f2f8a5 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45 + 20.46-SNAPSHOT diff --git a/data-model/pom.xml b/data-model/pom.xml index 1d816abc8b..b8ee085472 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45 + 20.46-SNAPSHOT diff --git a/mmt/pom.xml b/mmt/pom.xml index 3ec15e7a0a..8ed31c7da7 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45 + 20.46-SNAPSHOT diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index a77f8c8d4b..83218e49ca 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.45 + 20.46-SNAPSHOT diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index fd1164fd82..40d01179ad 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.45 + 20.46-SNAPSHOT diff --git a/packaging/pom.xml b/packaging/pom.xml index e7cb386437..25db219aad 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45 + 20.46-SNAPSHOT diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index c23a37668f..b155ac1501 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.45 + 20.46-SNAPSHOT diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index d3bc32d65f..d732ca2b48 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.45 + 20.46-SNAPSHOT diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index f124b5f294..1df5d02586 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.45 + 20.46-SNAPSHOT diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index be76236b5f..ef8ab3ad2d 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.45 + 20.46-SNAPSHOT diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index cc07d0d518..a750a0d272 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.45 + 20.46-SNAPSHOT diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index e9b9304de8..447aa4ebd7 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.45 + 20.46-SNAPSHOT diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index e8072e382c..ab7c728084 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.45 + 20.46-SNAPSHOT diff --git a/pom.xml b/pom.xml index d35c1f0d1a..c1a0f0a576 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.45 + 20.46-SNAPSHOT pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - 20.45 + HEAD diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 4766e6629a..cea307e479 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45 + 20.46-SNAPSHOT diff --git a/repository/pom.xml b/repository/pom.xml index 89a9a7cd87..2943d6f348 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.45 + 20.46-SNAPSHOT From 12af8f5766ebeab88ddb40863d4abb57e130a198 Mon Sep 17 00:00:00 2001 From: Alfresco CI User Date: Sun, 18 Dec 2022 00:05:58 +0000 Subject: [PATCH 25/37] [force] Force release for 2022-12-18. From c4fe682c816f7455341dedde822933082febbb51 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Sun, 18 Dec 2022 00:13:39 +0000 Subject: [PATCH 26/37] [maven-release-plugin][skip ci] prepare release 20.46 --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index e8ee49606f..f753adab3b 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.46-SNAPSHOT + 20.46 diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 8316b4e1a8..7ed035f4a9 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.46-SNAPSHOT + 20.46 diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 9508725b53..1ef8db8b9b 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.46-SNAPSHOT + 20.46 diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index cad8e1039d..791a1c01ee 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.46-SNAPSHOT + 20.46 diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 4d8a5bff49..9676d6da6a 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.46-SNAPSHOT + 20.46 diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 87d7894549..d2a6fc992f 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.46-SNAPSHOT + 20.46 diff --git a/amps/pom.xml b/amps/pom.xml index db0e4a047e..c983a7d0cd 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46-SNAPSHOT + 20.46 diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index a80516e152..cd14cbb9ca 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.46-SNAPSHOT + 20.46 diff --git a/core/pom.xml b/core/pom.xml index cf90f2f8a5..ef39f95116 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46-SNAPSHOT + 20.46 diff --git a/data-model/pom.xml b/data-model/pom.xml index b8ee085472..bd1739712b 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46-SNAPSHOT + 20.46 diff --git a/mmt/pom.xml b/mmt/pom.xml index 8ed31c7da7..5976feeedb 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46-SNAPSHOT + 20.46 diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 83218e49ca..10a6c782c1 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.46-SNAPSHOT + 20.46 diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 40d01179ad..4b6253d8a1 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.46-SNAPSHOT + 20.46 diff --git a/packaging/pom.xml b/packaging/pom.xml index 25db219aad..adc45c8f19 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46-SNAPSHOT + 20.46 diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index b155ac1501..4d7e34e1fa 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.46-SNAPSHOT + 20.46 diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index d732ca2b48..3ca9730e51 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.46-SNAPSHOT + 20.46 diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 1df5d02586..ac3a9ba7aa 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.46-SNAPSHOT + 20.46 diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index ef8ab3ad2d..8694bd0b21 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.46-SNAPSHOT + 20.46 diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index a750a0d272..af289d9947 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.46-SNAPSHOT + 20.46 diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index 447aa4ebd7..ffcc47d4b4 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.46-SNAPSHOT + 20.46 diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index ab7c728084..81e30c4200 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.46-SNAPSHOT + 20.46 diff --git a/pom.xml b/pom.xml index c1a0f0a576..affed43bed 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.46-SNAPSHOT + 20.46 pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - HEAD + 20.46 diff --git a/remote-api/pom.xml b/remote-api/pom.xml index cea307e479..ef3ddf21aa 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46-SNAPSHOT + 20.46 diff --git a/repository/pom.xml b/repository/pom.xml index 2943d6f348..49cd5905df 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46-SNAPSHOT + 20.46 From c40b862012fa21d70be27c6ab1d3bd47ef0b29e5 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Sun, 18 Dec 2022 00:13:41 +0000 Subject: [PATCH 27/37] [maven-release-plugin][skip ci] prepare for next development iteration --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index f753adab3b..ca653584b0 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.46 + 20.47-SNAPSHOT diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 7ed035f4a9..fe1b7e026e 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.46 + 20.47-SNAPSHOT diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 1ef8db8b9b..0869b081d8 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.46 + 20.47-SNAPSHOT diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 791a1c01ee..33a08c4b86 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.46 + 20.47-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 9676d6da6a..e14faed482 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.46 + 20.47-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index d2a6fc992f..918f66689a 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.46 + 20.47-SNAPSHOT diff --git a/amps/pom.xml b/amps/pom.xml index c983a7d0cd..0947dfaca6 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46 + 20.47-SNAPSHOT diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index cd14cbb9ca..92564b7e49 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.46 + 20.47-SNAPSHOT diff --git a/core/pom.xml b/core/pom.xml index ef39f95116..56fdc6ac93 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46 + 20.47-SNAPSHOT diff --git a/data-model/pom.xml b/data-model/pom.xml index bd1739712b..256fe89dd0 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46 + 20.47-SNAPSHOT diff --git a/mmt/pom.xml b/mmt/pom.xml index 5976feeedb..0fd2786209 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46 + 20.47-SNAPSHOT diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 10a6c782c1..2e14383faf 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.46 + 20.47-SNAPSHOT diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 4b6253d8a1..b2353c7814 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.46 + 20.47-SNAPSHOT diff --git a/packaging/pom.xml b/packaging/pom.xml index adc45c8f19..67387545aa 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46 + 20.47-SNAPSHOT diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 4d7e34e1fa..847d58f720 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.46 + 20.47-SNAPSHOT diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 3ca9730e51..a11ac9958c 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.46 + 20.47-SNAPSHOT diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index ac3a9ba7aa..7d0fac6eea 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.46 + 20.47-SNAPSHOT diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index 8694bd0b21..4c140e9016 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.46 + 20.47-SNAPSHOT diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index af289d9947..0c999648ce 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.46 + 20.47-SNAPSHOT diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index ffcc47d4b4..d530a19709 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.46 + 20.47-SNAPSHOT diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 81e30c4200..261347bdde 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.46 + 20.47-SNAPSHOT diff --git a/pom.xml b/pom.xml index affed43bed..066839c840 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.46 + 20.47-SNAPSHOT pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - 20.46 + HEAD diff --git a/remote-api/pom.xml b/remote-api/pom.xml index ef3ddf21aa..d7688caa1d 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46 + 20.47-SNAPSHOT diff --git a/repository/pom.xml b/repository/pom.xml index 49cd5905df..4ed2c90c8c 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.46 + 20.47-SNAPSHOT From 2a2ae2448e4a45f4f6ea9400bedc78fb3206dada Mon Sep 17 00:00:00 2001 From: Domenico Sibilio Date: Tue, 20 Dec 2022 09:45:10 +0100 Subject: [PATCH 28/37] ACS-4188 Migrate tas tests to Log4j 2.x (#1630) * ACS-4188 Migrate tas tests to Log4j 2.x * ACS-4188 Make main log4j2.properties file more compact * ACS-4188 Remove unnecessary log4j2 test dependencies * ACS-4188 Rename log4j.properties file --- .../rm-automation-community-rest-api/pom.xml | 23 - .../src/main/resources/log4j.properties | 26 - .../src/main/resources/log4j2.properties | 42 ++ .../src/test/resources/log4j.properties | 26 - .../src/test/resources/log4j2.properties | 42 ++ .../src/test/resources/log4j.properties | 26 - .../src/test/resources/log4j2.properties | 42 ++ .../src/test/resources/log4j.properties | 26 - .../src/test/resources/log4j2.properties | 42 ++ .../src/main/resources/log4j.properties | 26 - .../src/main/resources/log4j2.properties | 42 ++ .../src/test/resources/log4j.properties | 26 - .../src/test/resources/log4j2.properties | 42 ++ .../src/test/resources/log4j.properties | 26 - .../src/test/resources/log4j2.properties | 42 ++ .../war/src/main/resources/log4j2.properties | 159 +----- pom.xml | 2 +- .../src/test/resources/log4j.properties | 25 - .../src/test/resources/log4j2.properties | 56 +++ .../extension/custom-log4j.properties.sample | 3 - .../extension/custom-log4j2.properties.sample | 8 + .../src/test/resources/log4j.properties | 266 ---------- .../src/test/resources/log4j2.properties | 469 ++++++++++++++++++ 23 files changed, 829 insertions(+), 658 deletions(-) delete mode 100644 packaging/tests/tas-cmis/src/main/resources/log4j.properties create mode 100644 packaging/tests/tas-cmis/src/main/resources/log4j2.properties delete mode 100644 packaging/tests/tas-cmis/src/test/resources/log4j.properties create mode 100644 packaging/tests/tas-cmis/src/test/resources/log4j2.properties delete mode 100644 packaging/tests/tas-email/src/test/resources/log4j.properties create mode 100644 packaging/tests/tas-email/src/test/resources/log4j2.properties delete mode 100644 packaging/tests/tas-integration/src/test/resources/log4j.properties create mode 100644 packaging/tests/tas-integration/src/test/resources/log4j2.properties delete mode 100644 packaging/tests/tas-restapi/src/main/resources/log4j.properties create mode 100644 packaging/tests/tas-restapi/src/main/resources/log4j2.properties delete mode 100644 packaging/tests/tas-restapi/src/test/resources/log4j.properties create mode 100644 packaging/tests/tas-restapi/src/test/resources/log4j2.properties delete mode 100644 packaging/tests/tas-webdav/src/test/resources/log4j.properties create mode 100644 packaging/tests/tas-webdav/src/test/resources/log4j2.properties delete mode 100644 remote-api/src/test/resources/log4j.properties create mode 100644 remote-api/src/test/resources/log4j2.properties delete mode 100644 repository/src/main/resources/alfresco/extension/custom-log4j.properties.sample create mode 100644 repository/src/main/resources/alfresco/extension/custom-log4j2.properties.sample delete mode 100644 repository/src/test/resources/log4j.properties create mode 100644 repository/src/test/resources/log4j2.properties diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 0869b081d8..69e77be057 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -42,18 +42,6 @@ - - org.apache.logging.log4j - log4j-slf4j2-impl - ${dependency.log4j.version} - test - - - org.apache.logging.log4j - log4j-core - ${dependency.log4j.version} - test - org.alfresco.tas restapi @@ -69,17 +57,6 @@ org.alfresco.tas utility ${dependency.tas-utility.version} - - - - ch.qos.reload4j - reload4j - - - org.slf4j - slf4j-reload4j - - org.projectlombok diff --git a/packaging/tests/tas-cmis/src/main/resources/log4j.properties b/packaging/tests/tas-cmis/src/main/resources/log4j.properties deleted file mode 100644 index 00e9b5a114..0000000000 --- a/packaging/tests/tas-cmis/src/main/resources/log4j.properties +++ /dev/null @@ -1,26 +0,0 @@ -# Root logger option -log4j.rootLogger=INFO, file, stdout - -# Direct log messages to a log file -log4j.appender.file=org.apache.log4j.RollingFileAppender -log4j.appender.file.File=./target/reports/alfresco-tas.log -log4j.appender.file.MaxBackupIndex=10 -log4j.appender.file.layout=org.apache.log4j.PatternLayout -log4j.appender.file.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# Direct log messages to stdout -log4j.appender.stdout=org.apache.log4j.ConsoleAppender -log4j.appender.stdout.Target=System.out -log4j.appender.stdout.layout=org.apache.log4j.PatternLayout -log4j.appender.stdout.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# TestRail particular log file -# Direct log messages to a log file -log4j.appender.testrailLog=org.apache.log4j.RollingFileAppender -log4j.appender.testrailLog.File=./target/reports/alfresco-testrail.log -log4j.appender.testrailLog.MaxBackupIndex=10 -log4j.appender.testrailLog.layout=org.apache.log4j.PatternLayout -log4j.appender.testrailLog.layout.ConversionPattern=%d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -log4j.category.testrail=INFO, testrailLog -log4j.additivity.testrail=false \ No newline at end of file diff --git a/packaging/tests/tas-cmis/src/main/resources/log4j2.properties b/packaging/tests/tas-cmis/src/main/resources/log4j2.properties new file mode 100644 index 0000000000..5e34814028 --- /dev/null +++ b/packaging/tests/tas-cmis/src/main/resources/log4j2.properties @@ -0,0 +1,42 @@ +# Root logger option +rootLogger.level=info +rootLogger.appenderRef.stdout.ref=ConsoleAppender +rootLogger.appenderRef.rolling.ref=RollingAppender + +###### File appender definition ####### +appender.rolling.type=RollingFile +appender.rolling.name=RollingAppender +appender.rolling.fileName=./target/reports/alfresco-tas.log +appender.rolling.filePattern=./target/reports/alfresco-tas.log.%i +appender.rolling.layout.type=PatternLayout +appender.rolling.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.rolling.policies.type = Policies +appender.rolling.policies.size.type=SizeBasedTriggeringPolicy +appender.rolling.policies.size.size=10MB +appender.rolling.strategy.type=DefaultRolloverStrategy +appender.rolling.strategy.max=10 + +###### Console appender definition ####### +appender.console.type=Console +appender.console.name=ConsoleAppender +appender.console.layout.type=PatternLayout +appender.console.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n + +# TestRail particular log file +# Direct log messages to a log file +logger.testrail.name=testrail +logger.testrail.level=info +logger.testrail.additivity=false +logger.testrail.appenderRef.testrail.ref=TestrailAppender + +appender.testrail.name=TestrailAppender +appender.testrail.type=RollingFile +appender.testrail.fileName=./target/reports/alfresco-testrail.log +appender.testrail.filePattern=./target/reports/alfresco-testrail.log.%i +appender.testrail.layout.type=PatternLayout +appender.testrail.layout.pattern=%d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.testrail.policies.type=Policies +appender.testrail.policies.size.type=SizeBasedTriggeringPolicy +appender.testrail.policies.size.size=10MB +appender.testrail.strategy.type=DefaultRolloverStrategy +appender.testrail.strategy.max=10 \ No newline at end of file diff --git a/packaging/tests/tas-cmis/src/test/resources/log4j.properties b/packaging/tests/tas-cmis/src/test/resources/log4j.properties deleted file mode 100644 index 00e9b5a114..0000000000 --- a/packaging/tests/tas-cmis/src/test/resources/log4j.properties +++ /dev/null @@ -1,26 +0,0 @@ -# Root logger option -log4j.rootLogger=INFO, file, stdout - -# Direct log messages to a log file -log4j.appender.file=org.apache.log4j.RollingFileAppender -log4j.appender.file.File=./target/reports/alfresco-tas.log -log4j.appender.file.MaxBackupIndex=10 -log4j.appender.file.layout=org.apache.log4j.PatternLayout -log4j.appender.file.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# Direct log messages to stdout -log4j.appender.stdout=org.apache.log4j.ConsoleAppender -log4j.appender.stdout.Target=System.out -log4j.appender.stdout.layout=org.apache.log4j.PatternLayout -log4j.appender.stdout.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# TestRail particular log file -# Direct log messages to a log file -log4j.appender.testrailLog=org.apache.log4j.RollingFileAppender -log4j.appender.testrailLog.File=./target/reports/alfresco-testrail.log -log4j.appender.testrailLog.MaxBackupIndex=10 -log4j.appender.testrailLog.layout=org.apache.log4j.PatternLayout -log4j.appender.testrailLog.layout.ConversionPattern=%d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -log4j.category.testrail=INFO, testrailLog -log4j.additivity.testrail=false \ No newline at end of file diff --git a/packaging/tests/tas-cmis/src/test/resources/log4j2.properties b/packaging/tests/tas-cmis/src/test/resources/log4j2.properties new file mode 100644 index 0000000000..5e34814028 --- /dev/null +++ b/packaging/tests/tas-cmis/src/test/resources/log4j2.properties @@ -0,0 +1,42 @@ +# Root logger option +rootLogger.level=info +rootLogger.appenderRef.stdout.ref=ConsoleAppender +rootLogger.appenderRef.rolling.ref=RollingAppender + +###### File appender definition ####### +appender.rolling.type=RollingFile +appender.rolling.name=RollingAppender +appender.rolling.fileName=./target/reports/alfresco-tas.log +appender.rolling.filePattern=./target/reports/alfresco-tas.log.%i +appender.rolling.layout.type=PatternLayout +appender.rolling.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.rolling.policies.type = Policies +appender.rolling.policies.size.type=SizeBasedTriggeringPolicy +appender.rolling.policies.size.size=10MB +appender.rolling.strategy.type=DefaultRolloverStrategy +appender.rolling.strategy.max=10 + +###### Console appender definition ####### +appender.console.type=Console +appender.console.name=ConsoleAppender +appender.console.layout.type=PatternLayout +appender.console.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n + +# TestRail particular log file +# Direct log messages to a log file +logger.testrail.name=testrail +logger.testrail.level=info +logger.testrail.additivity=false +logger.testrail.appenderRef.testrail.ref=TestrailAppender + +appender.testrail.name=TestrailAppender +appender.testrail.type=RollingFile +appender.testrail.fileName=./target/reports/alfresco-testrail.log +appender.testrail.filePattern=./target/reports/alfresco-testrail.log.%i +appender.testrail.layout.type=PatternLayout +appender.testrail.layout.pattern=%d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.testrail.policies.type=Policies +appender.testrail.policies.size.type=SizeBasedTriggeringPolicy +appender.testrail.policies.size.size=10MB +appender.testrail.strategy.type=DefaultRolloverStrategy +appender.testrail.strategy.max=10 \ No newline at end of file diff --git a/packaging/tests/tas-email/src/test/resources/log4j.properties b/packaging/tests/tas-email/src/test/resources/log4j.properties deleted file mode 100644 index 00e9b5a114..0000000000 --- a/packaging/tests/tas-email/src/test/resources/log4j.properties +++ /dev/null @@ -1,26 +0,0 @@ -# Root logger option -log4j.rootLogger=INFO, file, stdout - -# Direct log messages to a log file -log4j.appender.file=org.apache.log4j.RollingFileAppender -log4j.appender.file.File=./target/reports/alfresco-tas.log -log4j.appender.file.MaxBackupIndex=10 -log4j.appender.file.layout=org.apache.log4j.PatternLayout -log4j.appender.file.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# Direct log messages to stdout -log4j.appender.stdout=org.apache.log4j.ConsoleAppender -log4j.appender.stdout.Target=System.out -log4j.appender.stdout.layout=org.apache.log4j.PatternLayout -log4j.appender.stdout.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# TestRail particular log file -# Direct log messages to a log file -log4j.appender.testrailLog=org.apache.log4j.RollingFileAppender -log4j.appender.testrailLog.File=./target/reports/alfresco-testrail.log -log4j.appender.testrailLog.MaxBackupIndex=10 -log4j.appender.testrailLog.layout=org.apache.log4j.PatternLayout -log4j.appender.testrailLog.layout.ConversionPattern=%d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -log4j.category.testrail=INFO, testrailLog -log4j.additivity.testrail=false \ No newline at end of file diff --git a/packaging/tests/tas-email/src/test/resources/log4j2.properties b/packaging/tests/tas-email/src/test/resources/log4j2.properties new file mode 100644 index 0000000000..5e34814028 --- /dev/null +++ b/packaging/tests/tas-email/src/test/resources/log4j2.properties @@ -0,0 +1,42 @@ +# Root logger option +rootLogger.level=info +rootLogger.appenderRef.stdout.ref=ConsoleAppender +rootLogger.appenderRef.rolling.ref=RollingAppender + +###### File appender definition ####### +appender.rolling.type=RollingFile +appender.rolling.name=RollingAppender +appender.rolling.fileName=./target/reports/alfresco-tas.log +appender.rolling.filePattern=./target/reports/alfresco-tas.log.%i +appender.rolling.layout.type=PatternLayout +appender.rolling.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.rolling.policies.type = Policies +appender.rolling.policies.size.type=SizeBasedTriggeringPolicy +appender.rolling.policies.size.size=10MB +appender.rolling.strategy.type=DefaultRolloverStrategy +appender.rolling.strategy.max=10 + +###### Console appender definition ####### +appender.console.type=Console +appender.console.name=ConsoleAppender +appender.console.layout.type=PatternLayout +appender.console.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n + +# TestRail particular log file +# Direct log messages to a log file +logger.testrail.name=testrail +logger.testrail.level=info +logger.testrail.additivity=false +logger.testrail.appenderRef.testrail.ref=TestrailAppender + +appender.testrail.name=TestrailAppender +appender.testrail.type=RollingFile +appender.testrail.fileName=./target/reports/alfresco-testrail.log +appender.testrail.filePattern=./target/reports/alfresco-testrail.log.%i +appender.testrail.layout.type=PatternLayout +appender.testrail.layout.pattern=%d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.testrail.policies.type=Policies +appender.testrail.policies.size.type=SizeBasedTriggeringPolicy +appender.testrail.policies.size.size=10MB +appender.testrail.strategy.type=DefaultRolloverStrategy +appender.testrail.strategy.max=10 \ No newline at end of file diff --git a/packaging/tests/tas-integration/src/test/resources/log4j.properties b/packaging/tests/tas-integration/src/test/resources/log4j.properties deleted file mode 100644 index 00e9b5a114..0000000000 --- a/packaging/tests/tas-integration/src/test/resources/log4j.properties +++ /dev/null @@ -1,26 +0,0 @@ -# Root logger option -log4j.rootLogger=INFO, file, stdout - -# Direct log messages to a log file -log4j.appender.file=org.apache.log4j.RollingFileAppender -log4j.appender.file.File=./target/reports/alfresco-tas.log -log4j.appender.file.MaxBackupIndex=10 -log4j.appender.file.layout=org.apache.log4j.PatternLayout -log4j.appender.file.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# Direct log messages to stdout -log4j.appender.stdout=org.apache.log4j.ConsoleAppender -log4j.appender.stdout.Target=System.out -log4j.appender.stdout.layout=org.apache.log4j.PatternLayout -log4j.appender.stdout.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# TestRail particular log file -# Direct log messages to a log file -log4j.appender.testrailLog=org.apache.log4j.RollingFileAppender -log4j.appender.testrailLog.File=./target/reports/alfresco-testrail.log -log4j.appender.testrailLog.MaxBackupIndex=10 -log4j.appender.testrailLog.layout=org.apache.log4j.PatternLayout -log4j.appender.testrailLog.layout.ConversionPattern=%d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -log4j.category.testrail=INFO, testrailLog -log4j.additivity.testrail=false \ No newline at end of file diff --git a/packaging/tests/tas-integration/src/test/resources/log4j2.properties b/packaging/tests/tas-integration/src/test/resources/log4j2.properties new file mode 100644 index 0000000000..5e34814028 --- /dev/null +++ b/packaging/tests/tas-integration/src/test/resources/log4j2.properties @@ -0,0 +1,42 @@ +# Root logger option +rootLogger.level=info +rootLogger.appenderRef.stdout.ref=ConsoleAppender +rootLogger.appenderRef.rolling.ref=RollingAppender + +###### File appender definition ####### +appender.rolling.type=RollingFile +appender.rolling.name=RollingAppender +appender.rolling.fileName=./target/reports/alfresco-tas.log +appender.rolling.filePattern=./target/reports/alfresco-tas.log.%i +appender.rolling.layout.type=PatternLayout +appender.rolling.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.rolling.policies.type = Policies +appender.rolling.policies.size.type=SizeBasedTriggeringPolicy +appender.rolling.policies.size.size=10MB +appender.rolling.strategy.type=DefaultRolloverStrategy +appender.rolling.strategy.max=10 + +###### Console appender definition ####### +appender.console.type=Console +appender.console.name=ConsoleAppender +appender.console.layout.type=PatternLayout +appender.console.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n + +# TestRail particular log file +# Direct log messages to a log file +logger.testrail.name=testrail +logger.testrail.level=info +logger.testrail.additivity=false +logger.testrail.appenderRef.testrail.ref=TestrailAppender + +appender.testrail.name=TestrailAppender +appender.testrail.type=RollingFile +appender.testrail.fileName=./target/reports/alfresco-testrail.log +appender.testrail.filePattern=./target/reports/alfresco-testrail.log.%i +appender.testrail.layout.type=PatternLayout +appender.testrail.layout.pattern=%d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.testrail.policies.type=Policies +appender.testrail.policies.size.type=SizeBasedTriggeringPolicy +appender.testrail.policies.size.size=10MB +appender.testrail.strategy.type=DefaultRolloverStrategy +appender.testrail.strategy.max=10 \ No newline at end of file diff --git a/packaging/tests/tas-restapi/src/main/resources/log4j.properties b/packaging/tests/tas-restapi/src/main/resources/log4j.properties deleted file mode 100644 index 00e9b5a114..0000000000 --- a/packaging/tests/tas-restapi/src/main/resources/log4j.properties +++ /dev/null @@ -1,26 +0,0 @@ -# Root logger option -log4j.rootLogger=INFO, file, stdout - -# Direct log messages to a log file -log4j.appender.file=org.apache.log4j.RollingFileAppender -log4j.appender.file.File=./target/reports/alfresco-tas.log -log4j.appender.file.MaxBackupIndex=10 -log4j.appender.file.layout=org.apache.log4j.PatternLayout -log4j.appender.file.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# Direct log messages to stdout -log4j.appender.stdout=org.apache.log4j.ConsoleAppender -log4j.appender.stdout.Target=System.out -log4j.appender.stdout.layout=org.apache.log4j.PatternLayout -log4j.appender.stdout.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# TestRail particular log file -# Direct log messages to a log file -log4j.appender.testrailLog=org.apache.log4j.RollingFileAppender -log4j.appender.testrailLog.File=./target/reports/alfresco-testrail.log -log4j.appender.testrailLog.MaxBackupIndex=10 -log4j.appender.testrailLog.layout=org.apache.log4j.PatternLayout -log4j.appender.testrailLog.layout.ConversionPattern=%d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -log4j.category.testrail=INFO, testrailLog -log4j.additivity.testrail=false \ No newline at end of file diff --git a/packaging/tests/tas-restapi/src/main/resources/log4j2.properties b/packaging/tests/tas-restapi/src/main/resources/log4j2.properties new file mode 100644 index 0000000000..5e34814028 --- /dev/null +++ b/packaging/tests/tas-restapi/src/main/resources/log4j2.properties @@ -0,0 +1,42 @@ +# Root logger option +rootLogger.level=info +rootLogger.appenderRef.stdout.ref=ConsoleAppender +rootLogger.appenderRef.rolling.ref=RollingAppender + +###### File appender definition ####### +appender.rolling.type=RollingFile +appender.rolling.name=RollingAppender +appender.rolling.fileName=./target/reports/alfresco-tas.log +appender.rolling.filePattern=./target/reports/alfresco-tas.log.%i +appender.rolling.layout.type=PatternLayout +appender.rolling.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.rolling.policies.type = Policies +appender.rolling.policies.size.type=SizeBasedTriggeringPolicy +appender.rolling.policies.size.size=10MB +appender.rolling.strategy.type=DefaultRolloverStrategy +appender.rolling.strategy.max=10 + +###### Console appender definition ####### +appender.console.type=Console +appender.console.name=ConsoleAppender +appender.console.layout.type=PatternLayout +appender.console.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n + +# TestRail particular log file +# Direct log messages to a log file +logger.testrail.name=testrail +logger.testrail.level=info +logger.testrail.additivity=false +logger.testrail.appenderRef.testrail.ref=TestrailAppender + +appender.testrail.name=TestrailAppender +appender.testrail.type=RollingFile +appender.testrail.fileName=./target/reports/alfresco-testrail.log +appender.testrail.filePattern=./target/reports/alfresco-testrail.log.%i +appender.testrail.layout.type=PatternLayout +appender.testrail.layout.pattern=%d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.testrail.policies.type=Policies +appender.testrail.policies.size.type=SizeBasedTriggeringPolicy +appender.testrail.policies.size.size=10MB +appender.testrail.strategy.type=DefaultRolloverStrategy +appender.testrail.strategy.max=10 \ No newline at end of file diff --git a/packaging/tests/tas-restapi/src/test/resources/log4j.properties b/packaging/tests/tas-restapi/src/test/resources/log4j.properties deleted file mode 100644 index 00e9b5a114..0000000000 --- a/packaging/tests/tas-restapi/src/test/resources/log4j.properties +++ /dev/null @@ -1,26 +0,0 @@ -# Root logger option -log4j.rootLogger=INFO, file, stdout - -# Direct log messages to a log file -log4j.appender.file=org.apache.log4j.RollingFileAppender -log4j.appender.file.File=./target/reports/alfresco-tas.log -log4j.appender.file.MaxBackupIndex=10 -log4j.appender.file.layout=org.apache.log4j.PatternLayout -log4j.appender.file.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# Direct log messages to stdout -log4j.appender.stdout=org.apache.log4j.ConsoleAppender -log4j.appender.stdout.Target=System.out -log4j.appender.stdout.layout=org.apache.log4j.PatternLayout -log4j.appender.stdout.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# TestRail particular log file -# Direct log messages to a log file -log4j.appender.testrailLog=org.apache.log4j.RollingFileAppender -log4j.appender.testrailLog.File=./target/reports/alfresco-testrail.log -log4j.appender.testrailLog.MaxBackupIndex=10 -log4j.appender.testrailLog.layout=org.apache.log4j.PatternLayout -log4j.appender.testrailLog.layout.ConversionPattern=%d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -log4j.category.testrail=INFO, testrailLog -log4j.additivity.testrail=false \ No newline at end of file diff --git a/packaging/tests/tas-restapi/src/test/resources/log4j2.properties b/packaging/tests/tas-restapi/src/test/resources/log4j2.properties new file mode 100644 index 0000000000..5e34814028 --- /dev/null +++ b/packaging/tests/tas-restapi/src/test/resources/log4j2.properties @@ -0,0 +1,42 @@ +# Root logger option +rootLogger.level=info +rootLogger.appenderRef.stdout.ref=ConsoleAppender +rootLogger.appenderRef.rolling.ref=RollingAppender + +###### File appender definition ####### +appender.rolling.type=RollingFile +appender.rolling.name=RollingAppender +appender.rolling.fileName=./target/reports/alfresco-tas.log +appender.rolling.filePattern=./target/reports/alfresco-tas.log.%i +appender.rolling.layout.type=PatternLayout +appender.rolling.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.rolling.policies.type = Policies +appender.rolling.policies.size.type=SizeBasedTriggeringPolicy +appender.rolling.policies.size.size=10MB +appender.rolling.strategy.type=DefaultRolloverStrategy +appender.rolling.strategy.max=10 + +###### Console appender definition ####### +appender.console.type=Console +appender.console.name=ConsoleAppender +appender.console.layout.type=PatternLayout +appender.console.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n + +# TestRail particular log file +# Direct log messages to a log file +logger.testrail.name=testrail +logger.testrail.level=info +logger.testrail.additivity=false +logger.testrail.appenderRef.testrail.ref=TestrailAppender + +appender.testrail.name=TestrailAppender +appender.testrail.type=RollingFile +appender.testrail.fileName=./target/reports/alfresco-testrail.log +appender.testrail.filePattern=./target/reports/alfresco-testrail.log.%i +appender.testrail.layout.type=PatternLayout +appender.testrail.layout.pattern=%d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.testrail.policies.type=Policies +appender.testrail.policies.size.type=SizeBasedTriggeringPolicy +appender.testrail.policies.size.size=10MB +appender.testrail.strategy.type=DefaultRolloverStrategy +appender.testrail.strategy.max=10 \ No newline at end of file diff --git a/packaging/tests/tas-webdav/src/test/resources/log4j.properties b/packaging/tests/tas-webdav/src/test/resources/log4j.properties deleted file mode 100644 index 00e9b5a114..0000000000 --- a/packaging/tests/tas-webdav/src/test/resources/log4j.properties +++ /dev/null @@ -1,26 +0,0 @@ -# Root logger option -log4j.rootLogger=INFO, file, stdout - -# Direct log messages to a log file -log4j.appender.file=org.apache.log4j.RollingFileAppender -log4j.appender.file.File=./target/reports/alfresco-tas.log -log4j.appender.file.MaxBackupIndex=10 -log4j.appender.file.layout=org.apache.log4j.PatternLayout -log4j.appender.file.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# Direct log messages to stdout -log4j.appender.stdout=org.apache.log4j.ConsoleAppender -log4j.appender.stdout.Target=System.out -log4j.appender.stdout.layout=org.apache.log4j.PatternLayout -log4j.appender.stdout.layout.ConversionPattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -# TestRail particular log file -# Direct log messages to a log file -log4j.appender.testrailLog=org.apache.log4j.RollingFileAppender -log4j.appender.testrailLog.File=./target/reports/alfresco-testrail.log -log4j.appender.testrailLog.MaxBackupIndex=10 -log4j.appender.testrailLog.layout=org.apache.log4j.PatternLayout -log4j.appender.testrailLog.layout.ConversionPattern=%d{HH:mm:ss} %-5p %c{1}:%L - %m%n - -log4j.category.testrail=INFO, testrailLog -log4j.additivity.testrail=false \ No newline at end of file diff --git a/packaging/tests/tas-webdav/src/test/resources/log4j2.properties b/packaging/tests/tas-webdav/src/test/resources/log4j2.properties new file mode 100644 index 0000000000..5e34814028 --- /dev/null +++ b/packaging/tests/tas-webdav/src/test/resources/log4j2.properties @@ -0,0 +1,42 @@ +# Root logger option +rootLogger.level=info +rootLogger.appenderRef.stdout.ref=ConsoleAppender +rootLogger.appenderRef.rolling.ref=RollingAppender + +###### File appender definition ####### +appender.rolling.type=RollingFile +appender.rolling.name=RollingAppender +appender.rolling.fileName=./target/reports/alfresco-tas.log +appender.rolling.filePattern=./target/reports/alfresco-tas.log.%i +appender.rolling.layout.type=PatternLayout +appender.rolling.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.rolling.policies.type = Policies +appender.rolling.policies.size.type=SizeBasedTriggeringPolicy +appender.rolling.policies.size.size=10MB +appender.rolling.strategy.type=DefaultRolloverStrategy +appender.rolling.strategy.max=10 + +###### Console appender definition ####### +appender.console.type=Console +appender.console.name=ConsoleAppender +appender.console.layout.type=PatternLayout +appender.console.layout.pattern=[%t] %d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n + +# TestRail particular log file +# Direct log messages to a log file +logger.testrail.name=testrail +logger.testrail.level=info +logger.testrail.additivity=false +logger.testrail.appenderRef.testrail.ref=TestrailAppender + +appender.testrail.name=TestrailAppender +appender.testrail.type=RollingFile +appender.testrail.fileName=./target/reports/alfresco-testrail.log +appender.testrail.filePattern=./target/reports/alfresco-testrail.log.%i +appender.testrail.layout.type=PatternLayout +appender.testrail.layout.pattern=%d{HH:mm:ss} %-5p %c{1}:%L - %replace{%m}{[\r\n]+}{}%n +appender.testrail.policies.type=Policies +appender.testrail.policies.size.type=SizeBasedTriggeringPolicy +appender.testrail.policies.size.size=10MB +appender.testrail.strategy.type=DefaultRolloverStrategy +appender.testrail.strategy.max=10 \ No newline at end of file diff --git a/packaging/war/src/main/resources/log4j2.properties b/packaging/war/src/main/resources/log4j2.properties index bc37e2bd7c..39b84a34b7 100644 --- a/packaging/war/src/main/resources/log4j2.properties +++ b/packaging/war/src/main/resources/log4j2.properties @@ -29,7 +29,6 @@ appender.rolling.policies.time.interval = 1 # Log4j addLoggerMBean as long as the logger exists and has been loaded. # Hibernate - logger.hibernate.name=org.hibernate logger.hibernate.level=error @@ -45,42 +44,29 @@ logger.hibernate-type.level=warn logger.hibernate-cfg-SettingsFactory.name=org.hibernate.cfg.SettingsFactory logger.hibernate-cfg-SettingsFactory.level=warn - - # Spring - logger.springframework.name=org.springframework logger.springframework.level=warn # Turn off Spring remoting warnings that should really be info or debug. - logger.springframework-remoting-support.name=org.springframework.remoting.support logger.springframework-remoting-support.level=error logger.springframework-util.name=org.springframework.util logger.springframework-util.level=error - - # Axis/WSS4J - logger.apache-axis.name=org.apache.axis logger.apache-axis.level=info logger.apache-ws.name=org.apache.ws logger.apache-ws.level=info - - # CXF - logger.apache-cxf.name=org.apache.cxf logger.apache-cxf.level=error - - # MyFaces - logger.apache-myfaces-util-DebugUtils.name=org.apache.myfaces.util.DebugUtils logger.apache-myfaces-util-DebugUtils.level=info @@ -93,17 +79,11 @@ logger.apache-myfaces-application-jsp-JspViewHandlerImpl.level=error logger.apache-myfaces-taglib.name=org.apache.myfaces.taglib logger.apache-myfaces-taglib.level=error - - # log prepared statement cache activity ### - logger.hibernate-ps-PreparedStatementCache.name=org.hibernate.ps.PreparedStatementCache logger.hibernate-ps-PreparedStatementCache.level=info - - # Alfresco - logger.alfresco.name=org.alfresco logger.alfresco.level=error @@ -146,8 +126,6 @@ logger.alfresco-repo-security-sync.level=info logger.alfresco-repo-security-person.name=org.alfresco.repo.security.person logger.alfresco-repo-security-person.level=info - - logger.alfresco-sample.name=org.alfresco.sample logger.alfresco-sample.level=info @@ -172,34 +150,25 @@ logger.alfresco-service-descriptor-DescriptorService.level=info #logger.alfresco-web-page.name=org.alfresco.web.page #logger.alfresco-web-page.level=debug - - logger.alfresco-repo-importer-ImporterBootstrap.name=org.alfresco.repo.importer.ImporterBootstrap logger.alfresco-repo-importer-ImporterBootstrap.level=error #logger.alfresco-repo-importer-ImporterBootstrap.name=org.alfresco.repo.importer.ImporterBootstrap #logger.alfresco-repo-importer-ImporterBootstrap.level=info - - logger.alfresco-repo-admin-patch-PatchExecuter.name=org.alfresco.repo.admin.patch.PatchExecuter logger.alfresco-repo-admin-patch-PatchExecuter.level=info logger.alfresco-repo-domain-patch-ibatis-PatchDAOImpl.name=org.alfresco.repo.domain.patch.ibatis.PatchDAOImpl logger.alfresco-repo-domain-patch-ibatis-PatchDAOImpl.level=info - - # Specific patches - logger.alfresco-repo-admin-patch-impl-DeploymentMigrationPatch.name=org.alfresco.repo.admin.patch.impl.DeploymentMigrationPatch logger.alfresco-repo-admin-patch-impl-DeploymentMigrationPatch.level=info logger.alfresco-repo-version-VersionMigrator.name=org.alfresco.repo.version.VersionMigrator logger.alfresco-repo-version-VersionMigrator.level=info - - logger.alfresco-repo-module-ModuleServiceImpl.name=org.alfresco.repo.module.ModuleServiceImpl logger.alfresco-repo-module-ModuleServiceImpl.level=info @@ -239,74 +208,49 @@ logger.alfresco-enterprise-repo-cluster.level=info logger.alfresco-repo-version-Version2ServiceImpl.name=org.alfresco.repo.version.Version2ServiceImpl logger.alfresco-repo-version-Version2ServiceImpl.level=warn - - #logger.alfresco-web-app-DebugPhaseListener.name=org.alfresco.web.app.DebugPhaseListener #logger.alfresco-web-app-DebugPhaseListener.level=debug logger.alfresco-repo-node-db-NodeStringLengthWorker.name=org.alfresco.repo.node.db.NodeStringLengthWorker logger.alfresco-repo-node-db-NodeStringLengthWorker.level=info - - logger.alfresco-repo-workflow.name=org.alfresco.repo.workflow logger.alfresco-repo-workflow.level=info - - # FTP server debugging - logger.alfresco-ftp-protocol.name=org.alfresco.ftp.protocol logger.alfresco-ftp-protocol.level=error #logger.alfresco-ftp-server.name=org.alfresco.ftp.server #logger.alfresco-ftp-server.level=debug - - # WebDAV debugging - #logger.alfresco-webdav-protocol.name=org.alfresco.webdav.protocol #logger.alfresco-webdav-protocol.level=debug logger.alfresco-webdav-protocol.name=org.alfresco.webdav.protocol logger.alfresco-webdav-protocol.level=info - - # Kerberos servlet filters - #logger.alfresco-web-app-servlet-KerberosAuthenticationFilter.name=org.alfresco.web.app.servlet.KerberosAuthenticationFilter #logger.alfresco-web-app-servlet-KerberosAuthenticationFilter.level=debug #logger.alfresco-repo-webdav-auth-KerberosAuthenticationFilter.name=org.alfresco.repo.webdav.auth.KerberosAuthenticationFilter #logger.alfresco-repo-webdav-auth-KerberosAuthenticationFilter.level=debug - - # File servers - logger.alfresco-fileserver.name=org.alfresco.fileserver logger.alfresco-fileserver.level=warn - - # Repo filesystem debug logging - #logger.alfresco-filesys-repo-ContentDiskDriver.name=org.alfresco.filesys.repo.ContentDiskDriver #logger.alfresco-filesys-repo-ContentDiskDriver.level=debug - - # Integrity message threshold - if 'failOnViolation' is off, then WARNINGS are generated - logger.alfresco-repo-node-integrity.name=org.alfresco.repo.node.integrity logger.alfresco-repo-node-integrity.level=error - - # Authentication - logger.alfresco-filesys-auth-ftp.name=org.alfresco.filesys.auth.ftp logger.alfresco-filesys-auth-ftp.level=warn @@ -323,22 +267,16 @@ logger.alfresco-web-app-servlet.name=org.alfresco.web.app.servlet logger.alfresco-web-app-servlet.level=warn # Used also for brute force attack detection - logger.alfresco-repo-security-authentication.name=org.alfresco.repo.security.authentication logger.alfresco-repo-security-authentication.level=warn - - # Indexer debugging - logger.alfresco-repo-search-Indexer.name=org.alfresco.repo.search.Indexer logger.alfresco-repo-search-Indexer.level=error #logger.alfresco-repo-search-Indexer.name=org.alfresco.repo.search.Indexer #logger.alfresco-repo-search-Indexer.level=debug - - logger.alfresco-repo-search-impl-lucene-index.name=org.alfresco.repo.search.impl.lucene.index logger.alfresco-repo-search-impl-lucene-index.level=error @@ -348,97 +286,62 @@ logger.alfresco-repo-search-impl-lucene-fts-FullTextSearchIndexerImpl.level=warn #logger.alfresco-repo-search-impl-lucene-index.name=org.alfresco.repo.search.impl.lucene.index #logger.alfresco-repo-search-impl-lucene-index.level=debug - - # Audit debugging - #logger.alfresco-repo-audit.name=org.alfresco.repo.audit #logger.alfresco-repo-audit.level=debug #logger.alfresco-repo-audit-model.name=org.alfresco.repo.audit.model #logger.alfresco-repo-audit-model.level=debug - # Property sheet and modelling debugging - # change to error to hide the warnings about missing properties and associations - logger.missingProperties.name=alfresco.missingProperties logger.missingProperties.level=warn - - # Dictionary/Model debugging - logger.alfresco-repo-dictionary.name=org.alfresco.repo.dictionary logger.alfresco-repo-dictionary.level=warn logger.alfresco-repo-dictionary-types-period.name=org.alfresco.repo.dictionary.types.period logger.alfresco-repo-dictionary-types-period.level=warn - - # Virtualization Server Registry - logger.alfresco-mbeans-VirtServerRegistry.name=org.alfresco.mbeans.VirtServerRegistry logger.alfresco-mbeans-VirtServerRegistry.level=error - - # Spring context runtime property setter - logger.alfresco-util-RuntimeSystemPropertiesSetter.name=org.alfresco.util.RuntimeSystemPropertiesSetter logger.alfresco-util-RuntimeSystemPropertiesSetter.level=info - - # Debugging options for clustering - logger.alfresco-repo-content-ReplicatingContentStore.name=org.alfresco.repo.content.ReplicatingContentStore logger.alfresco-repo-content-ReplicatingContentStore.level=error logger.alfresco-repo-content-replication.name=org.alfresco.repo.content.replication logger.alfresco-repo-content-replication.level=error - - #logger.alfresco-repo-deploy-DeploymentServiceImpl.name=org.alfresco.repo.deploy.DeploymentServiceImpl #logger.alfresco-repo-deploy-DeploymentServiceImpl.level=debug - - # Activity service - logger.alfresco-repo-activities.name=org.alfresco.repo.activities logger.alfresco-repo-activities.level=warn - - # User usage tracking - logger.alfresco-repo-usage.name=org.alfresco.repo.usage logger.alfresco-repo-usage.level=info - - # Sharepoint - logger.alfresco-module-vti.name=org.alfresco.module.vti logger.alfresco-module-vti.level=info - - # Forms Engine - logger.alfresco-web-config-forms.name=org.alfresco.web.config.forms logger.alfresco-web-config-forms.level=info logger.alfresco-web-scripts-forms.name=org.alfresco.web.scripts.forms logger.alfresco-web-scripts-forms.level=info - - # CMIS - logger.alfresco-opencmis.name=org.alfresco.opencmis logger.alfresco-opencmis.level=error @@ -460,35 +363,20 @@ logger.apache-chemistry-opencmis-server-impl-browser-CmisBrowserBindingServlet.l logger.apache-chemistry-opencmis-server-impl-atompub-CmisAtomPubServlet.name=org.apache.chemistry.opencmis.server.impl.atompub.CmisAtomPubServlet logger.apache-chemistry-opencmis-server-impl-atompub-CmisAtomPubServlet.level=off - - # IMAP - logger.alfresco-repo-imap.name=org.alfresco.repo.imap logger.alfresco-repo-imap.level=info - - # JBPM - # Note: non-fatal errors (eg. logged during job execution) should be handled by Alfresco's retrying transaction handler - logger.jbpm-graph-def-GraphElement.name=org.jbpm.graph.def.GraphElement logger.jbpm-graph-def-GraphElement.level=fatal - - #logger.alfresco-repo-googledocs.name=org.alfresco.repo.googledocs #logger.alfresco-repo-googledocs.level=debug - - ###### Scripting ####### - - - # Web Framework - logger.springframework-extensions-webscripts.name=org.springframework.extensions.webscripts logger.springframework-extensions-webscripts.level=info @@ -498,10 +386,7 @@ logger.springframework-extensions-webscripts-ScriptLogger.level=warn logger.springframework-extensions-webscripts-ScriptDebugger.name=org.springframework.extensions.webscripts.ScriptDebugger logger.springframework-extensions-webscripts-ScriptDebugger.level=off - - # Repository - logger.alfresco-repo-web-scripts.name=org.alfresco.repo.web.scripts logger.alfresco-repo-web-scripts.level=warn @@ -520,8 +405,6 @@ logger.alfresco-repo-jscript-ScriptLogger.level=warn logger.alfresco-repo-cmis-rest-CMISTest.name=org.alfresco.repo.cmis.rest.CMISTest logger.alfresco-repo-cmis-rest-CMISTest.level=info - - logger.alfresco-repo-domain-schema-script-ScriptBundleExecutorImpl.name=org.alfresco.repo.domain.schema.script.ScriptBundleExecutorImpl logger.alfresco-repo-domain-schema-script-ScriptBundleExecutorImpl.level=off @@ -531,103 +414,63 @@ logger.alfresco-repo-domain-schema-script-ScriptExecutorImpl.level=info logger.alfresco-repo-domain-schema-script-DeleteNotExistsExecutor.name=org.alfresco.repo.domain.schema.script.DeleteNotExistsExecutor logger.alfresco-repo-domain-schema-script-DeleteNotExistsExecutor.level=off - - logger.alfresco-repo-search-impl-solr-facet-SolrFacetServiceImpl.name=org.alfresco.repo.search.impl.solr.facet.SolrFacetServiceImpl logger.alfresco-repo-search-impl-solr-facet-SolrFacetServiceImpl.level=info - - # Bulk Filesystem Import Tool - logger.alfresco-repo-bulkimport.name=org.alfresco.repo.bulkimport logger.alfresco-repo-bulkimport.level=warn - - # Freemarker - # Note the freemarker.runtime logger is used to log non-fatal errors that are handled by Alfresco's retrying transaction handler - logger.runtime.name=freemarker.runtime logger.runtime.level= - - # Metadata extraction - logger.alfresco-repo-content-metadata-AbstractMappingMetadataExtracter.name=org.alfresco.repo.content.metadata.AbstractMappingMetadataExtracter logger.alfresco-repo-content-metadata-AbstractMappingMetadataExtracter.level=warn - - # no index support - logger.alfresco-repo-search-impl-noindex-NoIndexIndexer.name=org.alfresco.repo.search.impl.noindex.NoIndexIndexer logger.alfresco-repo-search-impl-noindex-NoIndexIndexer.level=fatal logger.alfresco-repo-search-impl-noindex-NoIndexSearchService.name=org.alfresco.repo.search.impl.noindex.NoIndexSearchService logger.alfresco-repo-search-impl-noindex-NoIndexSearchService.level=fatal - - # lucene index warnings - logger.alfresco-repo-search-impl-lucene-index-IndexInfo.name=org.alfresco.repo.search.impl.lucene.index.IndexInfo logger.alfresco-repo-search-impl-lucene-index-IndexInfo.level=warn - - # Warn about RMI socket bind retries. - logger.alfresco-util-remote-server-socket-HostConfigurableSocketFactory.name=org.alfresco.util.remote.server.socket.HostConfigurableSocketFactory logger.alfresco-util-remote-server-socket-HostConfigurableSocketFactory.level=warn - - logger.alfresco-repo-usage-RepoUsageMonitor.name=org.alfresco.repo.usage.RepoUsageMonitor logger.alfresco-repo-usage-RepoUsageMonitor.level=info - - # Authorization - logger.alfresco-enterprise-repo-authorization-AuthorizationService.name=org.alfresco.enterprise.repo.authorization.AuthorizationService logger.alfresco-enterprise-repo-authorization-AuthorizationService.level=info logger.alfresco-enterprise-repo-authorization-AuthorizationsConsistencyMonitor.name=org.alfresco.enterprise.repo.authorization.AuthorizationsConsistencyMonitor logger.alfresco-enterprise-repo-authorization-AuthorizationsConsistencyMonitor.level=warn - - # HeartBeat - logger.alfresco-heartbeat.name=org.alfresco.heartbeat logger.alfresco-heartbeat.level=info - - # Transformations - #logger.alfresco-repo-content-transform-TransformerDebug.name=org.alfresco.repo.content.transform.TransformerDebug #logger.alfresco-repo-content-transform-TransformerDebug.level=debug - - logger.alfresco-repo-content-transform.name=org.alfresco.repo.content.transform logger.alfresco-repo-content-transform.level=info - - # Repository probes - logger.alfresco-rest-api-probes-ProbeEntityResource.name=org.alfresco.rest.api.probes.ProbeEntityResource logger.alfresco-rest-api-probes-ProbeEntityResource.level=info - - # ActiveMQ logger.apache-activemq-transport-failover.name=org.apache.activemq.transport.failover -logger.apache-activemq-transport-failover.level=warn - +logger.apache-activemq-transport-failover.level=warn \ No newline at end of file diff --git a/pom.xml b/pom.xml index 066839c840..27f5c81e77 100644 --- a/pom.xml +++ b/pom.xml @@ -120,7 +120,7 @@ 8.0.30 8 2.7.4 - 3.0.56 + 3.0.57 5.2.0 1.11 1.7 diff --git a/remote-api/src/test/resources/log4j.properties b/remote-api/src/test/resources/log4j.properties deleted file mode 100644 index e8b1b86823..0000000000 --- a/remote-api/src/test/resources/log4j.properties +++ /dev/null @@ -1,25 +0,0 @@ -log4j.rootLogger=error, Console - -log4j.appender.Console=org.apache.log4j.ConsoleAppender -log4j.appender.Console.layout=org.apache.log4j.PatternLayout -log4j.appender.Console.layout.ConversionPattern=%d{ISO8601} %x %-5p [%c{3}] [%t] %m%n - -log4j.logger.org.alfresco=WARN -log4j.logger.org.alfresco.rest.api=DEBUG -log4j.logger.org.eclipse.jetty.util.log=INFO - -# Renditions and Transforms -log4j.logger.org.alfresco.repo.content.transform.TransformerDebug=debug - -log4j.logger.org.alfresco.repo.rendition2=debug -#log4j.logger.org.alfresco.repo.rendition2.LocalTransformClient=debug -#log4j.logger.org.alfresco.repo.rendition.RenditionServiceImpl=debug -#log4j.logger.org.alfresco.enterprise.repo.rendition2.RemoteTransformClient=debug -log4j.logger.org.alfresco.repo.thumbnail.ThumbnailServiceImplTest=DEBUG -log4j.logger.org.alfresco.repo.rendition2.RenditionService2Impl=DEBUG - -#log4j.logger.org.alfresco.repo.content.transform.LocalTransformServiceRegistry=debug -#log4j.logger.org.alfresco.enterprise.repo.rendition2.RemoteTransformServiceRegistry=debug -#log4j.logger.org.alfresco.repo.rendition2.RenditionDefinitionRegistry2Impl=debug -#log4j.logger.org.alfresco.repo.content.MimetypeMap=debug -#log4j.logger.org.alfresco.repo.content.transform.LocalTransform=trace diff --git a/remote-api/src/test/resources/log4j2.properties b/remote-api/src/test/resources/log4j2.properties new file mode 100644 index 0000000000..fc0d8a01c2 --- /dev/null +++ b/remote-api/src/test/resources/log4j2.properties @@ -0,0 +1,56 @@ +# Set root logger level to error +rootLogger.level=error +rootLogger.appenderRef.stdout.ref=ConsoleAppender + +###### Console appender definition ####### +# All outputs currently set to be a ConsoleAppender. +appender.console.type=Console +appender.console.name=ConsoleAppender +appender.console.layout.type=PatternLayout +appender.console.layout.pattern=%d{ISO8601} %x %-5p [%c{3}] [%t] %replace{%m}{[\r\n]+}{}%n + +logger.alfresco.name=org.alfresco +logger.alfresco.level=warn + +logger.alfresco-rest-api.name=org.alfresco.rest.api +logger.alfresco-rest-api.level=debug + +logger.eclipse-jetty-util-log.name=org.eclipse.jetty.util.log +logger.eclipse-jetty-util-log.level=info + +# Renditions and Transforms +logger.alfresco-repo-content-transform-TransformerDebug.name=org.alfresco.repo.content.transform.TransformerDebug +logger.alfresco-repo-content-transform-TransformerDebug.level=debug + +logger.alfresco-repo-rendition2.name=org.alfresco.repo.rendition2 +logger.alfresco-repo-rendition2.level=debug + +#logger.alfresco-repo-rendition2-LocalTransformClient.name=org.alfresco.repo.rendition2.LocalTransformClient +#logger.alfresco-repo-rendition2-LocalTransformClient.level=debug + +#logger.alfresco-repo-rendition-RenditionServiceImpl.name=org.alfresco.repo.rendition.RenditionServiceImpl +#logger.alfresco-repo-rendition-RenditionServiceImpl.level=debug + +#logger.alfresco-enterprise-repo-rendition2-RemoteTransformClient.name=org.alfresco.enterprise.repo.rendition2.RemoteTransformClient +#logger.alfresco-enterprise-repo-rendition2-RemoteTransformClient.level=debug + +logger.alfresco-repo-thumbnail-ThumbnailServiceImplTest.name=org.alfresco.repo.thumbnail.ThumbnailServiceImplTest +logger.alfresco-repo-thumbnail-ThumbnailServiceImplTest.level=debug + +logger.alfresco-repo-rendition2-RenditionService2Impl.name=org.alfresco.repo.rendition2.RenditionService2Impl +logger.alfresco-repo-rendition2-RenditionService2Impl.level=debug + +#logger.alfresco-repo-content-transform-LocalTransformServiceRegistry.name=org.alfresco.repo.content.transform.LocalTransformServiceRegistry +#logger.alfresco-repo-content-transform-LocalTransformServiceRegistry.level=debug + +#logger.alfresco-enterprise-repo-rendition2-RemoteTransformServiceRegistry.name=org.alfresco.enterprise.repo.rendition2.RemoteTransformServiceRegistry +#logger.alfresco-enterprise-repo-rendition2-RemoteTransformServiceRegistry.level=debug + +#logger.alfresco-repo-rendition2-RenditionDefinitionRegistry2Impl.name=org.alfresco.repo.rendition2.RenditionDefinitionRegistry2Impl +#logger.alfresco-repo-rendition2-RenditionDefinitionRegistry2Impl.level=debug + +#logger.alfresco-repo-content-MimetypeMap.name=org.alfresco.repo.content.MimetypeMap +#logger.alfresco-repo-content-MimetypeMap.level=debug + +#logger.alfresco-repo-content-transform-LocalTransform.name=org.alfresco.repo.content.transform.LocalTransform +#logger.alfresco-repo-content-transform-LocalTransform.level=trace \ No newline at end of file diff --git a/repository/src/main/resources/alfresco/extension/custom-log4j.properties.sample b/repository/src/main/resources/alfresco/extension/custom-log4j.properties.sample deleted file mode 100644 index 7746d6f5dd..0000000000 --- a/repository/src/main/resources/alfresco/extension/custom-log4j.properties.sample +++ /dev/null @@ -1,3 +0,0 @@ -log4j.logger.org.alfresco.repo.content.transform.TransformerDebug=debug -log4j.logger.org.alfresco.util.exec.RuntimeExecBootstrapBean=debug -log4j.logger.org.alfresco.util.exec.RuntimeExec=debug \ No newline at end of file diff --git a/repository/src/main/resources/alfresco/extension/custom-log4j2.properties.sample b/repository/src/main/resources/alfresco/extension/custom-log4j2.properties.sample new file mode 100644 index 0000000000..5e36cae2cd --- /dev/null +++ b/repository/src/main/resources/alfresco/extension/custom-log4j2.properties.sample @@ -0,0 +1,8 @@ +logger.alfresco-repo-content-transform-TransformerDebug.name=org.alfresco.repo.content.transform.TransformerDebug +logger.alfresco-repo-content-transform-TransformerDebug.level=debug + +logger.alfresco-util-exec-RuntimeExecBootstrapBean.name=org.alfresco.util.exec.RuntimeExecBootstrapBean +logger.alfresco-util-exec-RuntimeExecBootstrapBean.level=debug + +logger.alfresco-util-exec-RuntimeExec.name=org.alfresco.util.exec.RuntimeExec +logger.alfresco-util-exec-RuntimeExec.level=debug \ No newline at end of file diff --git a/repository/src/test/resources/log4j.properties b/repository/src/test/resources/log4j.properties deleted file mode 100644 index 332062a9fa..0000000000 --- a/repository/src/test/resources/log4j.properties +++ /dev/null @@ -1,266 +0,0 @@ -#TAKEN FROM ALFRESCO_CORE PROJECT -# Set root logger level to error -log4j.rootLogger=error, Console, File - -###### Console appender definition ####### - -# All outputs currently set to be a ConsoleAppender. -log4j.appender.Console=org.apache.log4j.ConsoleAppender -log4j.appender.Console.layout=org.apache.log4j.PatternLayout - -# use log4j NDC to replace %x with tenant domain / username -log4j.appender.Console.layout.ConversionPattern=%d{ISO8601} %x %-5p [%c{3}] [%t] %m%n -#log4j.appender.Console.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n - -###### File appender definition ####### -log4j.appender.File=org.apache.log4j.DailyRollingFileAppender -log4j.appender.File.File=alfresco.log -log4j.appender.File.Append=true -log4j.appender.File.DatePattern='.'yyyy-MM-dd -log4j.appender.File.layout=org.apache.log4j.PatternLayout -log4j.appender.File.layout.ConversionPattern=%d{yyyy-MM-dd} %d{ABSOLUTE} %-5p [%c] [%t] %m%n - -###### Hibernate specific appender definition ####### -#log4j.appender.file=org.apache.log4j.FileAppender -#log4j.appender.file.File=hibernate.log -#log4j.appender.file.layout=org.apache.log4j.PatternLayout -#log4j.appender.file.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n - -###### Log level overrides ####### - -# Commented-in loggers will be exposed as JMX MBeans (refer to org.alfresco.repo.admin.Log4JHierarchyInit) -# Hence, generally useful loggers should be listed with at least ERROR level to allow simple runtime -# control of the level via a suitable JMX Console. Also, any other loggers can be added transiently via -# Log4j addLoggerMBean as long as the logger exists and has been loaded. - -# Hibernate -log4j.logger.org.hibernate=error -log4j.logger.org.hibernate.util.JDBCExceptionReporter=fatal -log4j.logger.org.hibernate.event.def.AbstractFlushingEventListener=fatal -log4j.logger.org.hibernate.type=warn -log4j.logger.org.hibernate.cfg.SettingsFactory=warn - -# Spring -log4j.logger.org.springframework=warn -# Turn off Spring remoting warnings that should really be info or debug. -log4j.logger.org.springframework.remoting.support=error -log4j.logger.org.springframework.util=error - -# Axis/WSS4J -log4j.logger.org.apache.axis=info -log4j.logger.org.apache.ws=info - -# CXF -log4j.logger.org.apache.cxf=error - -# MyFaces -log4j.logger.org.apache.myfaces.util.DebugUtils=info -log4j.logger.org.apache.myfaces.el.VariableResolverImpl=error -log4j.logger.org.apache.myfaces.application.jsp.JspViewHandlerImpl=error -log4j.logger.org.apache.myfaces.taglib=error - -# log prepared statement cache activity ### -log4j.logger.org.hibernate.ps.PreparedStatementCache=info - -# Alfresco -log4j.logger.org.alfresco=error -log4j.logger.org.alfresco.repo.admin=info -log4j.logger.org.alfresco.repo.cache.TransactionalCache=warn -log4j.logger.org.alfresco.repo.model.filefolder=warn -log4j.logger.org.alfresco.repo.tenant=info -log4j.logger.org.alfresco.config=warn -log4j.logger.org.alfresco.config.JndiObjectFactoryBean=warn -log4j.logger.org.alfresco.config.JBossEnabledWebApplicationContext=warn -log4j.logger.org.alfresco.repo.management.subsystems=warn -log4j.logger.org.alfresco.repo.management.subsystems.ChildApplicationContextFactory=info -log4j.logger.org.alfresco.repo.management.subsystems.ChildApplicationContextFactory$ChildApplicationContext=warn -log4j.logger.org.alfresco.repo.security.sync=info -log4j.logger.org.alfresco.repo.security.person=info - -log4j.logger.org.alfresco.sample=info -log4j.logger.org.alfresco.web=info -#log4j.logger.org.alfresco.web.app.AlfrescoNavigationHandler=debug -#log4j.logger.org.alfresco.web.ui.repo.component.UIActions=debug -#log4j.logger.org.alfresco.web.ui.repo.tag.PageTag=debug -#log4j.logger.org.alfresco.web.bean.clipboard=debug -log4j.logger.org.alfresco.service.descriptor.DescriptorService=info -#log4j.logger.org.alfresco.web.page=debug - -log4j.logger.org.alfresco.repo.importer.ImporterBootstrap=error -#log4j.logger.org.alfresco.repo.importer.ImporterBootstrap=info - -log4j.logger.org.alfresco.repo.admin.patch.PatchExecuter=info -log4j.logger.org.alfresco.repo.domain.patch.ibatis.PatchDAOImpl=info - -# Specific patches -log4j.logger.org.alfresco.repo.admin.patch.impl.DeploymentMigrationPatch=info -log4j.logger.org.alfresco.repo.version.VersionMigrator=info - -log4j.logger.org.alfresco.repo.module.ModuleServiceImpl=info -log4j.logger.org.alfresco.repo.domain.schema.SchemaBootstrap=info -log4j.logger.org.alfresco.repo.admin.ConfigurationChecker=info -log4j.logger.org.alfresco.repo.node.index.AbstractReindexComponent=warn -log4j.logger.org.alfresco.repo.node.index.IndexTransactionTracker=warn -log4j.logger.org.alfresco.repo.node.index.FullIndexRecoveryComponent=info -log4j.logger.org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl=warn -log4j.logger.org.alfresco.repo.domain.hibernate.DirtySessionMethodInterceptor=warn -log4j.logger.org.alfresco.repo.transaction.RetryingTransactionHelper=debug -log4j.logger.org.alfresco.util.transaction.SpringAwareUserTransaction.trace=warn -log4j.logger.org.alfresco.util.AbstractTriggerBean=warn -log4j.logger.org.alfresco.enterprise.repo.cluster=info -log4j.logger.org.alfresco.repo.version.Version2ServiceImpl=warn -#log4j.logger.org.alfresco.repo.thumbnail=debug - -#log4j.logger.org.alfresco.web.app.DebugPhaseListener=debug - -log4j.logger.org.alfresco.repo.workflow=info - -# FTP server debugging -log4j.logger.org.alfresco.ftp.protocol=error -#log4j.logger.org.alfresco.ftp.server=debug - -# WebDAV debugging -#log4j.logger.org.alfresco.webdav.protocol=debug -log4j.logger.org.alfresco.webdav.protocol=info - -# Kerberos servlet filters -#log4j.logger.org.alfresco.web.app.servlet.KerberosAuthenticationFilter=debug -#log4j.logger.org.alfresco.repo.webdav.auth.KerberosAuthenticationFilter=debug - -# File servers -log4j.logger.org.alfresco.fileserver=warn - -# Repo filesystem debug logging -#log4j.logger.org.alfresco.filesys.repo.ContentDiskDriver=debug - -# Integrity message threshold - if 'failOnViolation' is off, then WARNINGS are generated -log4j.logger.org.alfresco.repo.node.integrity=ERROR - -# Indexer debugging -log4j.logger.org.alfresco.repo.search.Indexer=error -#log4j.logger.org.alfresco.repo.search.Indexer=debug - -log4j.logger.org.alfresco.repo.search.impl.lucene.index=error -log4j.logger.org.alfresco.repo.search.impl.lucene.fts.FullTextSearchIndexerImpl=warn -#log4j.logger.org.alfresco.repo.search.impl.lucene.index=DEBUG - -# Audit debugging -# log4j.logger.org.alfresco.repo.audit=DEBUG -# log4j.logger.org.alfresco.repo.audit.model=DEBUG - -# Property sheet and modelling debugging -# change to error to hide the warnings about missing properties and associations -log4j.logger.alfresco.missingProperties=warn - -# Dictionary/Model debugging -log4j.logger.org.alfresco.repo.dictionary=warn -log4j.logger.org.alfresco.repo.dictionary.types.period=warn - -# Virtualization Server Registry -log4j.logger.org.alfresco.mbeans.VirtServerRegistry=error - -# Spring context runtime property setter -log4j.logger.org.alfresco.util.RuntimeSystemPropertiesSetter=info - -# Debugging options for clustering -log4j.logger.org.alfresco.repo.content.ReplicatingContentStore=error -log4j.logger.org.alfresco.repo.content.replication=error - -#log4j.logger.org.alfresco.repo.deploy.DeploymentServiceImpl=debug - -# Activity service -log4j.logger.org.alfresco.repo.activities=warn - -# User usage tracking -log4j.logger.org.alfresco.repo.usage=info - -# Sharepoint -log4j.logger.org.alfresco.module.vti=info - -# Forms Engine -log4j.logger.org.alfresco.web.config.forms=info -log4j.logger.org.alfresco.web.scripts.forms=info - -# CMIS -log4j.logger.org.alfresco.opencmis=error -log4j.logger.org.alfresco.opencmis.AlfrescoCmisServiceInterceptor=error -log4j.logger.org.alfresco.cmis=error -log4j.logger.org.alfresco.cmis.dictionary=warn -log4j.logger.org.apache.chemistry.opencmis=info -log4j.logger.org.apache.chemistry.opencmis.server.impl.browser.CmisBrowserBindingServlet=OFF -log4j.logger.org.apache.chemistry.opencmis.server.impl.atompub.CmisAtomPubServlet=OFF - -# IMAP -log4j.logger.org.alfresco.repo.imap=info - -#log4j.logger.org.alfresco.repo.googledocs=debug - -###### Scripting ####### - -# Web Framework -log4j.logger.org.springframework.extensions.webscripts=info -log4j.logger.org.springframework.extensions.webscripts.ScriptLogger=warn -log4j.logger.org.springframework.extensions.webscripts.ScriptDebugger=off - -# Repository -log4j.logger.org.alfresco.repo.web.scripts=warn -log4j.logger.org.alfresco.repo.web.scripts.BaseWebScriptTest=info -log4j.logger.org.alfresco.repo.web.scripts.AlfrescoRhinoScriptDebugger=off -log4j.logger.org.alfresco.repo.jscript=error -log4j.logger.org.alfresco.repo.jscript.ScriptLogger=warn -log4j.logger.org.alfresco.repo.cmis.rest.CMISTest=info -log4j.logger.org.alfresco.repo.domain.schema.script.ScriptBundleExecutorImpl=off -log4j.logger.org.alfresco.repo.domain.schema.script.ScriptExecutorImpl=info -log4j.logger.org.alfresco.repo.domain.schema.script.DeleteNotExistsExecutor=off - -log4j.logger.org.alfresco.repo.search.impl.solr.facet.SolrFacetServiceImpl=info - -# Bulk Filesystem Import Tool -log4j.logger.org.alfresco.repo.bulkimport=warn - -# Freemarker -# Note the freemarker.runtime logger is used to log non-fatal errors that are handled by Alfresco's retrying transaction handler -log4j.logger.freemarker.runtime= - -# Metadata extraction -log4j.logger.org.alfresco.repo.content.metadata.AbstractMappingMetadataExtracter=warn - -# no index support -log4j.logger.org.alfresco.repo.search.impl.noindex.NoIndexIndexer=fatal -log4j.logger.org.alfresco.repo.search.impl.noindex.NoIndexSearchService=fatal - -# lucene index warnings -log4j.logger.org.alfresco.repo.search.impl.lucene.index.IndexInfo=warn - -# Warn about RMI socket bind retries. -log4j.logger.org.alfresco.util.remote.server.socket.HostConfigurableSocketFactory=warn - -log4j.logger.org.alfresco.repo.usage.RepoUsageMonitor=info - -log4j.logger.org.alfresco.repo.site.SiteServiceImpl=DEBUG -#log4j.logger.org.alfresco.repo.action.ActionServiceImpl=DEBUG -log4j.logger.org.alfresco.repo.security.person.PersonServiceImpl=DEBUG - -# identity service authentication -log4j.logger.org.alfresco.repo.security.authentication.identityservice=debug -log4j.logger.org.keycloak=debug - -# Renditions and Transforms -log4j.logger.org.alfresco.repo.content.transform.TransformerDebug=debug - -log4j.logger.org.alfresco.repo.rendition2=debug -#log4j.logger.org.alfresco.repo.rendition2.LocalTransformClient=debug -#log4j.logger.org.alfresco.repo.rendition.RenditionServiceImpl=debug -#log4j.logger.org.alfresco.enterprise.repo.rendition2.RemoteTransformClient=debug -log4j.logger.org.alfresco.repo.thumbnail.ThumbnailServiceImplTest=DEBUG -log4j.logger.org.alfresco.repo.rendition2.RenditionService2Impl=DEBUG - -#log4j.logger.org.alfresco.repo.content.transform.LocalTransformServiceRegistry=debug -#log4j.logger.org.alfresco.enterprise.repo.rendition2.RemoteTransformServiceRegistry=debug -#log4j.logger.org.alfresco.repo.rendition2.RenditionDefinitionRegistry2Impl=debug -#log4j.logger.org.alfresco.repo.content.MimetypeMap=debug -#log4j.logger.org.alfresco.repo.content.transform.LocalTransform=trace - -#log4j.logger.org.alfresco.repo.rawevents=debug - -#log4j.logger.org.alfresco.repo.event2=trace \ No newline at end of file diff --git a/repository/src/test/resources/log4j2.properties b/repository/src/test/resources/log4j2.properties new file mode 100644 index 0000000000..6b873ba637 --- /dev/null +++ b/repository/src/test/resources/log4j2.properties @@ -0,0 +1,469 @@ +# Set root logger level to error +rootLogger.level=error +rootLogger.appenderRef.stdout.ref=ConsoleAppender +rootLogger.appenderRef.rolling.ref=RollingAppender + +###### Console appender definition ####### +# All outputs currently set to be a ConsoleAppender. +appender.console.type=Console +appender.console.name=ConsoleAppender +appender.console.layout.type=PatternLayout +# use log4j NDC to replace %x with tenant domain / username +appender.console.layout.pattern=%d{ISO8601} %x %-5p [%c{3}] [%t] %replace{%m}{[\r\n]+}{}%n + +###### File appender definition ####### +appender.rolling.type=RollingFile +appender.rolling.name=RollingAppender +appender.rolling.fileName=alfresco.log +appender.rolling.filePattern=alfresco.log.%d{yyyy-MM-dd} +appender.rolling.layout.type=PatternLayout +appender.rolling.layout.pattern=%d{yyyy-MM-dd} %d{ABSOLUTE} %-5p [%c] [%t] %replace{%m}{[\r\n]+}{}%n +appender.rolling.policies.type = Policies +appender.rolling.policies.time.type = TimeBasedTriggeringPolicy +appender.rolling.policies.time.interval = 1 + +###### Log level overrides ####### +# Commented-in loggers will be exposed as JMX MBeans (refer to org.alfresco.repo.admin.Log4JHierarchyInit) +# Hence, generally useful loggers should be listed with at least ERROR level to allow simple runtime +# control of the level via a suitable JMX Console. Also, any other loggers can be added transiently via +# Log4j addLoggerMBean as long as the logger exists and has been loaded. + +# Hibernate +logger.hibernate.name=org.hibernate +logger.hibernate.level=error + +logger.hibernate-util-JDBCExceptionReporter.name=org.hibernate.util.JDBCExceptionReporter +logger.hibernate-util-JDBCExceptionReporter.level=fatal + +logger.hibernate-event-def-AbstractFlushingEventListener.name=org.hibernate.event.def.AbstractFlushingEventListener +logger.hibernate-event-def-AbstractFlushingEventListener.level=fatal + +logger.hibernate-type.name=org.hibernate.type +logger.hibernate-type.level=warn + +logger.hibernate-cfg-SettingsFactory.name=org.hibernate.cfg.SettingsFactory +logger.hibernate-cfg-SettingsFactory.level=warn + +# Spring +logger.springframework.name=org.springframework +logger.springframework.level=warn + +# Turn off Spring remoting warnings that should really be info or debug. +logger.springframework-remoting-support.name=org.springframework.remoting.support +logger.springframework-remoting-support.level=error + +logger.springframework-util.name=org.springframework.util +logger.springframework-util.level=error + +# Axis/WSS4J +logger.apache-axis.name=org.apache.axis +logger.apache-axis.level=info + +logger.apache-ws.name=org.apache.ws +logger.apache-ws.level=info + +# CXF +logger.apache-cxf.name=org.apache.cxf +logger.apache-cxf.level=error + +# MyFaces +logger.apache-myfaces-util-DebugUtils.name=org.apache.myfaces.util.DebugUtils +logger.apache-myfaces-util-DebugUtils.level=info + +logger.apache-myfaces-el-VariableResolverImpl.name=org.apache.myfaces.el.VariableResolverImpl +logger.apache-myfaces-el-VariableResolverImpl.level=error + +logger.apache-myfaces-application-jsp-JspViewHandlerImpl.name=org.apache.myfaces.application.jsp.JspViewHandlerImpl +logger.apache-myfaces-application-jsp-JspViewHandlerImpl.level=error + +logger.apache-myfaces-taglib.name=org.apache.myfaces.taglib +logger.apache-myfaces-taglib.level=error + +# log prepared statement cache activity ### +logger.hibernate-ps-PreparedStatementCache.name=org.hibernate.ps.PreparedStatementCache +logger.hibernate-ps-PreparedStatementCache.level=info + +# Alfresco +logger.alfresco.name=org.alfresco +logger.alfresco.level=error + +logger.alfresco-repo-admin.name=org.alfresco.repo.admin +logger.alfresco-repo-admin.level=info + +logger.alfresco-repo-transaction.name=org.alfresco.repo.transaction +logger.alfresco-repo-transaction.level=warn + +logger.alfresco-repo-cache-TransactionalCache.name=org.alfresco.repo.cache.TransactionalCache +logger.alfresco-repo-cache-TransactionalCache.level=warn + +logger.alfresco-repo-model-filefolder.name=org.alfresco.repo.model.filefolder +logger.alfresco-repo-model-filefolder.level=warn + +logger.alfresco-repo-tenant.name=org.alfresco.repo.tenant +logger.alfresco-repo-tenant.level=info + +logger.alfresco-config.name=org.alfresco.config +logger.alfresco-config.level=warn + +logger.alfresco-config-JndiObjectFactoryBean.name=org.alfresco.config.JndiObjectFactoryBean +logger.alfresco-config-JndiObjectFactoryBean.level=warn + +logger.alfresco-config-JBossEnabledWebApplicationContext.name=org.alfresco.config.JBossEnabledWebApplicationContext +logger.alfresco-config-JBossEnabledWebApplicationContext.level=warn + +logger.alfresco-repo-management-subsystems.name=org.alfresco.repo.management.subsystems +logger.alfresco-repo-management-subsystems.level=warn + +logger.alfresco-repo-management-subsystems-ChildApplicationContextFactory.name=org.alfresco.repo.management.subsystems.ChildApplicationContextFactory +logger.alfresco-repo-management-subsystems-ChildApplicationContextFactory.level=info + +logger.alfresco-repo-management-subsystems-ChildApplicationContextFactory$ChildApplicationContext.name=org.alfresco.repo.management.subsystems.ChildApplicationContextFactory$ChildApplicationContext +logger.alfresco-repo-management-subsystems-ChildApplicationContextFactory$ChildApplicationContext.level=warn + +logger.alfresco-repo-security-sync.name=org.alfresco.repo.security.sync +logger.alfresco-repo-security-sync.level=info + +logger.alfresco-repo-security-person.name=org.alfresco.repo.security.person +logger.alfresco-repo-security-person.level=info + +logger.alfresco-sample.name=org.alfresco.sample +logger.alfresco-sample.level=info + +logger.alfresco-web.name=org.alfresco.web +logger.alfresco-web.level=info + +#logger.alfresco-web-app-AlfrescoNavigationHandler.name=org.alfresco.web.app.AlfrescoNavigationHandler +#logger.alfresco-web-app-AlfrescoNavigationHandler.level=debug + +#logger.alfresco-web-ui-repo-component-UIActions.name=org.alfresco.web.ui.repo.component.UIActions +#logger.alfresco-web-ui-repo-component-UIActions.level=debug + +#logger.alfresco-web-ui-repo-tag-PageTag.name=org.alfresco.web.ui.repo.tag.PageTag +#logger.alfresco-web-ui-repo-tag-PageTag.level=debug + +#logger.alfresco-web-bean-clipboard.name=org.alfresco.web.bean.clipboard +#logger.alfresco-web-bean-clipboard.level=debug + +logger.alfresco-service-descriptor-DescriptorService.name=org.alfresco.service.descriptor.DescriptorService +logger.alfresco-service-descriptor-DescriptorService.level=info + +#logger.alfresco-web-page.name=org.alfresco.web.page +#logger.alfresco-web-page.level=debug + +logger.alfresco-repo-importer-ImporterBootstrap.name=org.alfresco.repo.importer.ImporterBootstrap +logger.alfresco-repo-importer-ImporterBootstrap.level=error + +#logger.alfresco-repo-importer-ImporterBootstrap.name=org.alfresco.repo.importer.ImporterBootstrap +#logger.alfresco-repo-importer-ImporterBootstrap.level=info + +logger.alfresco-repo-admin-patch-PatchExecuter.name=org.alfresco.repo.admin.patch.PatchExecuter +logger.alfresco-repo-admin-patch-PatchExecuter.level=info + +logger.alfresco-repo-domain-patch-ibatis-PatchDAOImpl.name=org.alfresco.repo.domain.patch.ibatis.PatchDAOImpl +logger.alfresco-repo-domain-patch-ibatis-PatchDAOImpl.level=info + +# Specific patches +logger.alfresco-repo-admin-patch-impl-DeploymentMigrationPatch.name=org.alfresco.repo.admin.patch.impl.DeploymentMigrationPatch +logger.alfresco-repo-admin-patch-impl-DeploymentMigrationPatch.level=info + +logger.alfresco-repo-version-VersionMigrator.name=org.alfresco.repo.version.VersionMigrator +logger.alfresco-repo-version-VersionMigrator.level=info + +logger.alfresco-repo-module-ModuleServiceImpl.name=org.alfresco.repo.module.ModuleServiceImpl +logger.alfresco-repo-module-ModuleServiceImpl.level=info + +logger.alfresco-repo-domain-schema-SchemaBootstrap.name=org.alfresco.repo.domain.schema.SchemaBootstrap +logger.alfresco-repo-domain-schema-SchemaBootstrap.level=info + +logger.alfresco-repo-admin-ConfigurationChecker.name=org.alfresco.repo.admin.ConfigurationChecker +logger.alfresco-repo-admin-ConfigurationChecker.level=info + +logger.alfresco-repo-node-index-AbstractReindexComponent.name=org.alfresco.repo.node.index.AbstractReindexComponent +logger.alfresco-repo-node-index-AbstractReindexComponent.level=warn + +logger.alfresco-repo-node-index-IndexTransactionTracker.name=org.alfresco.repo.node.index.IndexTransactionTracker +logger.alfresco-repo-node-index-IndexTransactionTracker.level=warn + +logger.alfresco-repo-node-index-FullIndexRecoveryComponent.name=org.alfresco.repo.node.index.FullIndexRecoveryComponent +logger.alfresco-repo-node-index-FullIndexRecoveryComponent.level=info + +#logger.alfresco-repo-node-db-hibernate-HibernateNodeDaoServiceImpl.name=org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl +#logger.alfresco-repo-node-db-hibernate-HibernateNodeDaoServiceImpl.level=warn + +logger.alfresco-repo-domain-hibernate-DirtySessionMethodInterceptor.name=org.alfresco.repo.domain.hibernate.DirtySessionMethodInterceptor +logger.alfresco-repo-domain-hibernate-DirtySessionMethodInterceptor.level=warn + +logger.alfresco-repo-transaction-RetryingTransactionHelper.name=org.alfresco.repo.transaction.RetryingTransactionHelper +logger.alfresco-repo-transaction-RetryingTransactionHelper.level=warn + +logger.alfresco-util-transaction-SpringAwareUserTransaction-trace.name=org.alfresco.util.transaction.SpringAwareUserTransaction.trace +logger.alfresco-util-transaction-SpringAwareUserTransaction-trace.level=warn + +logger.alfresco-util-AbstractTriggerBean.name=org.alfresco.util.AbstractTriggerBean +logger.alfresco-util-AbstractTriggerBean.level=warn + +logger.alfresco-enterprise-repo-cluster.name=org.alfresco.enterprise.repo.cluster +logger.alfresco-enterprise-repo-cluster.level=info + +logger.alfresco-repo-version-Version2ServiceImpl.name=org.alfresco.repo.version.Version2ServiceImpl +logger.alfresco-repo-version-Version2ServiceImpl.level=warn + +#logger.alfresco-web-app-DebugPhaseListener.name=org.alfresco.web.app.DebugPhaseListener +#logger.alfresco-web-app-DebugPhaseListener.level=debug + +logger.alfresco-repo-node-db-NodeStringLengthWorker.name=org.alfresco.repo.node.db.NodeStringLengthWorker +logger.alfresco-repo-node-db-NodeStringLengthWorker.level=info + +logger.alfresco-repo-workflow.name=org.alfresco.repo.workflow +logger.alfresco-repo-workflow.level=info + +# FTP server debugging +logger.alfresco-ftp-protocol.name=org.alfresco.ftp.protocol +logger.alfresco-ftp-protocol.level=error + +#logger.alfresco-ftp-server.name=org.alfresco.ftp.server +#logger.alfresco-ftp-server.level=debug + +# WebDAV debugging +#logger.alfresco-webdav-protocol.name=org.alfresco.webdav.protocol +#logger.alfresco-webdav-protocol.level=debug + +logger.alfresco-webdav-protocol.name=org.alfresco.webdav.protocol +logger.alfresco-webdav-protocol.level=info + +# Kerberos servlet filters +#logger.alfresco-web-app-servlet-KerberosAuthenticationFilter.name=org.alfresco.web.app.servlet.KerberosAuthenticationFilter +#logger.alfresco-web-app-servlet-KerberosAuthenticationFilter.level=debug + +#logger.alfresco-repo-webdav-auth-KerberosAuthenticationFilter.name=org.alfresco.repo.webdav.auth.KerberosAuthenticationFilter +#logger.alfresco-repo-webdav-auth-KerberosAuthenticationFilter.level=debug + +# File servers +logger.alfresco-fileserver.name=org.alfresco.fileserver +logger.alfresco-fileserver.level=warn + +# Repo filesystem debug logging +#logger.alfresco-filesys-repo-ContentDiskDriver.name=org.alfresco.filesys.repo.ContentDiskDriver +#logger.alfresco-filesys-repo-ContentDiskDriver.level=debug + +# Integrity message threshold - if 'failOnViolation' is off, then WARNINGS are generated +logger.alfresco-repo-node-integrity.name=org.alfresco.repo.node.integrity +logger.alfresco-repo-node-integrity.level=error + +# Authentication +logger.alfresco-filesys-auth-ftp.name=org.alfresco.filesys.auth.ftp +logger.alfresco-filesys-auth-ftp.level=warn + +logger.alfresco-ftp-protocol-auth.name=org.alfresco.ftp.protocol.auth +logger.alfresco-ftp-protocol-auth.level=warn + +logger.alfresco-repo-webdav-auth.name=org.alfresco.repo.webdav.auth +logger.alfresco-repo-webdav-auth.level=warn + +logger.alfresco-repo-web-auth.name=org.alfresco.repo.web.auth +logger.alfresco-repo-web-auth.level=warn + +logger.alfresco-web-app-servlet.name=org.alfresco.web.app.servlet +logger.alfresco-web-app-servlet.level=warn + +# Used also for brute force attack detection +logger.alfresco-repo-security-authentication.name=org.alfresco.repo.security.authentication +logger.alfresco-repo-security-authentication.level=warn + +# Indexer debugging +logger.alfresco-repo-search-Indexer.name=org.alfresco.repo.search.Indexer +logger.alfresco-repo-search-Indexer.level=error + +#logger.alfresco-repo-search-Indexer.name=org.alfresco.repo.search.Indexer +#logger.alfresco-repo-search-Indexer.level=debug + +logger.alfresco-repo-search-impl-lucene-index.name=org.alfresco.repo.search.impl.lucene.index +logger.alfresco-repo-search-impl-lucene-index.level=error + +logger.alfresco-repo-search-impl-lucene-fts-FullTextSearchIndexerImpl.name=org.alfresco.repo.search.impl.lucene.fts.FullTextSearchIndexerImpl +logger.alfresco-repo-search-impl-lucene-fts-FullTextSearchIndexerImpl.level=warn + +#logger.alfresco-repo-search-impl-lucene-index.name=org.alfresco.repo.search.impl.lucene.index +#logger.alfresco-repo-search-impl-lucene-index.level=debug + +# Audit debugging +#logger.alfresco-repo-audit.name=org.alfresco.repo.audit +#logger.alfresco-repo-audit.level=debug +#logger.alfresco-repo-audit-model.name=org.alfresco.repo.audit.model +#logger.alfresco-repo-audit-model.level=debug + +# Property sheet and modelling debugging +# change to error to hide the warnings about missing properties and associations +logger.missingProperties.name=alfresco.missingProperties +logger.missingProperties.level=warn + +# Dictionary/Model debugging +logger.alfresco-repo-dictionary.name=org.alfresco.repo.dictionary +logger.alfresco-repo-dictionary.level=warn + +logger.alfresco-repo-dictionary-types-period.name=org.alfresco.repo.dictionary.types.period +logger.alfresco-repo-dictionary-types-period.level=warn + +# Virtualization Server Registry +logger.alfresco-mbeans-VirtServerRegistry.name=org.alfresco.mbeans.VirtServerRegistry +logger.alfresco-mbeans-VirtServerRegistry.level=error + +# Spring context runtime property setter +logger.alfresco-util-RuntimeSystemPropertiesSetter.name=org.alfresco.util.RuntimeSystemPropertiesSetter +logger.alfresco-util-RuntimeSystemPropertiesSetter.level=info + +# Debugging options for clustering +logger.alfresco-repo-content-ReplicatingContentStore.name=org.alfresco.repo.content.ReplicatingContentStore +logger.alfresco-repo-content-ReplicatingContentStore.level=error + +logger.alfresco-repo-content-replication.name=org.alfresco.repo.content.replication +logger.alfresco-repo-content-replication.level=error + +#logger.alfresco-repo-deploy-DeploymentServiceImpl.name=org.alfresco.repo.deploy.DeploymentServiceImpl +#logger.alfresco-repo-deploy-DeploymentServiceImpl.level=debug + +# Activity service +logger.alfresco-repo-activities.name=org.alfresco.repo.activities +logger.alfresco-repo-activities.level=warn + +# User usage tracking +logger.alfresco-repo-usage.name=org.alfresco.repo.usage +logger.alfresco-repo-usage.level=info + +# Sharepoint +logger.alfresco-module-vti.name=org.alfresco.module.vti +logger.alfresco-module-vti.level=info + +# Forms Engine +logger.alfresco-web-config-forms.name=org.alfresco.web.config.forms +logger.alfresco-web-config-forms.level=info + +logger.alfresco-web-scripts-forms.name=org.alfresco.web.scripts.forms +logger.alfresco-web-scripts-forms.level=info + +# CMIS +logger.alfresco-opencmis.name=org.alfresco.opencmis +logger.alfresco-opencmis.level=error + +logger.alfresco-opencmis-AlfrescoCmisServiceInterceptor.name=org.alfresco.opencmis.AlfrescoCmisServiceInterceptor +logger.alfresco-opencmis-AlfrescoCmisServiceInterceptor.level=error + +logger.alfresco-cmis.name=org.alfresco.cmis +logger.alfresco-cmis.level=error + +logger.alfresco-cmis-dictionary.name=org.alfresco.cmis.dictionary +logger.alfresco-cmis-dictionary.level=warn + +logger.apache-chemistry-opencmis.name=org.apache.chemistry.opencmis +logger.apache-chemistry-opencmis.level=info + +logger.apache-chemistry-opencmis-server-impl-browser-CmisBrowserBindingServlet.name=org.apache.chemistry.opencmis.server.impl.browser.CmisBrowserBindingServlet +logger.apache-chemistry-opencmis-server-impl-browser-CmisBrowserBindingServlet.level=off + +logger.apache-chemistry-opencmis-server-impl-atompub-CmisAtomPubServlet.name=org.apache.chemistry.opencmis.server.impl.atompub.CmisAtomPubServlet +logger.apache-chemistry-opencmis-server-impl-atompub-CmisAtomPubServlet.level=off + +# IMAP +logger.alfresco-repo-imap.name=org.alfresco.repo.imap +logger.alfresco-repo-imap.level=info + +# JBPM +# Note: non-fatal errors (eg. logged during job execution) should be handled by Alfresco's retrying transaction handler +logger.jbpm-graph-def-GraphElement.name=org.jbpm.graph.def.GraphElement +logger.jbpm-graph-def-GraphElement.level=fatal + +#logger.alfresco-repo-googledocs.name=org.alfresco.repo.googledocs +#logger.alfresco-repo-googledocs.level=debug + +###### Scripting ####### +# Web Framework +logger.springframework-extensions-webscripts.name=org.springframework.extensions.webscripts +logger.springframework-extensions-webscripts.level=info + +logger.springframework-extensions-webscripts-ScriptLogger.name=org.springframework.extensions.webscripts.ScriptLogger +logger.springframework-extensions-webscripts-ScriptLogger.level=warn + +logger.springframework-extensions-webscripts-ScriptDebugger.name=org.springframework.extensions.webscripts.ScriptDebugger +logger.springframework-extensions-webscripts-ScriptDebugger.level=off + +# Repository +logger.alfresco-repo-web-scripts.name=org.alfresco.repo.web.scripts +logger.alfresco-repo-web-scripts.level=warn + +logger.alfresco-repo-web-scripts-BaseWebScriptTest.name=org.alfresco.repo.web.scripts.BaseWebScriptTest +logger.alfresco-repo-web-scripts-BaseWebScriptTest.level=info + +logger.alfresco-repo-web-scripts-AlfrescoRhinoScriptDebugger.name=org.alfresco.repo.web.scripts.AlfrescoRhinoScriptDebugger +logger.alfresco-repo-web-scripts-AlfrescoRhinoScriptDebugger.level=off + +logger.alfresco-repo-jscript.name=org.alfresco.repo.jscript +logger.alfresco-repo-jscript.level=error + +logger.alfresco-repo-jscript-ScriptLogger.name=org.alfresco.repo.jscript.ScriptLogger +logger.alfresco-repo-jscript-ScriptLogger.level=warn + +logger.alfresco-repo-cmis-rest-CMISTest.name=org.alfresco.repo.cmis.rest.CMISTest +logger.alfresco-repo-cmis-rest-CMISTest.level=info + +logger.alfresco-repo-domain-schema-script-ScriptBundleExecutorImpl.name=org.alfresco.repo.domain.schema.script.ScriptBundleExecutorImpl +logger.alfresco-repo-domain-schema-script-ScriptBundleExecutorImpl.level=off + +logger.alfresco-repo-domain-schema-script-ScriptExecutorImpl.name=org.alfresco.repo.domain.schema.script.ScriptExecutorImpl +logger.alfresco-repo-domain-schema-script-ScriptExecutorImpl.level=info + +logger.alfresco-repo-domain-schema-script-DeleteNotExistsExecutor.name=org.alfresco.repo.domain.schema.script.DeleteNotExistsExecutor +logger.alfresco-repo-domain-schema-script-DeleteNotExistsExecutor.level=off + +logger.alfresco-repo-search-impl-solr-facet-SolrFacetServiceImpl.name=org.alfresco.repo.search.impl.solr.facet.SolrFacetServiceImpl +logger.alfresco-repo-search-impl-solr-facet-SolrFacetServiceImpl.level=info + +# Bulk Filesystem Import Tool +logger.alfresco-repo-bulkimport.name=org.alfresco.repo.bulkimport +logger.alfresco-repo-bulkimport.level=warn + +# Freemarker +# Note the freemarker.runtime logger is used to log non-fatal errors that are handled by Alfresco's retrying transaction handler +logger.runtime.name=freemarker.runtime +logger.runtime.level= + +# Metadata extraction +logger.alfresco-repo-content-metadata-AbstractMappingMetadataExtracter.name=org.alfresco.repo.content.metadata.AbstractMappingMetadataExtracter +logger.alfresco-repo-content-metadata-AbstractMappingMetadataExtracter.level=warn + +# no index support +logger.alfresco-repo-search-impl-noindex-NoIndexIndexer.name=org.alfresco.repo.search.impl.noindex.NoIndexIndexer +logger.alfresco-repo-search-impl-noindex-NoIndexIndexer.level=fatal + +logger.alfresco-repo-search-impl-noindex-NoIndexSearchService.name=org.alfresco.repo.search.impl.noindex.NoIndexSearchService +logger.alfresco-repo-search-impl-noindex-NoIndexSearchService.level=fatal + +# lucene index warnings +logger.alfresco-repo-search-impl-lucene-index-IndexInfo.name=org.alfresco.repo.search.impl.lucene.index.IndexInfo +logger.alfresco-repo-search-impl-lucene-index-IndexInfo.level=warn + +# Warn about RMI socket bind retries. +logger.alfresco-util-remote-server-socket-HostConfigurableSocketFactory.name=org.alfresco.util.remote.server.socket.HostConfigurableSocketFactory +logger.alfresco-util-remote-server-socket-HostConfigurableSocketFactory.level=warn + +logger.alfresco-repo-usage-RepoUsageMonitor.name=org.alfresco.repo.usage.RepoUsageMonitor +logger.alfresco-repo-usage-RepoUsageMonitor.level=info + +# identity service authentication +logger.alfresco-repo-security-authentication-identityservice.name=org.alfresco.repo.security.authentication.identityservice +logger.alfresco-repo-security-authentication-identityservice.level=debug + +logger.keycloak.name=org.keycloak +logger.keycloak.level=debug + +# Renditions and Transforms +logger.alfresco-repo-content-transform-TransformerDebug.name=org.alfresco.repo.content.transform.TransformerDebug +logger.alfresco-repo-content-transform-TransformerDebug.level=debug + +logger.alfresco-repo-rendition2.name=org.alfresco.repo.rendition2 +logger.alfresco-repo-rendition2.level=debug + +logger.alfresco-repo-thumbnail-ThumbnailServiceImplTest.name=org.alfresco.repo.thumbnail.ThumbnailServiceImplTest +logger.alfresco-repo-thumbnail-ThumbnailServiceImplTest.level=debug + +logger.alfresco-repo-rendition2-RenditionService2Impl.name=org.alfresco.repo.rendition2.RenditionService2Impl +logger.alfresco-repo-rendition2-RenditionService2Impl.level=debug \ No newline at end of file From 7e660572d6585fca21441ddecd9b38b2245948b0 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Tue, 20 Dec 2022 09:25:27 +0000 Subject: [PATCH 29/37] [maven-release-plugin][skip ci] prepare release 20.47 --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index ca653584b0..5cec421bbf 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.47-SNAPSHOT + 20.47 diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index fe1b7e026e..2afd548ffa 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.47-SNAPSHOT + 20.47 diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 69e77be057..5d2f0dcfe1 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.47-SNAPSHOT + 20.47 diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index 33a08c4b86..b8f234ed58 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.47-SNAPSHOT + 20.47 diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index e14faed482..62a04fdb34 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.47-SNAPSHOT + 20.47 diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 918f66689a..7a88bf5d5b 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.47-SNAPSHOT + 20.47 diff --git a/amps/pom.xml b/amps/pom.xml index 0947dfaca6..1e410ce925 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47-SNAPSHOT + 20.47 diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index 92564b7e49..bc12e8be75 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.47-SNAPSHOT + 20.47 diff --git a/core/pom.xml b/core/pom.xml index 56fdc6ac93..3f84b5a327 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47-SNAPSHOT + 20.47 diff --git a/data-model/pom.xml b/data-model/pom.xml index 256fe89dd0..56f2dd8a46 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47-SNAPSHOT + 20.47 diff --git a/mmt/pom.xml b/mmt/pom.xml index 0fd2786209..ef94ea4b1a 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47-SNAPSHOT + 20.47 diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index 2e14383faf..a07565803f 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.47-SNAPSHOT + 20.47 diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index b2353c7814..6c8ad25195 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.47-SNAPSHOT + 20.47 diff --git a/packaging/pom.xml b/packaging/pom.xml index 67387545aa..dbb3e68fb7 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47-SNAPSHOT + 20.47 diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 847d58f720..6ba7fee7a8 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.47-SNAPSHOT + 20.47 diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index a11ac9958c..63c1a3ef85 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.47-SNAPSHOT + 20.47 diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 7d0fac6eea..917c65fa49 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.47-SNAPSHOT + 20.47 diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index 4c140e9016..d9910e825d 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.47-SNAPSHOT + 20.47 diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 0c999648ce..52752a0a5f 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.47-SNAPSHOT + 20.47 diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index d530a19709..a435487a07 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.47-SNAPSHOT + 20.47 diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index 261347bdde..b1a55eea46 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.47-SNAPSHOT + 20.47 diff --git a/pom.xml b/pom.xml index 27f5c81e77..e0c3868d50 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.47-SNAPSHOT + 20.47 pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - HEAD + 20.47 diff --git a/remote-api/pom.xml b/remote-api/pom.xml index d7688caa1d..47b5b5718c 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47-SNAPSHOT + 20.47 diff --git a/repository/pom.xml b/repository/pom.xml index 4ed2c90c8c..0724998ce3 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47-SNAPSHOT + 20.47 From 3b25edefd1b11cfc42220e89d31467e5ea1871b7 Mon Sep 17 00:00:00 2001 From: Travis CI User <8039454+alfresco-build@users.noreply.github.com> Date: Tue, 20 Dec 2022 09:25:30 +0000 Subject: [PATCH 30/37] [maven-release-plugin][skip ci] prepare for next development iteration --- amps/ags/pom.xml | 2 +- amps/ags/rm-automation/pom.xml | 2 +- .../rm-automation/rm-automation-community-rest-api/pom.xml | 2 +- amps/ags/rm-community/pom.xml | 2 +- amps/ags/rm-community/rm-community-repo/pom.xml | 2 +- amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml | 2 +- amps/pom.xml | 2 +- amps/share-services/pom.xml | 2 +- core/pom.xml | 2 +- data-model/pom.xml | 2 +- mmt/pom.xml | 2 +- packaging/distribution/pom.xml | 2 +- packaging/docker-alfresco/pom.xml | 2 +- packaging/pom.xml | 2 +- packaging/tests/pom.xml | 2 +- packaging/tests/tas-cmis/pom.xml | 2 +- packaging/tests/tas-email/pom.xml | 2 +- packaging/tests/tas-integration/pom.xml | 2 +- packaging/tests/tas-restapi/pom.xml | 2 +- packaging/tests/tas-webdav/pom.xml | 2 +- packaging/war/pom.xml | 2 +- pom.xml | 4 ++-- remote-api/pom.xml | 2 +- repository/pom.xml | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/amps/ags/pom.xml b/amps/ags/pom.xml index 5cec421bbf..bd8c260eb9 100644 --- a/amps/ags/pom.xml +++ b/amps/ags/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-amps - 20.47 + 20.48-SNAPSHOT diff --git a/amps/ags/rm-automation/pom.xml b/amps/ags/rm-automation/pom.xml index 2afd548ffa..19b3639fa6 100644 --- a/amps/ags/rm-automation/pom.xml +++ b/amps/ags/rm-automation/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.47 + 20.48-SNAPSHOT diff --git a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml index 5d2f0dcfe1..d9c6457dd6 100644 --- a/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml +++ b/amps/ags/rm-automation/rm-automation-community-rest-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-automation-community-repo - 20.47 + 20.48-SNAPSHOT diff --git a/amps/ags/rm-community/pom.xml b/amps/ags/rm-community/pom.xml index b8f234ed58..ee057689dd 100644 --- a/amps/ags/rm-community/pom.xml +++ b/amps/ags/rm-community/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-parent - 20.47 + 20.48-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-repo/pom.xml b/amps/ags/rm-community/rm-community-repo/pom.xml index 62a04fdb34..8a51e7cf96 100644 --- a/amps/ags/rm-community/rm-community-repo/pom.xml +++ b/amps/ags/rm-community/rm-community-repo/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.47 + 20.48-SNAPSHOT diff --git a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml index 7a88bf5d5b..6bcd05eb46 100644 --- a/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml +++ b/amps/ags/rm-community/rm-community-rest-api-explorer/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-governance-services-community-repo-parent - 20.47 + 20.48-SNAPSHOT diff --git a/amps/pom.xml b/amps/pom.xml index 1e410ce925..36888d4467 100644 --- a/amps/pom.xml +++ b/amps/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47 + 20.48-SNAPSHOT diff --git a/amps/share-services/pom.xml b/amps/share-services/pom.xml index bc12e8be75..7831dffde5 100644 --- a/amps/share-services/pom.xml +++ b/amps/share-services/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-amps - 20.47 + 20.48-SNAPSHOT diff --git a/core/pom.xml b/core/pom.xml index 3f84b5a327..fa7732c945 100644 --- a/core/pom.xml +++ b/core/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47 + 20.48-SNAPSHOT diff --git a/data-model/pom.xml b/data-model/pom.xml index 56f2dd8a46..b699fdbfe4 100644 --- a/data-model/pom.xml +++ b/data-model/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47 + 20.48-SNAPSHOT diff --git a/mmt/pom.xml b/mmt/pom.xml index ef94ea4b1a..9cbe1bdddd 100644 --- a/mmt/pom.xml +++ b/mmt/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47 + 20.48-SNAPSHOT diff --git a/packaging/distribution/pom.xml b/packaging/distribution/pom.xml index a07565803f..dad1b78bbc 100644 --- a/packaging/distribution/pom.xml +++ b/packaging/distribution/pom.xml @@ -9,6 +9,6 @@ org.alfresco alfresco-community-repo-packaging - 20.47 + 20.48-SNAPSHOT diff --git a/packaging/docker-alfresco/pom.xml b/packaging/docker-alfresco/pom.xml index 6c8ad25195..e1092b89e6 100644 --- a/packaging/docker-alfresco/pom.xml +++ b/packaging/docker-alfresco/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.47 + 20.48-SNAPSHOT diff --git a/packaging/pom.xml b/packaging/pom.xml index dbb3e68fb7..1fe3c5419b 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47 + 20.48-SNAPSHOT diff --git a/packaging/tests/pom.xml b/packaging/tests/pom.xml index 6ba7fee7a8..f8a1951e4e 100644 --- a/packaging/tests/pom.xml +++ b/packaging/tests/pom.xml @@ -6,7 +6,7 @@ org.alfresco alfresco-community-repo-packaging - 20.47 + 20.48-SNAPSHOT diff --git a/packaging/tests/tas-cmis/pom.xml b/packaging/tests/tas-cmis/pom.xml index 63c1a3ef85..a6a789fbc7 100644 --- a/packaging/tests/tas-cmis/pom.xml +++ b/packaging/tests/tas-cmis/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-tests - 20.47 + 20.48-SNAPSHOT diff --git a/packaging/tests/tas-email/pom.xml b/packaging/tests/tas-email/pom.xml index 917c65fa49..9724566ab4 100644 --- a/packaging/tests/tas-email/pom.xml +++ b/packaging/tests/tas-email/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.47 + 20.48-SNAPSHOT diff --git a/packaging/tests/tas-integration/pom.xml b/packaging/tests/tas-integration/pom.xml index d9910e825d..aa2b709f2b 100644 --- a/packaging/tests/tas-integration/pom.xml +++ b/packaging/tests/tas-integration/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.47 + 20.48-SNAPSHOT diff --git a/packaging/tests/tas-restapi/pom.xml b/packaging/tests/tas-restapi/pom.xml index 52752a0a5f..d040d52484 100644 --- a/packaging/tests/tas-restapi/pom.xml +++ b/packaging/tests/tas-restapi/pom.xml @@ -8,7 +8,7 @@ org.alfresco alfresco-community-repo-tests - 20.47 + 20.48-SNAPSHOT diff --git a/packaging/tests/tas-webdav/pom.xml b/packaging/tests/tas-webdav/pom.xml index a435487a07..fc8ec74701 100644 --- a/packaging/tests/tas-webdav/pom.xml +++ b/packaging/tests/tas-webdav/pom.xml @@ -9,7 +9,7 @@ org.alfresco alfresco-community-repo-tests - 20.47 + 20.48-SNAPSHOT diff --git a/packaging/war/pom.xml b/packaging/war/pom.xml index b1a55eea46..faf0fda75f 100644 --- a/packaging/war/pom.xml +++ b/packaging/war/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo-packaging - 20.47 + 20.48-SNAPSHOT diff --git a/pom.xml b/pom.xml index e0c3868d50..5d00dbc8ad 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 alfresco-community-repo - 20.47 + 20.48-SNAPSHOT pom Alfresco Community Repo Parent @@ -148,7 +148,7 @@ scm:git:https://github.com/Alfresco/alfresco-community-repo.git scm:git:https://github.com/Alfresco/alfresco-community-repo.git https://github.com/Alfresco/alfresco-community-repo - 20.47 + HEAD diff --git a/remote-api/pom.xml b/remote-api/pom.xml index 47b5b5718c..bd8122793f 100644 --- a/remote-api/pom.xml +++ b/remote-api/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47 + 20.48-SNAPSHOT diff --git a/repository/pom.xml b/repository/pom.xml index 0724998ce3..ab01a35a28 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -7,7 +7,7 @@ org.alfresco alfresco-community-repo - 20.47 + 20.48-SNAPSHOT From d785b100df430408d441e3a6c8d5e200f292219e Mon Sep 17 00:00:00 2001 From: Antonio Felix Date: Thu, 22 Dec 2022 11:48:55 +0000 Subject: [PATCH 31/37] Fix/mnt 23290 slow group membership (#1637) * MNT-23290 - Change query to get the root groups --- .../security/rm-method-security.properties | 1 + .../service/cmr/repository/NodeService.java | 14 +++- .../alfresco/repo/domain/node/NodeDAO.java | 4 +- .../repo/domain/node/ibatis/NodeDAOImpl.java | 18 ++++- .../repo/node/db/DbNodeServiceImpl.java | 11 ++- .../security/authority/AuthorityDAOImpl.java | 9 +-- .../repo/version/NodeServiceImpl.java | 74 ++++++++++--------- .../bundle/VirtualNodeServiceExtension.java | 7 +- .../node-common-SqlMap.xml | 14 ++++ .../public-services-security-context.xml | 1 + 10 files changed, 109 insertions(+), 44 deletions(-) diff --git a/amps/ags/rm-community/rm-community-repo/config/alfresco/module/org_alfresco_module_rm/security/rm-method-security.properties b/amps/ags/rm-community/rm-community-repo/config/alfresco/module/org_alfresco_module_rm/security/rm-method-security.properties index 8c9bd9a7e8..60fe652775 100644 --- a/amps/ags/rm-community/rm-community-repo/config/alfresco/module/org_alfresco_module_rm/security/rm-method-security.properties +++ b/amps/ags/rm-community/rm-community-repo/config/alfresco/module/org_alfresco_module_rm/security/rm-method-security.properties @@ -47,6 +47,7 @@ rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getPaths=RM.Re rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getStoreArchiveNode=RM_ABSTAIN rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.restoreNode=RM_ABSTAIN rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getChildAssocsWithoutParentAssocsOfType=RM_ABSTAIN +rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.findAssocsNotLinkedByTwoOtherAssocs=RM_ABSTAIN rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getNodeRef=RM.Read.0 rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getChildAssocsByPropertyValue=RM.Read.0,AFTER_RM.FilterNode rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.countChildAssocs=RM.Read.0 diff --git a/data-model/src/main/java/org/alfresco/service/cmr/repository/NodeService.java b/data-model/src/main/java/org/alfresco/service/cmr/repository/NodeService.java index 449b4dad9c..b2d59e4935 100644 --- a/data-model/src/main/java/org/alfresco/service/cmr/repository/NodeService.java +++ b/data-model/src/main/java/org/alfresco/service/cmr/repository/NodeService.java @@ -2,7 +2,7 @@ * #%L * Alfresco Data model classes * %% - * Copyright (C) 2005 - 2016 Alfresco Software Limited + * Copyright (C) 2005 - 2022 Alfresco Software Limited * %% * This file is part of the Alfresco software. * If the software was purchased under a paid Alfresco license, the terms of @@ -714,6 +714,18 @@ public interface NodeService final NodeRef parent, final QName assocTypeQName); + /** + * Gets the list of the localnames of the child associations without parent node + * + * @param parent + * the parent node reference + * @return a list of the local names of the child associations + */ + @Auditable(parameters = {"parent"}) + public List findAssocsNotLinkedByTwoOtherAssocs( + final NodeRef parent); + + /** * Create a peer association between two nodes. *

diff --git a/repository/src/main/java/org/alfresco/repo/domain/node/NodeDAO.java b/repository/src/main/java/org/alfresco/repo/domain/node/NodeDAO.java index 787587761e..3c1bb2675d 100644 --- a/repository/src/main/java/org/alfresco/repo/domain/node/NodeDAO.java +++ b/repository/src/main/java/org/alfresco/repo/domain/node/NodeDAO.java @@ -2,7 +2,7 @@ * #%L * Alfresco Repository * %% - * Copyright (C) 2005 - 2016 Alfresco Software Limited + * Copyright (C) 2005 - 2022 Alfresco Software Limited * %% * This file is part of the Alfresco software. * If the software was purchased under a paid Alfresco license, the terms of @@ -894,6 +894,8 @@ public interface NodeDAO extends NodeBulkLoader Serializable nodeValue, ChildAssocRefQueryCallback resultsCallback); + public abstract List selectAssocsNotLinkedByTwoOtherAssocs( + Long parentNodeId); /** * Used by the re-encryptor to re-encrypt encryptable properties with a new encryption key. */ diff --git a/repository/src/main/java/org/alfresco/repo/domain/node/ibatis/NodeDAOImpl.java b/repository/src/main/java/org/alfresco/repo/domain/node/ibatis/NodeDAOImpl.java index e1e9e546f9..a387385de0 100644 --- a/repository/src/main/java/org/alfresco/repo/domain/node/ibatis/NodeDAOImpl.java +++ b/repository/src/main/java/org/alfresco/repo/domain/node/ibatis/NodeDAOImpl.java @@ -2,7 +2,7 @@ * #%L * Alfresco Repository * %% - * Copyright (C) 2005 - 2021 Alfresco Software Limited + * Copyright (C) 2005 - 2022 Alfresco Software Limited * %% * This file is part of the Alfresco software. * If the software was purchased under a paid Alfresco license, the terms of @@ -139,6 +139,8 @@ public class NodeDAOImpl extends AbstractNodeDAOImpl private static final String SELECT_CHILD_ASSOC_OF_PARENT_BY_NAME = "alfresco.node.select_ChildAssocOfParentByName"; private static final String SELECT_CHILD_ASSOCS_OF_PARENT_WITHOUT_PARENT_ASSOCS_OF_TYPE = "alfresco.node.select_ChildAssocsOfParentWithoutParentAssocsOfType"; + + private static final String SELECT_ASSOCS_NOT_LINKED_BY_TWO_OTHER_ASSOCS = "alfresco.node.select_AssocsNotLinkedByTwoOtherAssocs"; private static final String SELECT_CHILD_ASSOCS_OF_PARENT_WITHOUT_NODE_ASSOCS_OF_TYPE = "alfresco.node.select_ChildAssocsOfParentWithoutNodeAssocsOfType"; private static final String SELECT_PARENT_ASSOCS_OF_CHILD = "alfresco.node.select_ParentAssocsOfChild"; @@ -1415,11 +1417,23 @@ public class NodeDAOImpl extends AbstractNodeDAOImpl assoc.setOrdered(resultsCallback.orderResults()); ChildAssocResultHandler resultHandler = new ChildAssocResultHandler(resultsCallback); - + template.select(SELECT_CHILD_ASSOCS_OF_PARENT_WITHOUT_PARENT_ASSOCS_OF_TYPE, assoc, resultHandler); resultsCallback.done(); } + public List selectAssocsNotLinkedByTwoOtherAssocs( + Long parentNodeId) + { + ChildAssocEntity assoc = new ChildAssocEntity(); + // Parent + NodeEntity parentNode = new NodeEntity(); + parentNode.setId(parentNodeId); + assoc.setParentNode(parentNode); + // Type QName + return template.selectList(SELECT_ASSOCS_NOT_LINKED_BY_TWO_OTHER_ASSOCS, assoc); + } + @Override public List selectChildAssocsWithoutNodeAssocsOfTypes(Long parentNodeId, Long minNodeId, Long maxNodeId, Set assocTypeQNames) { diff --git a/repository/src/main/java/org/alfresco/repo/node/db/DbNodeServiceImpl.java b/repository/src/main/java/org/alfresco/repo/node/db/DbNodeServiceImpl.java index cd6e33f032..e0c19856b9 100644 --- a/repository/src/main/java/org/alfresco/repo/node/db/DbNodeServiceImpl.java +++ b/repository/src/main/java/org/alfresco/repo/node/db/DbNodeServiceImpl.java @@ -2133,7 +2133,16 @@ public class DbNodeServiceImpl extends AbstractNodeServiceImpl implements Extens // done return results; } - + + @Extend(traitAPI=NodeServiceTrait.class,extensionAPI=NodeServiceExtension.class) + public List findAssocsNotLinkedByTwoOtherAssocs(NodeRef parent) + { + // Get the parent node + Pair nodePair = getNodePairNotNull(parent); + Long parentNodeId = nodePair.getFirst(); + + return nodeDAO.selectAssocsNotLinkedByTwoOtherAssocs(parentNodeId); + } /** * Specific properties not supported by {@link #getChildAssocsByPropertyValue(NodeRef, QName, Serializable)} */ diff --git a/repository/src/main/java/org/alfresco/repo/security/authority/AuthorityDAOImpl.java b/repository/src/main/java/org/alfresco/repo/security/authority/AuthorityDAOImpl.java index 8e930b3497..f72f4b5177 100644 --- a/repository/src/main/java/org/alfresco/repo/security/authority/AuthorityDAOImpl.java +++ b/repository/src/main/java/org/alfresco/repo/security/authority/AuthorityDAOImpl.java @@ -2,7 +2,7 @@ * #%L * Alfresco Repository * %% - * Copyright (C) 2005 - 2016 Alfresco Software Limited + * Copyright (C) 2005 - 2022 Alfresco Software Limited * %% * This file is part of the Alfresco software. * If the software was purchased under a paid Alfresco license, the terms of @@ -48,7 +48,6 @@ import org.alfresco.query.CannedQueryFactory; import org.alfresco.query.CannedQueryResults; import org.alfresco.query.PagingRequest; import org.alfresco.query.PagingResults; -import org.alfresco.repo.cache.AsynchronouslyRefreshedCache; import org.alfresco.util.cache.RefreshableCacheEvent; import org.alfresco.util.cache.RefreshableCacheListener; import org.alfresco.repo.cache.SimpleCache; @@ -1566,11 +1565,11 @@ public class AuthorityDAOImpl implements AuthorityDAO, NodeServicePolicies.Befor { return Collections. emptySet(); } - Collection childRefs = nodeService.getChildAssocsWithoutParentAssocsOfType(container, ContentModel.ASSOC_MEMBER); + List rootGroupsNames = nodeService.findAssocsNotLinkedByTwoOtherAssocs(container); Set authorities = new TreeSet(); - for (ChildAssociationRef childRef : childRefs) + for (String rootGroupName : rootGroupsNames) { - addAuthorityNameIfMatches(authorities, childRef.getQName().getLocalName(), type); + addAuthorityNameIfMatches(authorities, rootGroupName, type); } return authorities; } diff --git a/repository/src/main/java/org/alfresco/repo/version/NodeServiceImpl.java b/repository/src/main/java/org/alfresco/repo/version/NodeServiceImpl.java index aa3d2514f8..b8c40cc21b 100644 --- a/repository/src/main/java/org/alfresco/repo/version/NodeServiceImpl.java +++ b/repository/src/main/java/org/alfresco/repo/version/NodeServiceImpl.java @@ -1,28 +1,28 @@ -/* - * #%L - * Alfresco Repository - * %% - * Copyright (C) 2005 - 2016 Alfresco Software Limited - * %% - * This file is part of the Alfresco software. - * If the software was purchased under a paid Alfresco license, the terms of - * the paid license agreement will prevail. Otherwise, the software is - * provided under the following open source license terms: - * - * Alfresco is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * Alfresco is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with Alfresco. If not, see . - * #L% - */ +/* + * #%L + * Alfresco Repository + * %% + * Copyright (C) 2005 - 2022 Alfresco Software Limited + * %% + * This file is part of the Alfresco software. + * If the software was purchased under a paid Alfresco license, the terms of + * the paid license agreement will prevail. Otherwise, the software is + * provided under the following open source license terms: + * + * Alfresco is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Alfresco is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with Alfresco. If not, see . + * #L% + */ package org.alfresco.repo.version; import java.io.Serializable; @@ -656,13 +656,13 @@ public class NodeServiceImpl implements NodeService, VersionModel throw new UnsupportedOperationException(MSG_UNSUPPORTED); } - /** - * Gets an association by ID. - * - * @param id - * the association id - * @return the association, or null if it does not exist - */ + /** + * Gets an association by ID. + * + * @param id + * the association id + * @return the association, or null if it does not exist + */ public AssociationRef getAssoc(Long id) { return null; @@ -762,7 +762,15 @@ public class NodeServiceImpl implements NodeService, VersionModel public Collection getChildAssocsWithoutParentAssocsOfType(NodeRef parent, QName assocTypeQName) { throw new UnsupportedOperationException(MSG_UNSUPPORTED); - } + } + + /** + * @throws UnsupportedOperationException always + */ + public List findAssocsNotLinkedByTwoOtherAssocs(NodeRef parent) + { + throw new UnsupportedOperationException(MSG_UNSUPPORTED); + } /** * Gets, converts and adds the intrinsic properties to the current node's properties diff --git a/repository/src/main/java/org/alfresco/repo/virtual/bundle/VirtualNodeServiceExtension.java b/repository/src/main/java/org/alfresco/repo/virtual/bundle/VirtualNodeServiceExtension.java index 7c752236e8..1cf368d1f1 100644 --- a/repository/src/main/java/org/alfresco/repo/virtual/bundle/VirtualNodeServiceExtension.java +++ b/repository/src/main/java/org/alfresco/repo/virtual/bundle/VirtualNodeServiceExtension.java @@ -2,7 +2,7 @@ * #%L * Alfresco Repository * %% - * Copyright (C) 2005 - 2016 Alfresco Software Limited + * Copyright (C) 2005 - 2022 Alfresco Software Limited * %% * This file is part of the Alfresco software. * If the software was purchased under a paid Alfresco license, the terms of @@ -1467,6 +1467,11 @@ public class VirtualNodeServiceExtension extends VirtualSpringBeanExtension findAssocsNotLinkedByTwoOtherAssocs(NodeRef nodeRef){ + return getTrait().findAssocsNotLinkedByTwoOtherAssocs(nodeRef); + } + @Override public void removeAssociation(NodeRef sourceRef, NodeRef targetRef, QName assocTypeQName) throws InvalidNodeRefException diff --git a/repository/src/main/resources/alfresco/ibatis/org.alfresco.repo.domain.dialect.Dialect/node-common-SqlMap.xml b/repository/src/main/resources/alfresco/ibatis/org.alfresco.repo.domain.dialect.Dialect/node-common-SqlMap.xml index 2c1ba5bf32..f208f3d222 100644 --- a/repository/src/main/resources/alfresco/ibatis/org.alfresco.repo.domain.dialect.Dialect/node-common-SqlMap.xml +++ b/repository/src/main/resources/alfresco/ibatis/org.alfresco.repo.domain.dialect.Dialect/node-common-SqlMap.xml @@ -1147,6 +1147,20 @@ parentNode.id = #{parentNode.id} and a.child_node_id IS NULL + +