mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-09-10 14:11:58 +00:00
Compare commits
97 Commits
4880
...
23.1.0.231
Author | SHA1 | Date | |
---|---|---|---|
|
9d60e36682 | ||
|
248fecd030 | ||
|
d3498f4bc4 | ||
|
a862b8f829 | ||
|
73a3f9bb19 | ||
|
71063661ea | ||
|
449c58adad | ||
|
94066cc682 | ||
|
52991462a7 | ||
|
e530ffb9b6 | ||
|
5e0c592fe9 | ||
|
fb3552945e | ||
|
8a43c5741d | ||
|
6af36ae79e | ||
|
d1585e4578 | ||
|
dee199da5e | ||
|
cd0db19ef8 | ||
|
ea835f9185 | ||
|
b3f49ebe54 | ||
|
a956469a0b | ||
|
a6f57ef9e8 | ||
|
67b5c9bc70 | ||
|
cd72aba32b | ||
|
7f43175288 | ||
|
60437b1cc3 | ||
|
5eae584ea5 | ||
|
234222ba4b | ||
|
d6c4934910 | ||
|
5fc889a101 | ||
|
ce8f1bda77 | ||
|
37606c1aa5 | ||
|
48d7f4223e | ||
|
e070354764 | ||
|
0c4ce183be | ||
|
c6881ac128 | ||
|
4c4c561f94 | ||
|
7c993ba695 | ||
|
8f929d9744 | ||
|
c28be29c0e | ||
|
285080566a | ||
|
99f8ba31c4 | ||
|
ce9bf0cd71 | ||
|
e436be7f10 | ||
|
06a4e28b40 | ||
|
5b9311a18a | ||
|
ccd2f5e996 | ||
|
94ac09bf44 | ||
|
9331c33e87 | ||
|
ba250f6872 | ||
|
5343b615e4 | ||
|
80ffd2826c | ||
|
41ce8a869e | ||
|
9ece324e92 | ||
|
ddd0fac97e | ||
|
c43dc66e2e | ||
|
a09c7ef4ca | ||
|
e89f0b4e82 | ||
|
e7f9b439ae | ||
|
4a0f5eab77 | ||
|
779c16677b | ||
|
ddf14c7e31 | ||
|
71df1b01e2 | ||
|
fc83e0d131 | ||
|
bce387bbb7 | ||
|
9fb46ed66c | ||
|
203f2933bc | ||
|
5849da3cc1 | ||
|
c3bcc5f242 | ||
|
7078ba7d56 | ||
|
65dd5be19b | ||
|
08e67aa004 | ||
|
63db311d11 | ||
|
ed674cfa2e | ||
|
21d7cf8c69 | ||
|
077ea7f9a5 | ||
|
6384a33ac9 | ||
|
0800c0e42a | ||
|
94b0bae03c | ||
|
82eef1b975 | ||
|
67fa274abb | ||
|
acc50febda | ||
|
7b4ba83797 | ||
|
874835301e | ||
|
9413bad6ef | ||
|
6af0413b08 | ||
|
5f75662aad | ||
|
6470baeeb2 | ||
|
8bfe25ef51 | ||
|
9207fde808 | ||
|
2f77cdd94f | ||
|
c18144643d | ||
|
746846982c | ||
|
63bc31acd1 | ||
|
332ff9791e | ||
|
03fe795fba | ||
|
557292982a | ||
|
d0fabbdf1f |
96
.github/dependabot.yml
vendored
96
.github/dependabot.yml
vendored
@@ -14,15 +14,6 @@ updates:
|
||||
timezone: Africa/Abidjan
|
||||
open-pull-requests-limit: 99
|
||||
ignore:
|
||||
- dependency-name: com.google.code.gson:gson
|
||||
versions:
|
||||
- "> 2.8.6"
|
||||
- dependency-name: io.fabric8:fabric8-maven-plugin
|
||||
versions:
|
||||
- "> 4.4.0"
|
||||
- dependency-name: javax.servlet:javax.servlet-api
|
||||
versions:
|
||||
- "> 3.0.1"
|
||||
- dependency-name: org.acegisecurity:acegi-security
|
||||
versions:
|
||||
- "> 0.8.2_patched"
|
||||
@@ -52,92 +43,7 @@ updates:
|
||||
- "> 1.0.0"
|
||||
- dependency-name: org.freemarker:freemarker
|
||||
versions:
|
||||
- "> 2.3.20-alfresco-patched-20200421"
|
||||
- dependency-name: org.eclipse.jetty:jetty-server
|
||||
versions:
|
||||
- 9.4.38.v20210224
|
||||
- dependency-name: org.alfresco.tas:cmis
|
||||
versions:
|
||||
- "1.28"
|
||||
- dependency-name: org.springframework:spring-webmvc
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-web
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-tx
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-orm
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-test
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-jms
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-jdbc
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-expression
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-core
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-context-support
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-context
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-beans
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.springframework:spring-aop
|
||||
versions:
|
||||
- 5.3.4
|
||||
- 5.3.5
|
||||
- dependency-name: org.alfresco.tas:restapi
|
||||
versions:
|
||||
- "1.55"
|
||||
- dependency-name: org.eclipse.jetty:jetty-security
|
||||
versions:
|
||||
- 11.0.1
|
||||
- dependency-name: org.alfresco.aos-module:alfresco-vti-bin
|
||||
versions:
|
||||
- 1.4.0-M1
|
||||
- dependency-name: org.alfresco.aos-module:alfresco-aos-module-distributionzip
|
||||
versions:
|
||||
- 1.4.0-M1
|
||||
- dependency-name: org.alfresco.aos-module:alfresco-aos-module
|
||||
versions:
|
||||
- 1.4.0-M1
|
||||
- dependency-name: org.alfresco.surf:spring-webscripts-api
|
||||
versions:
|
||||
- "8.16"
|
||||
- dependency-name: org.alfresco.surf:spring-webscripts:tests
|
||||
versions:
|
||||
- "8.16"
|
||||
- dependency-name: org.alfresco.surf:spring-webscripts
|
||||
versions:
|
||||
- "8.16"
|
||||
- dependency-name: org.alfresco.surf:spring-surf-core-configservice
|
||||
versions:
|
||||
- "8.16"
|
||||
- "> 2.3.31-alfresco-patched"
|
||||
registries:
|
||||
- maven-repository-artifacts-alfresco-com-nexus-content-groups-int
|
||||
- package-ecosystem: "docker"
|
||||
|
4
.github/workflows/ci.yml
vendored
4
.github/workflows/ci.yml
vendored
@@ -76,9 +76,7 @@ jobs:
|
||||
!contains(github.event.head_commit.message, '[skip tests]') &&
|
||||
!contains(github.event.head_commit.message, '[force]')
|
||||
steps:
|
||||
- uses: Alfresco/ya-pmd-scan@v2.0.0
|
||||
with:
|
||||
fail-on-new-issues: "false"
|
||||
- uses: Alfresco/ya-pmd-scan@v2.0.4
|
||||
|
||||
all_unit_tests_suite:
|
||||
name: "Core, Data-Model, Repository - AllUnitTestsSuite - Build and test"
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-amps</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<modules>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-governance-services-community-parent</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<modules>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-governance-services-automation-community-repo</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<build>
|
||||
|
@@ -26,8 +26,8 @@
|
||||
*/
|
||||
package org.alfresco.rest.core.v0;
|
||||
|
||||
import javax.json.Json;
|
||||
import javax.json.JsonReader;
|
||||
import jakarta.json.Json;
|
||||
import jakarta.json.JsonReader;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
|
@@ -42,8 +42,8 @@ import static org.testng.Assert.assertNotNull;
|
||||
import static org.testng.Assert.assertTrue;
|
||||
import static org.testng.AssertJUnit.assertFalse;
|
||||
|
||||
import javax.json.Json;
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.Json;
|
||||
import jakarta.json.JsonObject;
|
||||
import java.io.File;
|
||||
|
||||
import org.alfresco.dataprep.CMISUtil;
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-governance-services-community-parent</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<modules>
|
||||
|
@@ -1,3 +1,3 @@
|
||||
SOLR6_TAG=2.0.7-A5
|
||||
SOLR6_TAG=2.0.8.1
|
||||
POSTGRES_TAG=14.4
|
||||
ACTIVEMQ_TAG=5.18.2-jre17-rockylinux8
|
||||
|
@@ -8,7 +8,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-governance-services-community-repo-parent</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<properties>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-governance-services-community-repo-parent</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<build>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<modules>
|
||||
|
@@ -8,7 +8,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-amps</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<properties>
|
||||
@@ -131,23 +131,6 @@
|
||||
<groupId>jakarta.servlet</groupId>
|
||||
<artifactId>jakarta.servlet-api</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SHA-2432 -->
|
||||
<dependency>
|
||||
<groupId>org.apache.taglibs</groupId>
|
||||
<artifactId>taglibs-standard-spec</artifactId>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.taglibs</groupId>
|
||||
<artifactId>taglibs-standard-impl</artifactId>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.taglibs</groupId>
|
||||
<artifactId>taglibs-standard-jstlel</artifactId>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<properties>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
|
@@ -9,6 +9,6 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-packaging</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
</project>
|
||||
|
@@ -208,10 +208,6 @@ Hibernate http://www.hibernate.org/
|
||||
jid3lib http://javamusictag.sourceforge.net/
|
||||
TinyMCE http://www.tinymce.com/
|
||||
|
||||
|
||||
=== LGPL 3.0 ===
|
||||
Gytheio https://github.com/Alfresco/gytheio
|
||||
|
||||
|
||||
=== MIT License ===
|
||||
Bouncy Castle http://www.bouncycastle.org/
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-packaging</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<properties>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<modules>
|
||||
|
@@ -1,3 +1,3 @@
|
||||
SOLR6_TAG=2.0.7-A5
|
||||
SOLR6_TAG=2.0.8.1
|
||||
POSTGRES_TAG=14.4
|
||||
ACTIVEMQ_TAG=5.18.2-jre17-rockylinux8
|
||||
|
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-packaging</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<modules>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-tests</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<organization>
|
||||
|
@@ -9,7 +9,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-tests</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<developers>
|
||||
|
@@ -9,7 +9,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-tests</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<developers>
|
||||
|
@@ -7,7 +7,7 @@ import static org.hamcrest.Matchers.equalTo;
|
||||
import io.restassured.RestAssured;
|
||||
import java.io.File;
|
||||
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.JsonObject;
|
||||
import jakarta.mail.Flags;
|
||||
import jakarta.mail.MessagingException;
|
||||
|
||||
|
@@ -7,7 +7,7 @@ import io.restassured.http.ContentType;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.JsonObject;
|
||||
|
||||
import org.alfresco.rest.core.JsonBodyGenerator;
|
||||
import org.alfresco.rest.core.RestRequest;
|
||||
|
@@ -8,7 +8,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-tests</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<properties>
|
||||
@@ -17,7 +17,6 @@
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<rest.api.explorer.branch>master</rest.api.explorer.branch>
|
||||
<httpclient-osgi-version>4.5.6</httpclient-osgi-version>
|
||||
<org.glassfish.version>1.1.4</org.glassfish.version>
|
||||
<commons-lang3.version>3.13.0</commons-lang3.version>
|
||||
<scribejava-apis.version>8.3.3</scribejava-apis.version>
|
||||
<java.version>17</java.version>
|
||||
@@ -138,13 +137,6 @@
|
||||
<artifactId>jackson-databind</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- https://mvnrepository.com/artifact/org.glassfish/javax.json -->
|
||||
<dependency>
|
||||
<groupId>org.glassfish</groupId>
|
||||
<artifactId>javax.json</artifactId>
|
||||
<version>${org.glassfish.version}</version>
|
||||
</dependency>
|
||||
|
||||
<!-- swagger parser -->
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
@@ -184,9 +176,8 @@
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.glassfish</groupId>
|
||||
<artifactId>jakarta.json</artifactId>
|
||||
<scope>test</scope>
|
||||
<groupId>org.eclipse.parsson</groupId>
|
||||
<artifactId>parsson</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
|
@@ -25,11 +25,11 @@
|
||||
*/
|
||||
package org.alfresco.rest.core;
|
||||
|
||||
import javax.json.Json;
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import javax.json.JsonBuilderFactory;
|
||||
import javax.json.JsonObject;
|
||||
import javax.json.JsonObjectBuilder;
|
||||
import jakarta.json.Json;
|
||||
import jakarta.json.JsonArrayBuilder;
|
||||
import jakarta.json.JsonBuilderFactory;
|
||||
import jakarta.json.JsonObject;
|
||||
import jakarta.json.JsonObjectBuilder;
|
||||
import java.io.Serializable;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
@@ -31,15 +31,10 @@ import org.alfresco.rest.core.RestWrapper;
|
||||
import org.alfresco.rest.model.RestCustomAspectModel;
|
||||
import org.alfresco.rest.model.RestCustomModel;
|
||||
import org.alfresco.rest.model.RestCustomTypeModel;
|
||||
import org.alfresco.rest.model.RestGroupsModelsCollection;
|
||||
import org.alfresco.utility.model.CustomAspectModel;
|
||||
import org.alfresco.utility.model.CustomAspectPropertiesModel;
|
||||
import org.alfresco.utility.model.CustomContentModel;
|
||||
import org.springframework.http.HttpMethod;
|
||||
|
||||
import javax.json.Json;
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import javax.json.JsonObject;
|
||||
|
||||
/**
|
||||
* @author Bogdan Bocancea
|
||||
|
@@ -33,8 +33,8 @@ import org.alfresco.utility.model.CustomContentModel;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.http.HttpMethod;
|
||||
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import javax.json.JsonObjectBuilder;
|
||||
import jakarta.json.JsonArrayBuilder;
|
||||
import jakarta.json.JsonObjectBuilder;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
@@ -30,7 +30,7 @@ import static org.alfresco.rest.core.JsonBodyGenerator.arrayToJson;
|
||||
import static org.alfresco.rest.requests.RuleSettings.IS_INHERITANCE_ENABLED;
|
||||
import static org.springframework.http.HttpMethod.PUT;
|
||||
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import jakarta.json.JsonArrayBuilder;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.IOException;
|
||||
|
@@ -25,7 +25,7 @@
|
||||
*/
|
||||
package org.alfresco.rest.requests;
|
||||
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import jakarta.json.JsonArrayBuilder;
|
||||
|
||||
import org.alfresco.dataprep.CMISUtil.Priority;
|
||||
import org.alfresco.rest.core.JsonBodyGenerator;
|
||||
|
@@ -27,7 +27,7 @@ package org.alfresco.rest.requests;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import jakarta.json.JsonArrayBuilder;
|
||||
|
||||
import org.alfresco.rest.core.JsonBodyGenerator;
|
||||
import org.alfresco.rest.core.RestRequest;
|
||||
|
@@ -25,8 +25,8 @@
|
||||
*/
|
||||
package org.alfresco.rest.requests;
|
||||
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.JsonArrayBuilder;
|
||||
import jakarta.json.JsonObject;
|
||||
|
||||
import org.alfresco.rest.core.JsonBodyGenerator;
|
||||
import org.alfresco.rest.core.RestRequest;
|
||||
|
@@ -39,8 +39,8 @@
|
||||
*/
|
||||
package org.alfresco.rest.requests.search;
|
||||
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import javax.json.JsonObjectBuilder;
|
||||
import jakarta.json.JsonArrayBuilder;
|
||||
import jakarta.json.JsonObjectBuilder;
|
||||
|
||||
import io.restassured.RestAssured;
|
||||
|
||||
|
@@ -27,7 +27,7 @@ package org.alfresco.rest.requests.syncServiceAPI;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import jakarta.json.JsonArrayBuilder;
|
||||
|
||||
import org.alfresco.rest.core.JsonBodyGenerator;
|
||||
import org.alfresco.rest.core.RestRequest;
|
||||
|
@@ -27,7 +27,7 @@ package org.alfresco.rest.requests.syncServiceAPI;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import javax.json.JsonArrayBuilder;
|
||||
import jakarta.json.JsonArrayBuilder;
|
||||
|
||||
import org.alfresco.rest.core.JsonBodyGenerator;
|
||||
import org.alfresco.rest.core.RestRequest;
|
||||
|
@@ -25,7 +25,7 @@
|
||||
*/
|
||||
package org.alfresco.rest.requests.workflowAPI;
|
||||
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.JsonObject;
|
||||
|
||||
import org.alfresco.dataprep.CMISUtil.Priority;
|
||||
import org.alfresco.rest.core.RestWrapper;
|
||||
|
@@ -44,6 +44,7 @@
|
||||
package org.alfresco.rest.search;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
@@ -52,11 +53,11 @@ import org.alfresco.utility.model.TestModel;
|
||||
* @author Michael Suzuki
|
||||
*
|
||||
*/
|
||||
public class ResponseHighLightModel extends TestModel implements IRestModel<ResponseHighLightModel>
|
||||
public class ResponseHighlightModel extends TestModel implements IRestModel<ResponseHighlightModel>
|
||||
{
|
||||
private ResponseHighLightModel model;
|
||||
private ResponseHighlightModel model;
|
||||
private String field;
|
||||
private List<Object> snippets;
|
||||
private List<String> snippets;
|
||||
|
||||
public String getField()
|
||||
{
|
||||
@@ -66,19 +67,44 @@ public class ResponseHighLightModel extends TestModel implements IRestModel<Resp
|
||||
{
|
||||
this.field = field;
|
||||
}
|
||||
public List<Object> getSnippets()
|
||||
public List<String> getSnippets()
|
||||
{
|
||||
return snippets;
|
||||
}
|
||||
public void setSnippets(List<Object> snippets)
|
||||
public void setSnippets(List<String> snippets)
|
||||
{
|
||||
this.snippets = snippets;
|
||||
}
|
||||
@Override
|
||||
public ResponseHighLightModel onModel()
|
||||
public ResponseHighlightModel onModel()
|
||||
{
|
||||
return model;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o)
|
||||
{
|
||||
if (this == o)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
if (o == null || getClass() != o.getClass())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
ResponseHighlightModel that = (ResponseHighlightModel) o;
|
||||
return Objects.equals(model, that.model) && Objects.equals(field, that.field) && Objects.equals(snippets, that.snippets);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode()
|
||||
{
|
||||
return Objects.hash(model, field, snippets);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
return "ResponseHighlightModel{model=%s, field=%s, snippets=%s}".formatted(model, field, snippets);
|
||||
}
|
||||
}
|
@@ -2,23 +2,23 @@
|
||||
* #%L
|
||||
* alfresco-tas-restapi
|
||||
* %%
|
||||
* Copyright (C) 2005 - 2022 Alfresco Software Limited
|
||||
* Copyright (C) 2005 - 2023 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
|
||||
* 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 <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
@@ -33,62 +33,38 @@ import org.alfresco.rest.core.IRestModel;
|
||||
import org.alfresco.utility.model.TestModel;
|
||||
|
||||
/**
|
||||
* Generated by 'msuzuki' on '2017-02-23 13:41' from 'Alfresco Search REST API' swagger file
|
||||
* Generated by 'msuzuki' on '2017-02-23 13:41' from 'Alfresco Search REST API' swagger file
|
||||
* Generated from 'Alfresco Search REST API' swagger file
|
||||
* Base Path {@linkplain /alfresco/api/-default-/public/search/versions/1}
|
||||
*/
|
||||
public class RestRequestHighlightModel extends TestModel implements IRestModel<RestRequestHighlightModel>
|
||||
{
|
||||
@JsonProperty(value = "entry")
|
||||
@JsonProperty("entry")
|
||||
RestRequestHighlightModel model;
|
||||
|
||||
/** The string used to mark the start of a highlight in a fragment. */
|
||||
private String prefix;
|
||||
/** The string used to mark the end of a highlight in a fragment. */
|
||||
private String postfix;
|
||||
/** The maximum number of distinct highlight snippets to return for each highlight field. */
|
||||
private int snippetCount;
|
||||
/** The character length of each snippet. */
|
||||
private int fragmentSize;
|
||||
/** The number of characters to be considered for highlighting. Matches after this count will not be shown. */
|
||||
private int maxAnalyzedChars;
|
||||
/** If fragments overlap they can be merged into one larger fragment */
|
||||
private boolean mergeContiguous;
|
||||
/** Should phrases be identified. */
|
||||
private boolean usePhraseHighlighter;
|
||||
/** The fields to highlight and field specific configuration properties for each field */
|
||||
private List<RestRequestFieldsModel> fields;
|
||||
|
||||
@Override
|
||||
public RestRequestHighlightModel onModel()
|
||||
{
|
||||
return model;
|
||||
}
|
||||
|
||||
/**
|
||||
The string used to mark the start of a highlight in a fragment.
|
||||
*/
|
||||
|
||||
private String prefix;
|
||||
/**
|
||||
The string used to mark the end of a highlight in a fragment.
|
||||
*/
|
||||
|
||||
private String postfix;
|
||||
/**
|
||||
The maximum number of distinct highlight snippets to return for each highlight field.
|
||||
*/
|
||||
|
||||
private int snippetCount;
|
||||
/**
|
||||
The character length of each snippet.
|
||||
*/
|
||||
|
||||
private int fragmentSize;
|
||||
/**
|
||||
The number of characters to be considered for highlighting. Matches after this count will not be shown.
|
||||
*/
|
||||
|
||||
private int maxAnalyzedChars;
|
||||
/**
|
||||
If fragments over lap they can be merged into one larger fragment
|
||||
*/
|
||||
|
||||
private boolean mergeContiguous;
|
||||
/**
|
||||
Should phrases be identified.
|
||||
*/
|
||||
|
||||
private boolean usePhraseHighlighter;
|
||||
/**
|
||||
The fields to highlight and field specific configuration properties for each field
|
||||
*/
|
||||
|
||||
private List<RestRequestFieldsModel> fields;
|
||||
|
||||
public String getPrefix()
|
||||
{
|
||||
return this.prefix;
|
||||
@@ -97,7 +73,7 @@ public class RestRequestHighlightModel extends TestModel implements IRestModel<R
|
||||
public void setPrefix(String prefix)
|
||||
{
|
||||
this.prefix = prefix;
|
||||
}
|
||||
}
|
||||
|
||||
public String getPostfix()
|
||||
{
|
||||
@@ -107,7 +83,7 @@ public class RestRequestHighlightModel extends TestModel implements IRestModel<R
|
||||
public void setPostfix(String postfix)
|
||||
{
|
||||
this.postfix = postfix;
|
||||
}
|
||||
}
|
||||
|
||||
public int getSnippetCount()
|
||||
{
|
||||
@@ -117,7 +93,7 @@ public class RestRequestHighlightModel extends TestModel implements IRestModel<R
|
||||
public void setSnippetCount(int snippetCount)
|
||||
{
|
||||
this.snippetCount = snippetCount;
|
||||
}
|
||||
}
|
||||
|
||||
public int getFragmentSize()
|
||||
{
|
||||
@@ -127,7 +103,7 @@ public class RestRequestHighlightModel extends TestModel implements IRestModel<R
|
||||
public void setFragmentSize(int fragmentSize)
|
||||
{
|
||||
this.fragmentSize = fragmentSize;
|
||||
}
|
||||
}
|
||||
|
||||
public int getMaxAnalyzedChars()
|
||||
{
|
||||
@@ -137,9 +113,9 @@ public class RestRequestHighlightModel extends TestModel implements IRestModel<R
|
||||
public void setMaxAnalyzedChars(int maxAnalyzedChars)
|
||||
{
|
||||
this.maxAnalyzedChars = maxAnalyzedChars;
|
||||
}
|
||||
}
|
||||
|
||||
public boolean getMergeContiguous()
|
||||
public boolean isMergeContiguous()
|
||||
{
|
||||
return this.mergeContiguous;
|
||||
}
|
||||
@@ -147,9 +123,9 @@ public class RestRequestHighlightModel extends TestModel implements IRestModel<R
|
||||
public void setMergeContiguous(boolean mergeContiguous)
|
||||
{
|
||||
this.mergeContiguous = mergeContiguous;
|
||||
}
|
||||
}
|
||||
|
||||
public boolean getUsePhraseHighlighter()
|
||||
public boolean isUsePhraseHighlighter()
|
||||
{
|
||||
return this.usePhraseHighlighter;
|
||||
}
|
||||
@@ -157,7 +133,7 @@ public class RestRequestHighlightModel extends TestModel implements IRestModel<R
|
||||
public void setUsePhraseHighlighter(boolean usePhraseHighlighter)
|
||||
{
|
||||
this.usePhraseHighlighter = usePhraseHighlighter;
|
||||
}
|
||||
}
|
||||
|
||||
public List<RestRequestFieldsModel> getFields()
|
||||
{
|
||||
@@ -167,6 +143,85 @@ public class RestRequestHighlightModel extends TestModel implements IRestModel<R
|
||||
public void setFields(List<RestRequestFieldsModel> fields)
|
||||
{
|
||||
this.fields = fields;
|
||||
}
|
||||
}
|
||||
|
||||
public static RestRequestHighlightModelBuilder builder()
|
||||
{
|
||||
return new RestRequestHighlightModelBuilder();
|
||||
}
|
||||
|
||||
public static class RestRequestHighlightModelBuilder
|
||||
{
|
||||
private String prefix;
|
||||
private String postfix;
|
||||
private int snippetCount;
|
||||
private int fragmentSize;
|
||||
private int maxAnalyzedChars;
|
||||
private boolean mergeContiguous;
|
||||
private boolean usePhraseHighlighter;
|
||||
private List<RestRequestFieldsModel> fields;
|
||||
|
||||
public RestRequestHighlightModelBuilder prefix(String prefix)
|
||||
{
|
||||
this.prefix = prefix;
|
||||
return this;
|
||||
}
|
||||
|
||||
public RestRequestHighlightModelBuilder postfix(String postfix)
|
||||
{
|
||||
this.postfix = postfix;
|
||||
return this;
|
||||
}
|
||||
|
||||
public RestRequestHighlightModelBuilder snippetCount(int snippetCount)
|
||||
{
|
||||
this.snippetCount = snippetCount;
|
||||
return this;
|
||||
}
|
||||
|
||||
public RestRequestHighlightModelBuilder fragmentSize(int fragmentSize)
|
||||
{
|
||||
this.fragmentSize = fragmentSize;
|
||||
return this;
|
||||
}
|
||||
|
||||
public RestRequestHighlightModelBuilder maxAnalyzedChars(int maxAnalyzedChars)
|
||||
{
|
||||
this.maxAnalyzedChars = maxAnalyzedChars;
|
||||
return this;
|
||||
}
|
||||
|
||||
public RestRequestHighlightModelBuilder mergeContinuous(boolean mergeContiguous)
|
||||
{
|
||||
this.mergeContiguous = mergeContiguous;
|
||||
return this;
|
||||
}
|
||||
|
||||
public RestRequestHighlightModelBuilder usePhraseHighlighter(boolean usePhraseHighlighter)
|
||||
{
|
||||
this.usePhraseHighlighter = usePhraseHighlighter;
|
||||
return this;
|
||||
}
|
||||
|
||||
public RestRequestHighlightModelBuilder fields(List<String> fields)
|
||||
{
|
||||
this.fields = fields.stream().map(field -> new RestRequestFieldsModel(field)).toList();
|
||||
return this;
|
||||
}
|
||||
|
||||
public RestRequestHighlightModel build()
|
||||
{
|
||||
RestRequestHighlightModel highlightModel = new RestRequestHighlightModel();
|
||||
highlightModel.setPrefix(prefix);
|
||||
highlightModel.setPostfix(postfix);
|
||||
highlightModel.setSnippetCount(snippetCount);
|
||||
highlightModel.setFragmentSize(fragmentSize);
|
||||
highlightModel.setMaxAnalyzedChars(maxAnalyzedChars);
|
||||
highlightModel.setMergeContiguous(mergeContiguous);
|
||||
highlightModel.setUsePhraseHighlighter(usePhraseHighlighter);
|
||||
highlightModel.setFields(fields);
|
||||
return highlightModel;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -60,7 +60,7 @@ public class SearchScoreModel extends TestModel implements IRestModel<SearchScor
|
||||
@JsonProperty(required = true)
|
||||
private float score;
|
||||
|
||||
private List<ResponseHighLightModel> highlight;
|
||||
private List<ResponseHighlightModel> highlight;
|
||||
|
||||
public float getScore()
|
||||
{
|
||||
@@ -78,12 +78,12 @@ public class SearchScoreModel extends TestModel implements IRestModel<SearchScor
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<ResponseHighLightModel> getHighlight()
|
||||
public List<ResponseHighlightModel> getHighlight()
|
||||
{
|
||||
return highlight;
|
||||
}
|
||||
|
||||
public void setHighlight(List<ResponseHighLightModel> highlight)
|
||||
public void setHighlight(List<ResponseHighlightModel> highlight)
|
||||
{
|
||||
this.highlight = highlight;
|
||||
}
|
||||
|
@@ -9,7 +9,7 @@ import java.io.InputStream;
|
||||
import java.io.Serializable;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.JsonObject;
|
||||
|
||||
import org.alfresco.rest.RestTest;
|
||||
import org.alfresco.rest.core.JsonBodyGenerator;
|
||||
|
@@ -35,7 +35,7 @@ import static org.springframework.http.HttpStatus.NOT_FOUND;
|
||||
import static org.springframework.http.HttpStatus.NO_CONTENT;
|
||||
import static org.springframework.http.HttpStatus.UNPROCESSABLE_ENTITY;
|
||||
|
||||
import javax.json.Json;
|
||||
import jakarta.json.Json;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
|
@@ -32,7 +32,7 @@ import static org.springframework.http.HttpStatus.NOT_FOUND;
|
||||
import static org.springframework.http.HttpStatus.OK;
|
||||
import static org.springframework.http.HttpStatus.UNPROCESSABLE_ENTITY;
|
||||
|
||||
import javax.json.Json;
|
||||
import jakarta.json.Json;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.stream.IntStream;
|
||||
|
@@ -1,6 +1,6 @@
|
||||
package org.alfresco.rest.downloads;
|
||||
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.JsonObject;
|
||||
|
||||
import org.alfresco.dataprep.CMISUtil.DocumentType;
|
||||
import org.alfresco.rest.RestTest;
|
||||
|
@@ -2,8 +2,8 @@ package org.alfresco.rest.groups;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
import javax.json.Json;
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.Json;
|
||||
import jakarta.json.JsonObject;
|
||||
|
||||
import org.alfresco.rest.RestTest;
|
||||
import org.alfresco.utility.RetryOperation;
|
||||
|
@@ -10,8 +10,8 @@ import static org.testng.Assert.assertNull;
|
||||
import static org.testng.Assert.assertSame;
|
||||
import static org.testng.Assert.assertTrue;
|
||||
|
||||
import javax.json.Json;
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.Json;
|
||||
import jakarta.json.JsonObject;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.io.RandomAccessFile;
|
||||
|
@@ -2,8 +2,8 @@ package org.alfresco.rest.nodes;
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
|
||||
import javax.json.Json;
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.Json;
|
||||
import jakarta.json.JsonObject;
|
||||
|
||||
import org.alfresco.dataprep.CMISUtil;
|
||||
import org.alfresco.rest.RestTest;
|
||||
|
@@ -58,8 +58,8 @@ 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;
|
||||
import jakarta.json.Json;
|
||||
import jakarta.json.JsonObject;
|
||||
|
||||
import org.alfresco.rest.model.RestActionBodyExecTemplateModel;
|
||||
import org.alfresco.rest.model.RestActionConstraintModel;
|
||||
|
@@ -1,7 +1,7 @@
|
||||
package org.alfresco.rest.sharedLinks;
|
||||
|
||||
import javax.json.Json;
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.Json;
|
||||
import jakarta.json.JsonObject;
|
||||
|
||||
import org.alfresco.dataprep.CMISUtil.DocumentType;
|
||||
import org.alfresco.rest.RestTest;
|
||||
|
@@ -1,6 +1,6 @@
|
||||
package org.alfresco.rest.sharedLinks;
|
||||
|
||||
import javax.json.Json;
|
||||
import jakarta.json.Json;
|
||||
|
||||
import org.alfresco.dataprep.CMISUtil.DocumentType;
|
||||
import org.alfresco.rest.RestTest;
|
||||
|
@@ -1,6 +1,6 @@
|
||||
package org.alfresco.rest.workflow.processes;
|
||||
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.JsonObject;
|
||||
|
||||
import org.alfresco.dataprep.CMISUtil.Priority;
|
||||
import org.alfresco.rest.RestTest;
|
||||
|
@@ -19,7 +19,7 @@ import org.testng.annotations.BeforeClass;
|
||||
import org.testng.annotations.BeforeMethod;
|
||||
import org.testng.annotations.Test;
|
||||
|
||||
import javax.json.JsonObject;
|
||||
import jakarta.json.JsonObject;
|
||||
import java.util.HashMap;
|
||||
|
||||
public class UpdateTaskTests extends RestTest
|
||||
|
@@ -9,7 +9,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-tests</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<developers>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo-packaging</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<properties>
|
||||
|
101
pom.xml
101
pom.xml
@@ -2,7 +2,7 @@
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>alfresco-community-repo</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
<packaging>pom</packaging>
|
||||
<name>Alfresco Community Repo Parent</name>
|
||||
|
||||
@@ -51,37 +51,37 @@
|
||||
<dependency.alfresco-server-root.version>7.0.1</dependency.alfresco-server-root.version>
|
||||
<dependency.activiti-engine.version>5.23.0</dependency.activiti-engine.version>
|
||||
<dependency.activiti.version>5.23.0</dependency.activiti.version>
|
||||
<dependency.alfresco-transform-service.version>3.0.1-A2</dependency.alfresco-transform-service.version>
|
||||
<dependency.alfresco-transform-core.version>4.0.1-A3</dependency.alfresco-transform-core.version>
|
||||
<dependency.alfresco-transform-service.version>4.0.0-A1</dependency.alfresco-transform-service.version>
|
||||
<dependency.alfresco-transform-core.version>5.0.0-A2</dependency.alfresco-transform-core.version>
|
||||
<dependency.alfresco-greenmail.version>7.0</dependency.alfresco-greenmail.version>
|
||||
<dependency.acs-event-model.version>0.0.23</dependency.acs-event-model.version>
|
||||
|
||||
<dependency.spring.version>6.0.9</dependency.spring.version>
|
||||
<dependency.aspectj.version>1.9.20.1</dependency.aspectj.version>
|
||||
<dependency.spring.version>6.0.12</dependency.spring.version>
|
||||
<dependency.spring-security.version>6.1.4</dependency.spring-security.version>
|
||||
<dependency.antlr.version>3.5.3</dependency.antlr.version>
|
||||
<dependency.jackson.version>2.15.2</dependency.jackson.version>
|
||||
<dependency.cxf.version>4.0.2</dependency.cxf.version>
|
||||
<dependency.opencmis.version>1.0.0-jakarta-1</dependency.opencmis.version>
|
||||
<dependency.webscripts.version>8.46</dependency.webscripts.version>
|
||||
<dependency.webscripts.version>9.0</dependency.webscripts.version>
|
||||
<dependency.bouncycastle.version>1.76</dependency.bouncycastle.version>
|
||||
<dependency.mockito-core.version>5.4.0</dependency.mockito-core.version>
|
||||
<dependency.assertj.version>3.24.2</dependency.assertj.version>
|
||||
<dependency.org-json.version>20230618</dependency.org-json.version>
|
||||
<dependency.commons-dbcp.version>2.9.0</dependency.commons-dbcp.version>
|
||||
<dependency.commons-io.version>2.13.0</dependency.commons-io.version>
|
||||
<dependency.gson.version>2.8.9</dependency.gson.version>
|
||||
<dependency.gson.version>2.10.1</dependency.gson.version>
|
||||
<dependency.guava.version>32.1.2-jre</dependency.guava.version>
|
||||
<dependency.httpclient.version>4.5.13</dependency.httpclient.version>
|
||||
<dependency.httpclient.version>4.5.14</dependency.httpclient.version>
|
||||
<dependency.httpcore.version>4.4.16</dependency.httpcore.version>
|
||||
<dependency.httpcomponents-httpclient5.version>5.2.1</dependency.httpcomponents-httpclient5.version>
|
||||
<dependency.httpcomponents-httpcore5.version>5.2.2</dependency.httpcomponents-httpcore5.version>
|
||||
<dependency.httpcomponents-httpcore5.version>5.2.3</dependency.httpcomponents-httpcore5.version>
|
||||
<dependency.commons-httpclient.version>3.1-HTTPCLIENT-1265</dependency.commons-httpclient.version>
|
||||
<dependency.xercesImpl.version>2.12.2</dependency.xercesImpl.version>
|
||||
<dependency.slf4j.version>2.0.7</dependency.slf4j.version>
|
||||
<dependency.slf4j.version>2.0.9</dependency.slf4j.version>
|
||||
<dependency.log4j.version>2.20.0</dependency.log4j.version>
|
||||
<dependency.gytheio.version>0.20.0-A1</dependency.gytheio.version>
|
||||
<dependency.groovy.version>3.0.19</dependency.groovy.version>
|
||||
<dependency.tika.version>2.4.1</dependency.tika.version>
|
||||
<dependency.spring-security.version>6.1.3</dependency.spring-security.version>
|
||||
<dependency.truezip.version>7.7.10</dependency.truezip.version>
|
||||
<dependency.poi.version>5.2.2</dependency.poi.version>
|
||||
<dependency.poi-ooxml-lite.version>5.2.3</dependency.poi-ooxml-lite.version>
|
||||
@@ -89,15 +89,14 @@
|
||||
<dependency.camel.version>4.0.0</dependency.camel.version> <!-- when bumping this version, please keep track/sync with included netty.io dependencies -->
|
||||
<dependency.netty.version>4.1.96.Final</dependency.netty.version> <!-- must be in sync with camels transitive dependencies, e.g.: netty-common -->
|
||||
<dependency.activemq.version>5.18.2</dependency.activemq.version>
|
||||
<dependency.apache-compress.version>1.23.0</dependency.apache-compress.version>
|
||||
<dependency.apache.taglibs.version>1.2.5</dependency.apache.taglibs.version>
|
||||
<dependency.apache-compress.version>1.24.0</dependency.apache-compress.version>
|
||||
<dependency.awaitility.version>4.2.0</dependency.awaitility.version>
|
||||
<dependency.swagger-ui.version>3.38.0</dependency.swagger-ui.version>
|
||||
<dependency.swagger-parser.version>1.0.67</dependency.swagger-parser.version>
|
||||
<dependency.maven-filtering.version>3.1.1</dependency.maven-filtering.version>
|
||||
<dependency.maven-artifact.version>3.8.6</dependency.maven-artifact.version>
|
||||
<dependency.jdom2.version>2.0.6.1</dependency.jdom2.version>
|
||||
<dependency.pooled-jms.version>3.1.1</dependency.pooled-jms.version>
|
||||
<dependency.pooled-jms.version>3.1.2</dependency.pooled-jms.version>
|
||||
|
||||
<dependency.jakarta-ee-jaxb-api.version>4.0.0</dependency.jakarta-ee-jaxb-api.version>
|
||||
<dependency.jakarta-ee-jaxb-impl.version>4.0.3</dependency.jakarta-ee-jaxb-impl.version>
|
||||
@@ -111,13 +110,12 @@
|
||||
<dependency.jakarta-ee-activation.version>2.0.1</dependency.jakarta-ee-activation.version>
|
||||
<dependency.jakarta-ee-jms.version>3.0.0</dependency.jakarta-ee-jms.version>
|
||||
<dependency.java-ee-activation.version>1.2.0</dependency.java-ee-activation.version>
|
||||
<dependency.jakarta-json-api.version>1.1.6</dependency.jakarta-json-api.version>
|
||||
<dependency.jakarta-ee-json-api.version>2.1.2</dependency.jakarta-ee-json-api.version>
|
||||
<dependency.jakarta-ee-json-impl.version>1.1.4</dependency.jakarta-ee-json-impl.version>
|
||||
<dependency.jakarta-json-path.version>2.8.0</dependency.jakarta-json-path.version>
|
||||
<dependency.json-smart.version>2.5.0</dependency.json-smart.version>
|
||||
<dependency.jakarta-rpc-api.version>1.1.4</dependency.jakarta-rpc-api.version>
|
||||
|
||||
<alfresco.googledrive.version>3.4.2-A5</alfresco.googledrive.version>
|
||||
<alfresco.aos-module.version>1.6.2-A2</alfresco.aos-module.version>
|
||||
<alfresco.googledrive.version>4.0.0-M1</alfresco.googledrive.version>
|
||||
<alfresco.aos-module.version>2.0.0-M1</alfresco.aos-module.version>
|
||||
<alfresco.api-explorer.version>23.1.0-A1</alfresco.api-explorer.version> <!-- Also in alfresco-enterprise-share -->
|
||||
|
||||
<alfresco.maven-plugin.version>2.2.0</alfresco.maven-plugin.version>
|
||||
@@ -128,10 +126,10 @@
|
||||
<dependency.mysql-image.version>8</dependency.mysql-image.version>
|
||||
<dependency.mariadb.version>2.7.4</dependency.mariadb.version>
|
||||
<dependency.tas-utility.version>5.0.0</dependency.tas-utility.version>
|
||||
<dependency.rest-assured.version>5.3.1</dependency.rest-assured.version>
|
||||
<dependency.rest-assured.version>5.3.2</dependency.rest-assured.version>
|
||||
<dependency.tas-email.version>2.0.0</dependency.tas-email.version>
|
||||
<dependency.tas-webdav.version>1.20</dependency.tas-webdav.version>
|
||||
<dependency.tas-ftp.version>1.18</dependency.tas-ftp.version>
|
||||
<dependency.tas-webdav.version>1.21</dependency.tas-webdav.version>
|
||||
<dependency.tas-ftp.version>1.19</dependency.tas-ftp.version>
|
||||
<dependency.tas-dataprep.version>2.6</dependency.tas-dataprep.version>
|
||||
|
||||
<!-- AGS properties shared between community and enterprise -->
|
||||
@@ -155,7 +153,7 @@
|
||||
<connection>scm:git:https://github.com/Alfresco/alfresco-community-repo.git</connection>
|
||||
<developerConnection>scm:git:https://github.com/Alfresco/alfresco-community-repo.git</developerConnection>
|
||||
<url>https://github.com/Alfresco/alfresco-community-repo</url>
|
||||
<tag>HEAD</tag>
|
||||
<tag>23.1.0.231</tag>
|
||||
</scm>
|
||||
|
||||
<distributionManagement>
|
||||
@@ -266,12 +264,13 @@
|
||||
<dependency>
|
||||
<groupId>jakarta.json</groupId>
|
||||
<artifactId>jakarta.json-api</artifactId>
|
||||
<version>${dependency.jakarta-json-api.version}</version>
|
||||
<version>${dependency.jakarta-ee-json-api.version}</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.glassfish</groupId>
|
||||
<artifactId>jakarta.json</artifactId>
|
||||
<version>${dependency.jakarta-json-api.version}</version>
|
||||
<groupId>org.eclipse.parsson</groupId>
|
||||
<artifactId>parsson</artifactId>
|
||||
<version>${dependency.jakarta-ee-json-impl.version}</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -285,17 +284,6 @@
|
||||
<version>${dependency.json-smart.version}</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>jakarta.xml.rpc</groupId>
|
||||
<artifactId>jakarta.xml.rpc-api</artifactId>
|
||||
<version>${dependency.jakarta-rpc-api.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.sun.xml.rpc</groupId>
|
||||
<artifactId>jaxrpc-impl</artifactId>
|
||||
<version>${dependency.jakarta-rpc-api.version}</version>
|
||||
</dependency>
|
||||
|
||||
<!--CMIS-->
|
||||
<dependency>
|
||||
<groupId>org.apache.chemistry.opencmis</groupId>
|
||||
@@ -592,7 +580,7 @@
|
||||
<dependency>
|
||||
<groupId>org.yaml</groupId>
|
||||
<artifactId>snakeyaml</artifactId>
|
||||
<version>2.1</version>
|
||||
<version>2.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.fasterxml.jackson.core</groupId>
|
||||
@@ -929,21 +917,6 @@
|
||||
<version>${dependency.camel.version}</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.apache.taglibs</groupId>
|
||||
<artifactId>taglibs-standard-spec</artifactId>
|
||||
<version>${dependency.apache.taglibs.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.taglibs</groupId>
|
||||
<artifactId>taglibs-standard-impl</artifactId>
|
||||
<version>${dependency.apache.taglibs.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.taglibs</groupId>
|
||||
<artifactId>taglibs-standard-jstlel</artifactId>
|
||||
<version>${dependency.apache.taglibs.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.reflections</groupId>
|
||||
<artifactId>reflections</artifactId>
|
||||
@@ -958,7 +931,7 @@
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>1.18.28</version>
|
||||
<version>1.18.30</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
@@ -994,6 +967,16 @@
|
||||
<build>
|
||||
<pluginManagement>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.11.0</version>
|
||||
<configuration>
|
||||
<compilerArgs>
|
||||
<arg>-parameters</arg>
|
||||
</compilerArgs>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<!-- Ensure consistent maven-release-plugin version-->
|
||||
<plugin>
|
||||
<artifactId>maven-release-plugin</artifactId>
|
||||
@@ -1005,7 +988,7 @@
|
||||
<plugin>
|
||||
<groupId>io.fabric8</groupId>
|
||||
<artifactId>docker-maven-plugin</artifactId>
|
||||
<version>0.43.0</version>
|
||||
<version>0.43.4</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-surefire-plugin</artifactId>
|
||||
@@ -1062,7 +1045,7 @@
|
||||
<configuration>
|
||||
<failOnMissing>true</failOnMissing>
|
||||
<excludedScopes>provided,test</excludedScopes>
|
||||
<excludedGroups>^(org\.alfresco|com\.alfresco|org\.activiti|org\.gytheio).*</excludedGroups>
|
||||
<excludedGroups>^(org\.alfresco|com\.alfresco|org\.activiti).*</excludedGroups>
|
||||
<failIfWarning>true</failIfWarning>
|
||||
<includedLicenses>
|
||||
https://raw.githubusercontent.com/Alfresco/third-party-license-overrides/master/includedLicenses.txt
|
||||
@@ -1115,6 +1098,8 @@
|
||||
<exclude>javax.xml.ws:jaxws-api</exclude>
|
||||
<exclude>javax.mail</exclude>
|
||||
<exclude>javax.transaction</exclude>
|
||||
<exclude>*:javax.json</exclude>
|
||||
<exclude>org.glassfish:jakarta.json</exclude>
|
||||
|
||||
<!-- Enforce minimal versions of jakarta dependencies-->
|
||||
<exclude>jakarta.servlet:jakarta.servlet-api:(, 5.0.0)</exclude>
|
||||
@@ -1159,4 +1144,4 @@
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
</project>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
@@ -18,11 +18,6 @@
|
||||
</dependency>
|
||||
|
||||
<!-- Jakarta... -->
|
||||
<dependency>
|
||||
<groupId>jakarta.xml.rpc</groupId>
|
||||
<artifactId>jakarta.xml.rpc-api</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.fasterxml.jackson.core</groupId>
|
||||
<artifactId>jackson-core</artifactId>
|
||||
@@ -137,7 +132,7 @@
|
||||
<dependency>
|
||||
<groupId>org.eclipse.jetty</groupId>
|
||||
<artifactId>jetty-webapp</artifactId>
|
||||
<version>11.0.15</version>
|
||||
<version>11.0.16</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
<parent>
|
||||
<groupId>org.alfresco</groupId>
|
||||
<artifactId>alfresco-community-repo</artifactId>
|
||||
<version>23.1.0.204-SNAPSHOT</version>
|
||||
<version>23.1.0.231</version>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
@@ -560,21 +560,6 @@
|
||||
<artifactId>alfresco-sync-events</artifactId>
|
||||
<version>1.2.14</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.gytheio</groupId>
|
||||
<artifactId>gytheio-messaging-camel</artifactId>
|
||||
<version>${dependency.gytheio.version}</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>org.apache.camel</groupId>
|
||||
<artifactId>camel-core</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>org.apache.camel</groupId>
|
||||
<artifactId>camel-jackson</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.camel</groupId>
|
||||
<artifactId>camel-core</artifactId>
|
||||
@@ -726,7 +711,7 @@
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjrt</artifactId>
|
||||
<version>1.9.19</version>
|
||||
<version>${dependency.aspectj.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-net</groupId>
|
||||
@@ -746,18 +731,6 @@
|
||||
<version>${dependency.opencmis.version}</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.taglibs</groupId>
|
||||
<artifactId>taglibs-standard-spec</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.taglibs</groupId>
|
||||
<artifactId>taglibs-standard-impl</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.taglibs</groupId>
|
||||
<artifactId>taglibs-standard-jstlel</artifactId>
|
||||
</dependency>
|
||||
<!-- Repo Event Model-->
|
||||
<dependency>
|
||||
<groupId>org.alfresco</groupId>
|
||||
@@ -870,9 +843,9 @@
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>com.github.m50d</groupId>
|
||||
<groupId>org.codehaus.mojo</groupId>
|
||||
<artifactId>aspectj-maven-plugin</artifactId>
|
||||
<version>1.11.1</version>
|
||||
<version>1.14.0</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<!-- phase>process-sources</phase -->
|
||||
@@ -889,7 +862,17 @@
|
||||
<showWeaveInfo>true</showWeaveInfo>
|
||||
<source>1.8</source>
|
||||
<target>1.8</target>
|
||||
<additionalCompilerArgs>
|
||||
<arg>-parameters</arg>
|
||||
</additionalCompilerArgs>
|
||||
</configuration>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjtools</artifactId>
|
||||
<version>${dependency.aspectj.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
|
@@ -196,7 +196,7 @@ public class HierarchicalSqlSessionFactoryBean extends SqlSessionFactoryBean
|
||||
* @param plugins list of plugins
|
||||
*
|
||||
*/
|
||||
public void setPlugins(Interceptor[] plugins) {
|
||||
public void setPlugins(Interceptor... plugins) {
|
||||
this.plugins = plugins;
|
||||
}
|
||||
|
||||
@@ -244,7 +244,7 @@ public class HierarchicalSqlSessionFactoryBean extends SqlSessionFactoryBean
|
||||
*
|
||||
* @param typeHandlers Type handler list
|
||||
*/
|
||||
public void setTypeHandlers(TypeHandler<?>[] typeHandlers) {
|
||||
public void setTypeHandlers(TypeHandler<?>... typeHandlers) {
|
||||
this.typeHandlers = typeHandlers;
|
||||
}
|
||||
|
||||
@@ -255,7 +255,7 @@ public class HierarchicalSqlSessionFactoryBean extends SqlSessionFactoryBean
|
||||
*
|
||||
* @param typeAliases Type aliases list
|
||||
*/
|
||||
public void setTypeAliases(Class<?>[] typeAliases) {
|
||||
public void setTypeAliases(Class<?>... typeAliases) {
|
||||
this.typeAliases = typeAliases;
|
||||
}
|
||||
|
||||
@@ -288,7 +288,7 @@ public class HierarchicalSqlSessionFactoryBean extends SqlSessionFactoryBean
|
||||
* This property being based on Spring's resource abstraction also allows for specifying
|
||||
* resource patterns here: e.g. "classpath*:sqlmap/*-mapper.xml".
|
||||
*/
|
||||
public void setMapperLocations(Resource[] mapperLocations) {
|
||||
public void setMapperLocations(Resource... mapperLocations) {
|
||||
this.mapperLocations = mapperLocations;
|
||||
}
|
||||
|
||||
|
@@ -0,0 +1,42 @@
|
||||
/*
|
||||
* #%L
|
||||
* Alfresco Repository
|
||||
* %%
|
||||
* Copyright (C) 2005 - 2023 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 <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
package org.alfresco.messaging;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
public class LoggingDeadLetterQueue
|
||||
{
|
||||
private static final Logger LOG = LoggerFactory.getLogger(LoggingDeadLetterQueue.class);
|
||||
|
||||
public void onReceive(Object message)
|
||||
{
|
||||
if (message != null)
|
||||
{
|
||||
LOG.debug("Received:\n\n{}}\n\n", message);
|
||||
}
|
||||
}
|
||||
}
|
@@ -0,0 +1,93 @@
|
||||
/*
|
||||
* #%L
|
||||
* Alfresco Repository
|
||||
* %%
|
||||
* Copyright (C) 2005 - 2023 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 <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
package org.alfresco.messaging.jackson;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.Serial;
|
||||
import java.io.StringWriter;
|
||||
|
||||
import org.apache.commons.io.IOUtils;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonTypeInfo;
|
||||
import com.fasterxml.jackson.core.JsonParseException;
|
||||
import com.fasterxml.jackson.databind.DeserializationFeature;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import com.fasterxml.jackson.databind.SerializationFeature;
|
||||
|
||||
public class ObjectMapperFactory
|
||||
{
|
||||
private ObjectMapperFactory()
|
||||
{
|
||||
//no instantiation
|
||||
}
|
||||
|
||||
public static ObjectMapper createInstance()
|
||||
{
|
||||
QpidJsonBodyCleanerObjectMapper mapper = new QpidJsonBodyCleanerObjectMapper();
|
||||
mapper.configure(SerializationFeature.FAIL_ON_EMPTY_BEANS, false);
|
||||
mapper.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
|
||||
mapper.enableDefaultTyping(ObjectMapper.DefaultTyping.NON_FINAL, JsonTypeInfo.As.PROPERTY);
|
||||
return mapper;
|
||||
}
|
||||
|
||||
private static class QpidJsonBodyCleanerObjectMapper extends ObjectMapper
|
||||
{
|
||||
@Serial
|
||||
private static final long serialVersionUID = 2568701685293341501L;
|
||||
|
||||
private static final String DEFAULT_ENCODING = "utf8";
|
||||
|
||||
public <T> T readValue(InputStream inputStream, Class<T> valueType) throws IOException
|
||||
{
|
||||
try
|
||||
{
|
||||
// Try to unmarshal normally
|
||||
if (inputStream.markSupported())
|
||||
{
|
||||
inputStream.mark(1024 * 512);
|
||||
}
|
||||
return super.readValue(inputStream, valueType);
|
||||
}
|
||||
catch (JsonParseException e)
|
||||
{
|
||||
if (!inputStream.markSupported())
|
||||
{
|
||||
// We can't reset this stream, bail out
|
||||
throw e;
|
||||
}
|
||||
// Reset the stream
|
||||
inputStream.reset();
|
||||
}
|
||||
// Clean the message body and try again
|
||||
StringWriter writer = new StringWriter();
|
||||
IOUtils.copy(inputStream, writer, DEFAULT_ENCODING);
|
||||
String content = writer.toString();
|
||||
content = content.substring(content.indexOf('{'));
|
||||
return readValue(content, valueType);
|
||||
}
|
||||
}
|
||||
}
|
@@ -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 <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
/*
|
||||
* #%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 <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
package org.alfresco.repo.action.executer;
|
||||
|
||||
import java.io.Serializable;
|
||||
@@ -34,10 +34,10 @@ import org.alfresco.repo.action.ParameterDefinitionImpl;
|
||||
import org.alfresco.repo.admin.SysAdminParams;
|
||||
import org.alfresco.repo.jscript.ScriptAction;
|
||||
import org.alfresco.service.ServiceRegistry;
|
||||
import org.alfresco.service.cmr.action.Action;
|
||||
import org.alfresco.service.cmr.action.ActionDefinition;
|
||||
import org.alfresco.service.cmr.action.ActionService;
|
||||
import org.alfresco.service.cmr.action.ParameterConstraint;
|
||||
import org.alfresco.service.cmr.action.Action;
|
||||
import org.alfresco.service.cmr.action.ActionDefinition;
|
||||
import org.alfresco.service.cmr.action.ActionService;
|
||||
import org.alfresco.service.cmr.action.ParameterConstraint;
|
||||
import org.alfresco.service.cmr.action.ParameterDefinition;
|
||||
import org.alfresco.service.cmr.dictionary.DataTypeDefinition;
|
||||
import org.alfresco.service.cmr.repository.NodeRef;
|
||||
@@ -129,10 +129,10 @@ public class ScriptActionExecuter extends ActionExecuterAbstractBase
|
||||
if (nodeService.exists(actionedUponNodeRef))
|
||||
{
|
||||
NodeRef scriptRef = (NodeRef)action.getParameterValue(PARAM_SCRIPTREF);
|
||||
if(!isValidScriptRef(action))
|
||||
{
|
||||
throw new IllegalStateException("Invalid script ref path: " + scriptRef);
|
||||
}
|
||||
if(!isValidScriptRef(action))
|
||||
{
|
||||
throw new IllegalStateException("Invalid script ref path: " + scriptRef);
|
||||
}
|
||||
NodeRef spaceRef = this.serviceRegistry.getRuleService().getOwningNodeRef(action);
|
||||
if (spaceRef == null)
|
||||
{
|
||||
@@ -229,19 +229,22 @@ public class ScriptActionExecuter extends ActionExecuterAbstractBase
|
||||
|
||||
return companyHomeRef;
|
||||
}
|
||||
|
||||
private boolean isValidScriptRef(Action action)
|
||||
{
|
||||
NodeRef scriptRef = (NodeRef) action.getParameterValue(PARAM_SCRIPTREF);
|
||||
ActionService actionService = this.serviceRegistry.getActionService();
|
||||
ActionDefinition actDef = actionService.getActionDefinition(action.getActionDefinitionName());
|
||||
ParameterDefinition parameterDef = actDef.getParameterDefintion(PARAM_SCRIPTREF);
|
||||
String paramConstraintName = parameterDef.getParameterConstraintName();
|
||||
if (paramConstraintName != null)
|
||||
{
|
||||
ParameterConstraint paramConstraint = actionService.getParameterConstraint(paramConstraintName);
|
||||
return paramConstraint.isValidValue(scriptRef.toString());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
private boolean isValidScriptRef(Action action)
|
||||
{
|
||||
NodeRef scriptRef = (NodeRef) action.getParameterValue(PARAM_SCRIPTREF);
|
||||
ActionService actionService = this.serviceRegistry.getActionService();
|
||||
ActionDefinition actDef = actionService.getActionDefinition(action.getActionDefinitionName());
|
||||
ParameterDefinition parameterDef = actDef.getParameterDefintion(PARAM_SCRIPTREF);
|
||||
if (parameterDef != null)
|
||||
{
|
||||
String paramConstraintName = parameterDef.getParameterConstraintName();
|
||||
if (paramConstraintName != null)
|
||||
{
|
||||
ParameterConstraint paramConstraint = actionService.getParameterConstraint(paramConstraintName);
|
||||
return paramConstraint.isValidValue(scriptRef.toString());
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@@ -108,7 +108,7 @@ public class DeleteNotExistsExecutor implements StatementExecutor
|
||||
|
||||
// --DELETE_NOT_EXISTS primaryTable.key,secondaryTable1.key1,... batch.size.property
|
||||
String[] args = sql.split("[ \\t]+(?=(?:[^\"]*\"[^\"]*\")*[^\"]*$)");
|
||||
if (args.length == 3 && (args[1].indexOf('.')) != -1)
|
||||
if (args.length >= 3 && args[1].indexOf('.') != -1)
|
||||
{
|
||||
String[] tableColumnArgs = args[1].split(",(?=(?:[^\"]*\"[^\"]*\")*[^\"]*$)");
|
||||
if (tableColumnArgs.length >= 2)
|
||||
@@ -133,6 +133,10 @@ public class DeleteNotExistsExecutor implements StatementExecutor
|
||||
String timeoutSecString = globalProperties.getProperty(PROPERTY_TIMEOUT_SECONDS);
|
||||
timeoutSec = timeoutSecString == null ? -1 : Long.parseLong(timeoutSecString);
|
||||
|
||||
// Only implemented in v3. In v2 the skip is not used
|
||||
String skipToIdString = (args.length == 4) ? globalProperties.getProperty(args[3]) : null;
|
||||
Long skipToId = skipToIdString == null ? 0L : Long.parseLong(skipToIdString);
|
||||
|
||||
// Compute upper limits
|
||||
Long[] tableUpperLimits = new Long[tableColumnArgs.length];
|
||||
Pair<String, String>[] tableColumn = new Pair[tableColumnArgs.length];
|
||||
@@ -159,7 +163,7 @@ public class DeleteNotExistsExecutor implements StatementExecutor
|
||||
}
|
||||
}
|
||||
|
||||
process(tableColumn, tableUpperLimits, optionalWhereClauses);
|
||||
process(tableColumn, tableUpperLimits, optionalWhereClauses, skipToId);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -623,4 +627,10 @@ public class DeleteNotExistsExecutor implements StatementExecutor
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void process(Pair<String, String>[] tableColumn, Long[] tableUpperLimits, String[] optionalWhereClauses,
|
||||
Long skipToId) throws SQLException
|
||||
{
|
||||
process(tableColumn, tableUpperLimits, optionalWhereClauses);
|
||||
}
|
||||
}
|
||||
|
@@ -108,12 +108,19 @@ public class DeleteNotExistsV3Executor extends DeleteNotExistsExecutor
|
||||
@Override
|
||||
protected void process(Pair<String, String>[] tableColumn, Long[] tableUpperLimits, String[] optionalWhereClauses)
|
||||
throws SQLException
|
||||
{
|
||||
process(tableColumn, tableUpperLimits, optionalWhereClauses, 0L);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void process(Pair<String, String>[] tableColumn, Long[] tableUpperLimits, String[] optionalWhereClauses, Long skipToId)
|
||||
throws SQLException
|
||||
{
|
||||
String primaryTableName = tableColumn[0].getFirst();
|
||||
String primaryColumnName = tableColumn[0].getSecond();
|
||||
String primaryWhereClause = optionalWhereClauses[0];
|
||||
|
||||
Long primaryId = 0L;
|
||||
Long primaryId = skipToId;
|
||||
|
||||
deletedCount = 0L;
|
||||
startTime = new Date();
|
||||
|
@@ -74,8 +74,6 @@ import org.alfresco.util.transaction.TransactionSupportUtil;
|
||||
import org.apache.chemistry.opencmis.commons.server.CallContext;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.gytheio.messaging.MessageProducer;
|
||||
import org.gytheio.messaging.MessagingException;
|
||||
|
||||
import com.google.common.base.Splitter;
|
||||
import com.google.common.collect.Sets;
|
||||
@@ -294,7 +292,7 @@ public abstract class AbstractEventsService extends TransactionListenerAdapter
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter out event before sending them to {@link org.gytheio.messaging.MessageProducer}
|
||||
* Filter out event before sending them to {@link MessageProducer}
|
||||
*
|
||||
* @param events the events to be filtered
|
||||
*
|
||||
|
@@ -0,0 +1,57 @@
|
||||
/*
|
||||
* #%L
|
||||
* Alfresco Repository
|
||||
* %%
|
||||
* Copyright (C) 2005 - 2023 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 <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
package org.alfresco.repo.events;
|
||||
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
|
||||
import org.apache.camel.ProducerTemplate;
|
||||
|
||||
class CamelMessageProducer implements MessageProducer
|
||||
{
|
||||
private static final Map<String, Object> AMQP_HEADERS = Map.of("JMS_AMQP_MESSAGE_FORMAT", 0L);
|
||||
private final ProducerTemplate producer;
|
||||
private final String endpoint;
|
||||
|
||||
CamelMessageProducer(ProducerTemplate producer, String endpoint)
|
||||
{
|
||||
this.producer = Objects.requireNonNull(producer);
|
||||
this.endpoint = Objects.requireNonNull(endpoint);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void send(Object message)
|
||||
{
|
||||
try
|
||||
{
|
||||
producer.sendBodyAndHeaders(endpoint, message, AMQP_HEADERS);
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
throw new MessagingException("Could not send message", e);
|
||||
}
|
||||
}
|
||||
}
|
@@ -30,8 +30,6 @@ import org.alfresco.repo.security.authentication.AuthenticationUtil;
|
||||
import org.alfresco.repo.tenant.TenantUtil;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.gytheio.messaging.MessageProducer;
|
||||
import org.gytheio.messaging.MessagingException;
|
||||
|
||||
public class ExceptionEventsServiceImpl extends AbstractEventsService implements ExceptionEventsService
|
||||
{
|
||||
|
@@ -0,0 +1,37 @@
|
||||
/*
|
||||
* #%L
|
||||
* Alfresco Repository
|
||||
* %%
|
||||
* Copyright (C) 2005 - 2023 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 <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
package org.alfresco.repo.events;
|
||||
|
||||
public interface MessageProducer
|
||||
{
|
||||
/**
|
||||
* Send the given POJO message to the default queue for the producer
|
||||
*
|
||||
* @param message message to send
|
||||
* @throws MessagingException on failure
|
||||
*/
|
||||
void send(Object message) throws MessagingException;
|
||||
}
|
@@ -0,0 +1,50 @@
|
||||
/*
|
||||
* #%L
|
||||
* Alfresco Repository
|
||||
* %%
|
||||
* Copyright (C) 2005 - 2023 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 <http://www.gnu.org/licenses/>.
|
||||
* #L%
|
||||
*/
|
||||
package org.alfresco.repo.events;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.time.LocalDate;
|
||||
import java.util.concurrent.atomic.AtomicInteger;
|
||||
|
||||
public class MessagingException extends RuntimeException
|
||||
{
|
||||
@Serial
|
||||
private static final long serialVersionUID = 8192266871339806688L;
|
||||
private static final AtomicInteger ERROR_COUNTER = new AtomicInteger();
|
||||
|
||||
public MessagingException(String message, Throwable cause)
|
||||
{
|
||||
super(buildErrorLogNumber(message), cause);
|
||||
}
|
||||
|
||||
private static String buildErrorLogNumber(String message)
|
||||
{
|
||||
final LocalDate today = LocalDate.now();
|
||||
message = message == null ? "" : message;
|
||||
|
||||
return "%02d%02d%04d %s".formatted(today.getMonthValue(), today.getDayOfMonth(), ERROR_COUNTER.getAndIncrement(), message);
|
||||
}
|
||||
}
|
@@ -156,7 +156,7 @@ public class ChainingSubsystemProxyFactory extends ProxyFactoryBean
|
||||
*/
|
||||
@SuppressWarnings("rawtypes")
|
||||
@Override
|
||||
public void setInterfaces(Class[] interfaces)
|
||||
public void setInterfaces(Class... interfaces)
|
||||
{
|
||||
super.setInterfaces(interfaces);
|
||||
// Make it possible to export the object via JMX
|
||||
|
@@ -89,7 +89,7 @@ public class SubsystemProxyFactory extends ProxyFactoryBean implements Applicati
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
@Override
|
||||
public void setInterfaces(Class[] interfaces)
|
||||
public void setInterfaces(Class... interfaces)
|
||||
{
|
||||
super.setInterfaces(interfaces);
|
||||
// Make it possible to export the object via JMX
|
||||
|
@@ -1,9 +1,9 @@
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_root.id,alf_audit_app.disabled_paths_id,alf_audit_entry.audit_values_id,alf_prop_unique_ctx.prop1_id system.delete_not_exists.batchsize
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_root.id,alf_audit_app.disabled_paths_id,alf_audit_entry.audit_values_id,alf_prop_unique_ctx.prop1_id system.delete_not_exists.batchsize system.delete_not_exists.alf_prop_root.skipToId
|
||||
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_value.id,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_value.id,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize system.delete_not_exists.alf_prop_value.skipToId
|
||||
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_string_value.id,alf_prop_value.long_value."persisted_type in (3, 5, 6)",alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_string_value.id,alf_prop_value.long_value."persisted_type in (3, 5, 6)",alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize system.delete_not_exists.alf_prop_string_value.skipToId
|
||||
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_serializable_value.id,alf_prop_value.long_value.persisted_type=4,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_serializable_value.id,alf_prop_value.long_value.persisted_type=4,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize system.delete_not_exists.alf_prop_serializable_value.skipToId
|
||||
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_double_value.id,alf_prop_value.long_value.persisted_type=2,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_double_value.id,alf_prop_value.long_value.persisted_type=2,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize system.delete_not_exists.alf_prop_double_value.skipToId
|
||||
|
@@ -1,9 +1,9 @@
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_root.id,alf_audit_app.disabled_paths_id,alf_audit_entry.audit_values_id,alf_prop_unique_ctx.prop1_id system.delete_not_exists.batchsize
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_root.id,alf_audit_app.disabled_paths_id,alf_audit_entry.audit_values_id,alf_prop_unique_ctx.prop1_id system.delete_not_exists.batchsize system.delete_not_exists.alf_prop_root.skipToId
|
||||
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_value.id,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_value.id,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize system.delete_not_exists.alf_prop_value.skipToId
|
||||
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_string_value.id,alf_prop_value.long_value."persisted_type in (3, 5, 6)",alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_string_value.id,alf_prop_value.long_value."persisted_type in (3, 5, 6)",alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize system.delete_not_exists.alf_prop_string_value.skipToId
|
||||
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_serializable_value.id,alf_prop_value.long_value.persisted_type=4,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_serializable_value.id,alf_prop_value.long_value.persisted_type=4,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize system.delete_not_exists.alf_prop_serializable_value.skipToId
|
||||
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_double_value.id,alf_prop_value.long_value.persisted_type=2,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize
|
||||
--DELETE_NOT_EXISTS_V3 alf_prop_double_value.id,alf_prop_value.long_value.persisted_type=2,alf_audit_app.app_name_id,alf_audit_entry.audit_user_id,alf_prop_link.key_prop_id,alf_prop_link.value_prop_id,alf_prop_unique_ctx.value1_prop_id,alf_prop_unique_ctx.value2_prop_id,alf_prop_unique_ctx.value3_prop_id system.delete_not_exists.batchsize system.delete_not_exists.alf_prop_double_value.skipToId
|
||||
|
@@ -1254,6 +1254,12 @@ system.prop_table_cleaner.algorithm=V2
|
||||
system.delete_not_exists.pauseAndRecoverBatchSize=500000
|
||||
#Duration of the pause in milliseconds (default 10s)
|
||||
system.delete_not_exists.pauseAndRecoverTime=10000
|
||||
#Skip ids on job execution
|
||||
system.delete_not_exists.alf_prop_root.skipToId=0
|
||||
system.delete_not_exists.alf_prop_value.skipToId=0
|
||||
system.delete_not_exists.alf_prop_string_value.skipToId=0
|
||||
system.delete_not_exists.alf_prop_serializable_value.skipToId=0
|
||||
system.delete_not_exists.alf_prop_double_value.skipToId=0
|
||||
|
||||
# --Node cleanup batch - default settings
|
||||
system.node_cleanup.delete_batchSize=1000
|
||||
|
@@ -9,9 +9,9 @@
|
||||
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.0.xsd
|
||||
http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd">
|
||||
|
||||
<bean id="eventsDispatcher" class="org.gytheio.messaging.camel.CamelMessageProducer">
|
||||
<property name="producer" ref="camelProducerTemplate" />
|
||||
<property name="endpoint" value="direct:alfresco.events" />
|
||||
<bean id="eventsDispatcher" class="org.alfresco.repo.events.CamelMessageProducer">
|
||||
<constructor-arg ref="camelProducerTemplate" />
|
||||
<constructor-arg value="direct:alfresco.events" />
|
||||
</bean>
|
||||
|
||||
<bean id="eventsRegistry" class="org.alfresco.sync.events.EventRegistryImpl">
|
||||
|
@@ -11,7 +11,7 @@
|
||||
|
||||
<context:component-scan base-package="org.alfresco.messaging.camel.configuration"/>
|
||||
|
||||
<bean id="messagingObjectMapper" class="org.gytheio.messaging.jackson.ObjectMapperFactory"
|
||||
<bean id="messagingObjectMapper" class="org.alfresco.messaging.jackson.ObjectMapperFactory"
|
||||
factory-method="createInstance" />
|
||||
|
||||
<bean id="defaultDataFormat" class="org.apache.camel.component.jackson.JacksonDataFormat">
|
||||
@@ -96,6 +96,6 @@
|
||||
</bean>
|
||||
|
||||
<!-- In the default routes, this is where a message goes if no queue is specified -->
|
||||
<bean id="deadLetterQueue" class="org.gytheio.messaging.LoggingDeadLetterQueue" />
|
||||
<bean id="deadLetterQueue" class="org.alfresco.messaging.LoggingDeadLetterQueue" />
|
||||
|
||||
</beans>
|
||||
|
@@ -86,7 +86,7 @@ public class DeleteNotExistsV3ExecutorTest
|
||||
{
|
||||
scriptExecutor.executeScriptUrl("scriptexec/${db.script.dialect}/delete-not-exists/test-data1.sql");
|
||||
|
||||
String sql = "--DELETE_NOT_EXISTS_V3 temp_tst_tbl_1.id,temp_tst_tbl_2.tbl_2_id,temp_tst_tbl_3.tbl_3_id,temp_tst_tbl_4.tbl_4_id system.delete_not_exists.batchsize";
|
||||
String sql = "--DELETE_NOT_EXISTS_V3 temp_tst_tbl_1.id,temp_tst_tbl_2.tbl_2_id,temp_tst_tbl_3.tbl_3_id,temp_tst_tbl_4.tbl_4_id system.delete_not_exists.batchsize system.delete_not_exists.temp_tst_tbl_1.skipToId";
|
||||
int line = 1;
|
||||
File scriptFile = Mockito.mock(File.class);
|
||||
Properties properties = Mockito.mock(Properties.class);
|
||||
@@ -101,8 +101,8 @@ public class DeleteNotExistsV3ExecutorTest
|
||||
{
|
||||
when(properties.getProperty(DeleteNotExistsV3Executor.PROPERTY_READ_ONLY)).thenReturn("true");
|
||||
when(properties.getProperty(DeleteNotExistsV3Executor.PROPERTY_TIMEOUT_SECONDS)).thenReturn("-1");
|
||||
DeleteNotExistsV3Executor DeleteNotExistsV3Executor = createDeleteNotExistsV3Executor(dialect, connection, sql, line, scriptFile, properties);
|
||||
DeleteNotExistsV3Executor.execute();
|
||||
DeleteNotExistsV3Executor deleteNotExistsV3Executor = createDeleteNotExistsV3Executor(dialect, connection, sql, line, scriptFile, properties);
|
||||
deleteNotExistsV3Executor.execute();
|
||||
|
||||
List<String> res = jdbcTmpl.queryForList(select, String.class);
|
||||
assertEquals(7, res.size());
|
||||
@@ -117,8 +117,8 @@ public class DeleteNotExistsV3ExecutorTest
|
||||
{
|
||||
when(properties.getProperty(DeleteNotExistsV3Executor.PROPERTY_READ_ONLY)).thenReturn("false");
|
||||
when(properties.getProperty(DeleteNotExistsV3Executor.PROPERTY_TIMEOUT_SECONDS)).thenReturn("-1");
|
||||
DeleteNotExistsV3Executor DeleteNotExistsV3Executor = createDeleteNotExistsV3Executor(dialect, connection, sql, line, scriptFile, properties);
|
||||
DeleteNotExistsV3Executor.execute();
|
||||
DeleteNotExistsV3Executor deleteNotExistsV3Executor = createDeleteNotExistsV3Executor(dialect, connection, sql, line, scriptFile, properties);
|
||||
deleteNotExistsV3Executor.execute();
|
||||
|
||||
List<String> res = jdbcTmpl.queryForList(select, String.class);
|
||||
assertEquals(5, res.size());
|
||||
@@ -137,7 +137,7 @@ public class DeleteNotExistsV3ExecutorTest
|
||||
{
|
||||
scriptExecutor.executeScriptUrl("scriptexec/${db.script.dialect}/delete-not-exists/test-data1.sql");
|
||||
|
||||
String sql = "--DELETE_NOT_EXISTS_V3 temp_tst_tbl_1.id,temp_tst_tbl_2.tbl_2_id,temp_tst_tbl_3.tbl_3_id,temp_tst_tbl_4.tbl_4_id system.delete_not_exists.batchsize";
|
||||
String sql = "--DELETE_NOT_EXISTS_V3 temp_tst_tbl_1.id,temp_tst_tbl_2.tbl_2_id,temp_tst_tbl_3.tbl_3_id,temp_tst_tbl_4.tbl_4_id system.delete_not_exists.batchsize system.delete_not_exists.temp_tst_tbl_1.skipToId";
|
||||
int line = 1;
|
||||
File scriptFile = Mockito.mock(File.class);
|
||||
Properties properties = Mockito.mock(Properties.class);
|
||||
@@ -150,8 +150,8 @@ public class DeleteNotExistsV3ExecutorTest
|
||||
{
|
||||
when(properties.getProperty(DeleteNotExistsV3Executor.PROPERTY_DELETE_BATCH_SIZE)).thenReturn("1");
|
||||
when(properties.getProperty(DeleteNotExistsV3Executor.PROPERTY_READ_ONLY)).thenReturn("false");
|
||||
DeleteNotExistsV3Executor DeleteNotExistsV3Executor = createDeleteNotExistsV3Executor(dialect, connection, sql, line, scriptFile, properties);
|
||||
DeleteNotExistsV3Executor.execute();
|
||||
DeleteNotExistsV3Executor deleteNotExistsV3Executor = createDeleteNotExistsV3Executor(dialect, connection, sql, line, scriptFile, properties);
|
||||
deleteNotExistsV3Executor.execute();
|
||||
|
||||
List<String> res = jdbcTmpl.queryForList(select, String.class);
|
||||
assertEquals(5, res.size());
|
||||
@@ -170,7 +170,7 @@ public class DeleteNotExistsV3ExecutorTest
|
||||
{
|
||||
scriptExecutor.executeScriptUrl("scriptexec/${db.script.dialect}/delete-not-exists/test-data1.sql");
|
||||
|
||||
String sql = "--DELETE_NOT_EXISTS_V3 temp_tst_tbl_1.id,temp_tst_tbl_2.tbl_2_id,temp_tst_tbl_3.tbl_3_id,temp_tst_tbl_4.tbl_4_id system.delete_not_exists.batchsize";
|
||||
String sql = "--DELETE_NOT_EXISTS_V3 temp_tst_tbl_1.id,temp_tst_tbl_2.tbl_2_id,temp_tst_tbl_3.tbl_3_id,temp_tst_tbl_4.tbl_4_id system.delete_not_exists.batchsize system.delete_not_exists.temp_tst_tbl_1.skipToId";
|
||||
int line = 1;
|
||||
File scriptFile = Mockito.mock(File.class);
|
||||
Properties properties = Mockito.mock(Properties.class);
|
||||
@@ -198,4 +198,42 @@ public class DeleteNotExistsV3ExecutorTest
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Test()
|
||||
public void testSkip() throws Exception
|
||||
{
|
||||
scriptExecutor.executeScriptUrl("scriptexec/${db.script.dialect}/delete-not-exists/test-data1.sql");
|
||||
|
||||
String sql = "--DELETE_NOT_EXISTS_V3 temp_tst_tbl_1.id,temp_tst_tbl_2.tbl_2_id,temp_tst_tbl_3.tbl_3_id,temp_tst_tbl_4.tbl_4_id system.delete_not_exists.batchsize system.delete_not_exists.temp_tst_tbl_1.skipToId";
|
||||
int line = 1;
|
||||
File scriptFile = Mockito.mock(File.class);
|
||||
Properties properties = Mockito.mock(Properties.class);
|
||||
|
||||
String select = "select id from temp_tst_tbl_1 order by id ASC";
|
||||
|
||||
try (Connection connection = dataSource.getConnection())
|
||||
{
|
||||
connection.setAutoCommit(true);
|
||||
{
|
||||
when(properties.getProperty(DeleteNotExistsV3Executor.PROPERTY_BATCH_SIZE)).thenReturn("2");
|
||||
when(properties.getProperty(DeleteNotExistsV3Executor.PROPERTY_READ_ONLY)).thenReturn("false");
|
||||
when(properties.getProperty(DeleteNotExistsV3Executor.PROPERTY_TIMEOUT_SECONDS)).thenReturn("-1");
|
||||
when(properties.getProperty("system.delete_not_exists.temp_tst_tbl_1.skipToId")).thenReturn("6");
|
||||
DeleteNotExistsV3Executor deleteNotExistsV3Executor = createDeleteNotExistsV3Executor(dialect, connection, sql, line, scriptFile, properties);
|
||||
deleteNotExistsV3Executor.execute();
|
||||
|
||||
List<String> res = jdbcTmpl.queryForList(select, String.class);
|
||||
assertEquals(7, res.size());
|
||||
|
||||
// We are only processing Ids after 6, so all ids < 6 must remain untouched
|
||||
assertEquals("1", res.get(0));
|
||||
assertEquals("2", res.get(1));
|
||||
assertEquals("3", res.get(2));
|
||||
assertEquals("4", res.get(3));
|
||||
assertEquals("5", res.get(4));
|
||||
assertEquals("10", res.get(5));
|
||||
assertEquals("11", res.get(6));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -35,6 +35,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.beans.factory.config.BeanPostProcessor;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.test.annotation.DirtiesContext;
|
||||
import org.springframework.test.context.ContextConfiguration;
|
||||
import org.springframework.test.context.ContextHierarchy;
|
||||
|
||||
@@ -42,6 +43,7 @@ import org.springframework.test.context.ContextHierarchy;
|
||||
// Context hierarchy inherits context config from parent classes and extends it with TestConfig from this class
|
||||
@ContextConfiguration(classes = DirectEventGeneratorTest.TestConfig.class)
|
||||
})
|
||||
@DirtiesContext(classMode = DirtiesContext.ClassMode.BEFORE_CLASS)
|
||||
public class DirectEventGeneratorTest extends EventGeneratorTest
|
||||
{
|
||||
@Autowired
|
||||
|
@@ -27,7 +27,9 @@ package org.alfresco.repo.event2;
|
||||
|
||||
import org.junit.Test;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.test.annotation.DirtiesContext;
|
||||
|
||||
@DirtiesContext(classMode = DirtiesContext.ClassMode.BEFORE_CLASS)
|
||||
public class EnqueuingEventGeneratorTest extends EventGeneratorTest
|
||||
{
|
||||
@Autowired
|
||||
|
@@ -37,7 +37,6 @@ import jakarta.jms.Message;
|
||||
import jakarta.jms.MessageConsumer;
|
||||
import jakarta.jms.MessageListener;
|
||||
import jakarta.jms.Session;
|
||||
|
||||
import org.alfresco.model.ContentModel;
|
||||
import org.alfresco.repo.event.v1.model.RepoEvent;
|
||||
import org.alfresco.service.cmr.repository.NodeRef;
|
||||
@@ -52,9 +51,7 @@ import org.junit.After;
|
||||
import org.junit.Before;
|
||||
import org.junit.BeforeClass;
|
||||
import org.junit.Test;
|
||||
import org.springframework.test.annotation.DirtiesContext;
|
||||
|
||||
@DirtiesContext(classMode = DirtiesContext.ClassMode.BEFORE_CLASS)
|
||||
public abstract class EventGeneratorTest extends AbstractContextAwareRepoEvent
|
||||
{
|
||||
private static final String EVENT2_TOPIC_NAME = "alfresco.repo.event2";
|
||||
|
@@ -35,8 +35,8 @@ import org.junit.runners.Suite.SuiteClasses;
|
||||
DeleteRepoEventIT.class,
|
||||
ChildAssociationRepoEventIT.class,
|
||||
PeerAssociationRepoEventIT.class,
|
||||
EnqueuingEventGeneratorTest.class,
|
||||
DirectEventGeneratorTest.class,
|
||||
EnqueuingEventGeneratorTest.class,
|
||||
EventGeneratorDisabledTest.class
|
||||
})
|
||||
public class RepoEvent2ITSuite
|
||||
|
Reference in New Issue
Block a user