Merge branch 'feature/RM-7066_UpdateToACS62' into 'master'

Resolve RM-7066 "Feature/ updatetoacs62"

Closes RM-7066

See merge request records-management/records-management!1314
This commit is contained in:
Rodica Sutu
2019-12-05 08:33:56 +00:00
71 changed files with 196 additions and 123 deletions

View File

@@ -531,8 +531,8 @@
<alfresco.db.username>alfresco</alfresco.db.username>
<alfresco.groupId>org.alfresco</alfresco.groupId>
<alfresco.share.artifactId>share</alfresco.share.artifactId>
<alfresco-spring-webscripts.version>7.8</alfresco-spring-webscripts.version>
<api.explorer.version>6.1.0</api.explorer.version>
<alfresco-spring-webscripts.version>7.9</alfresco-spring-webscripts.version>
<api.explorer.version>6.2.0</api.explorer.version>
<!-- Set this here and override it in the community and enterprise modules. -->
<alfresco.version>0.0</alfresco.version>
@@ -559,7 +559,7 @@
<maven.tomcat.port>8080</maven.tomcat.port>
<jackson.version>2.9.9</jackson.version>
<jackson-databind.version>2.9.9.3</jackson-databind.version>
<jackson-databind.version>2.9.10</jackson-databind.version>
<fabric8.docker.version>0.31.0</fabric8.docker.version>
<mockito.version>1.10.19</mockito.version>
<postgresql.version>42.2.6</postgresql.version>

View File

@@ -75,8 +75,8 @@
<properties>
<spring.version>5.1.8.RELEASE</spring.version>
<alfresco.version>6.1.2-ga</alfresco.version>
<share.version>6.1.0</share.version>
<alfresco.version>6.2.0-ga</alfresco.version>
<share.version>6.2.0</share.version>
<!-- The properties app.amp.* need to be set for share to work. -->
<app.filtering.enabled>true</app.filtering.enabled>
</properties>

View File

@@ -1,3 +1,6 @@
SOLR6_TAG=1.1.1
POSTGRES_TAG=10.1
ACTIVEMQ_TAG=5.15.6
TRANSFORMERS_TAG=2.1.0
SOLR6_TAG=1.4.0
POSTGRES_TAG=11.4
ACTIVEMQ_TAG=5.15.8
LEGACY_TRANSFORM_SERVICE_ENABLED=true
LOCAL_TRANSFORM_SERVICE_ENABLED=true

View File

@@ -1,4 +1,9 @@
FROM alfresco/alfresco-content-repository-community:6.1.2-ga
### Apply AGS community repo AMP to ACS image
FROM alfresco/alfresco-content-repository-community:6.2.0-ga
# Alfresco user does not have permissions to modify webapps or configuration. Switch to root.
# The access will be fixed after all operations are done.
USER root
COPY target/alfresco-governance-services-community-repo-*.amp /usr/local/tomcat/amps/
@@ -10,4 +15,13 @@ COPY target/gs-api-explorer-*.war /usr/local/tomcat/webapps/
### Unpack gs-api-explorer.war
RUN mkdir /usr/local/tomcat/webapps/gs-api-explorer && cd /usr/local/tomcat/webapps/gs-api-explorer && \
jar -xvf /usr/local/tomcat/webapps/gs-api-explorer-*.war && rm -f /usr/local/tomcat/webapps/gs-api-explorer-*.war
jar -xvf /usr/local/tomcat/webapps/gs-api-explorer-*.war && rm -f /usr/local/tomcat/webapps/gs-api-explorer-*.war
# All files in the tomcat folder must be owned by root user and Alfresco group as mentioned in the parent Dockerfile
RUN chgrp -R Alfresco /usr/local/tomcat && \
find /usr/local/tomcat/webapps -type d -exec chmod 0750 {} \; && \
find /usr/local/tomcat/webapps -type f -exec chmod 0640 {} \; && \
chmod -R g+r /usr/local/tomcat/webapps
# Switching back to alfresco user after having added amps files to run the container as non-root
USER alfresco

View File

@@ -38,7 +38,7 @@ rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getChildByName
rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getChildrenByName=RM.Read.0,AFTER_RM.FilterNode
rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getPrimaryParent=RM.Read.0
rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.createAssociation=RM.Assoc.0.1
rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.removeAssociation=Assoc.0.1
rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.removeAssociation=RM.Assoc.0.1
rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getTargetAssocs=RM.Read.0
rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getSourceAssocs=RM.Read.0
rm.methodsecurity.org.alfresco.service.cmr.repository.NodeService.getAssoc=RM.Read.0

View File

@@ -22,21 +22,71 @@ services:
-Dindex.subsystem.name=solr6
-Dalfresco.restApi.basicAuthScheme=true
-Dimap.server.enabled=true
-Dimap.server.port=1143
-Dftp.enabled=true
-Dftp.port=1221
-Dftp.dataPortFrom=30000
-Dftp.dataPortTo=30099
-Dshare.host=localhost
-Daos.baseUrlOverwrite=http://localhost:8080/alfresco/aos
-Dmessaging.broker.url=\"failover:(tcp://activemq:61616)?timeout=3000&jms.useCompression=true\"
-Dlocal.transform.service.enabled=${LOCAL_TRANSFORM_SERVICE_ENABLED}
-DlocalTransform.pdfrenderer.url=http://alfresco-pdf-renderer:8090/
-DlocalTransform.imagemagick.url=http://imagemagick:8090/
-DlocalTransform.libreoffice.url=http://libreoffice:8090/
-DlocalTransform.tika.url=http://tika:8090/
-DlocalTransform.misc.url=http://transform-misc:8090/
-Dlegacy.transform.service.enabled=${LEGACY_TRANSFORM_SERVICE_ENABLED}
-Dalfresco-pdf-renderer.url=http://alfresco-pdf-renderer:8090/
-Djodconverter.url=http://libreoffice:8090/
-Dimg.url=http://imagemagick:8090/
-Dtika.url=http://tika:8090/
-Dtransform.misc.url=http://transform-misc:8090/
"
ports:
- 8080:8080
- 8000:8000
- 445:445
- 143:143
- "21:21"
- 1143:1143
- "21:1221"
- "30000-30099:30000-30099"
alfresco-pdf-renderer:
image: alfresco/alfresco-pdf-renderer:${TRANSFORMERS_TAG}
environment:
JAVA_OPTS: " -Xms256m -Xmx256m"
ports:
- 8090:8090
imagemagick:
image: alfresco/alfresco-imagemagick:${TRANSFORMERS_TAG}
environment:
JAVA_OPTS: " -Xms256m -Xmx256m"
ports:
- 8091:8090
libreoffice:
image: alfresco/alfresco-libreoffice:${TRANSFORMERS_TAG}
environment:
JAVA_OPTS: " -Xms256m -Xmx256m"
ports:
- 8092:8090
tika:
image: alfresco/alfresco-tika:${TRANSFORMERS_TAG}
environment:
JAVA_OPTS: " -Xms256m -Xmx256m"
ports:
- 8093:8090
transform-misc:
image: alfresco/alfresco-transform-misc:${TRANSFORMERS_TAG}
environment:
JAVA_OPTS: " -Xms256m -Xmx256m"
ports:
- 8094:8090
postgres:
image: library/postgres:${POSTGRES_TAG}
environment:
@@ -57,6 +107,8 @@ services:
- SOLR_SOLR_PORT=8983
#Create the default alfresco and archive cores
- SOLR_CREATE_ALFRESCO_DEFAULTS=alfresco,archive
#HTTP by default
- ALFRESCO_SECURE_COMMS=none
ports:
- 8083:8983 #Browser port

View File

@@ -24,11 +24,11 @@
<alfresco.repo.artifactId>alfresco-platform</alfresco.repo.artifactId>
<alfresco.postgres.version>9.1-901.jdbc4</alfresco.postgres.version>
<ags.artifactId>alfresco-governance-services-community-repo</ags.artifactId>
<!-- 6.1.2-ga changes -->
<dependency.alfresco-core.version>7.5.1</dependency.alfresco-core.version>
<dependency.alfresco-repository.version>7.33.12</dependency.alfresco-repository.version>
<dependency.alfresco-remote-api.version>7.34.1</dependency.alfresco-remote-api.version>
<alfresco.alfresco-share-services.version>6.1.0</alfresco.alfresco-share-services.version>
<!-- 6.2.0-ga changes -->
<dependency.alfresco-core.version>7.22</dependency.alfresco-core.version>
<dependency.alfresco-repository.version>7.134.1</dependency.alfresco-repository.version>
<dependency.alfresco-remote-api.version>7.107.1</dependency.alfresco-remote-api.version>
<alfresco.alfresco-share-services.version>6.2.0</alfresco.alfresco-share-services.version>
<image.name>alfresco/alfresco-governance-repository-community</image.name>
<maven.javadoc.skip>false</maven.javadoc.skip>

View File

@@ -27,7 +27,7 @@
package org.alfresco.module.org_alfresco_module_rm.caveat;
import static org.apache.commons.lang.exception.ExceptionUtils.getFullStackTrace;
import static org.apache.commons.lang3.exception.ExceptionUtils.getStackTrace;
import java.io.File;
import java.io.InputStream;
@@ -44,6 +44,7 @@ import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReadWriteLock;
import java.util.concurrent.locks.ReentrantReadWriteLock;
import net.sf.acegisecurity.AccessDeniedException;
import org.alfresco.error.AlfrescoRuntimeException;
import org.alfresco.model.ContentModel;
import org.alfresco.module.org_alfresco_module_rm.caveat.RMListOfValuesConstraint.MatchLogic;
@@ -81,8 +82,6 @@ import org.apache.commons.logging.LogFactory;
import org.json.JSONException;
import org.json.JSONObject;
import net.sf.acegisecurity.AccessDeniedException;
/**
* RM Caveat Config component impl
*
@@ -1042,7 +1041,7 @@ public class RMCaveatConfigComponentImpl implements ContentServicePolicies.OnCon
sb.append("' to the JSONObject 'listMembers' '");
sb.append(listMembers);
sb.append("': ");
sb.append(getFullStackTrace(error));
sb.append(getStackTrace(error));
throw new AlfrescoRuntimeException(sb.toString());
}
}
@@ -1061,7 +1060,7 @@ public class RMCaveatConfigComponentImpl implements ContentServicePolicies.OnCon
sb.append("' to the JSONObject 'configJSONObject' '");
sb.append(configJSONObject);
sb.append("': ");
sb.append(getFullStackTrace(error));
sb.append(getStackTrace(error));
throw new AlfrescoRuntimeException(sb.toString());
}
}

View File

@@ -39,7 +39,7 @@ import org.alfresco.service.cmr.dictionary.ConstraintException;
import org.alfresco.service.cmr.i18n.MessageLookup;
import org.alfresco.service.cmr.repository.datatype.DefaultTypeConverter;
import org.alfresco.service.cmr.repository.datatype.TypeConversionException;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.I18NUtil;
/**

View File

@@ -36,7 +36,7 @@ import java.util.Map;
import java.util.Set;
import org.alfresco.service.cmr.security.AuthorityService;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.json.JSONArray;
import org.json.JSONObject;

View File

@@ -27,7 +27,7 @@
package org.alfresco.module.org_alfresco_module_rm.action;
import static org.apache.commons.lang.StringUtils.leftPad;
import static org.apache.commons.lang3.StringUtils.leftPad;
import java.io.Serializable;
import java.util.HashSet;
@@ -683,7 +683,7 @@ public abstract class RMActionExecuterAbstractBase extends PropertySubActionExe
*
* @return padded string or the original if already at &gt;= len characters
*
* @deprecated As of 2.1, replaced by {@link org.apache.commons.lang.StringUtils#leftPad(String, int)}
* @deprecated As of 2.1, replaced by {@link org.apache.commons.lang3.StringUtils#leftPad(String, int)}
*/
@Deprecated
protected String padString(String s, int len)

View File

@@ -37,7 +37,7 @@ import org.alfresco.service.cmr.action.Action;
import org.alfresco.service.cmr.action.ParameterDefinition;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

View File

@@ -43,7 +43,7 @@ import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.security.AccessStatus;
import org.alfresco.service.cmr.version.Version;
import org.alfresco.service.namespace.QName;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
/**
* Destroy action.

View File

@@ -31,7 +31,7 @@ import org.alfresco.error.AlfrescoRuntimeException;
import org.alfresco.module.org_alfresco_module_rm.action.RMActionExecuterAbstractBase;
import org.alfresco.service.cmr.action.Action;
import org.alfresco.service.cmr.repository.NodeRef;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.I18NUtil;
/**

View File

@@ -42,7 +42,7 @@ import org.alfresco.service.cmr.action.Action;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.security.AccessStatus;
import org.alfresco.service.namespace.QName;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.I18NUtil;
/**

View File

@@ -45,7 +45,7 @@ import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.workflow.WorkflowService;
import org.alfresco.service.namespace.QName;
import org.alfresco.workflow.RMWorkflowModel;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

View File

@@ -27,7 +27,7 @@
package org.alfresco.module.org_alfresco_module_rm.action.impl;
import static org.apache.commons.lang.StringUtils.isBlank;
import static org.apache.commons.lang3.StringUtils.isBlank;
import java.io.IOException;
import java.io.InputStream;

View File

@@ -33,6 +33,7 @@ import static org.alfresco.model.ContentModel.PROP_USERNAME;
import static org.alfresco.module.org_alfresco_module_rm.audit.event.UserGroupMembershipUtils.PARENT_GROUP;
import static org.alfresco.module.org_alfresco_module_rm.dod5015.DOD5015Model.TYPE_DOD_5015_SITE;
import static org.alfresco.module.org_alfresco_module_rm.model.rma.type.RmSiteType.DEFAULT_SITE_NAME;
import static org.apache.commons.lang3.StringEscapeUtils.escapeHtml4;
import static org.apache.commons.lang3.StringUtils.isBlank;
import java.io.BufferedWriter;
@@ -92,8 +93,8 @@ import org.alfresco.util.PropertyCheck;
import org.alfresco.util.PropertyMap;
import org.alfresco.util.TempFileProvider;
import org.alfresco.util.transaction.TransactionListenerAdapter;
import org.apache.commons.lang.StringEscapeUtils;
import org.apache.commons.lang.time.DateUtils;
import org.apache.commons.lang3.StringEscapeUtils;
import org.apache.commons.lang3.time.DateUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.json.JSONArray;
@@ -1356,29 +1357,29 @@ public class RecordsManagementAuditServiceImpl extends AbstractLifecycleBean
writer.write("<span class=\"label\">From:</span>");
writer.write("<span class=\"value\">");
Date from = params.getDateFrom();
writer.write(from == null ? "&lt;Not Set&gt;" : StringEscapeUtils.escapeHtml(from.toString()));
writer.write(from == null ? "&lt;Not Set&gt;" : escapeHtml4(from.toString()));
writer.write("</span>");
writer.write("<span class=\"label\">To:</span>");
writer.write("<span class=\"value\">");
Date to = params.getDateTo();
writer.write(to == null ? "&lt;Not Set&gt;" : StringEscapeUtils.escapeHtml(to.toString()));
writer.write(to == null ? "&lt;Not Set&gt;" : escapeHtml4(to.toString()));
writer.write("</span>");
writer.write("<span class=\"label\">Property:</span>");
writer.write("<span class=\"value\">");
QName prop = params.getProperty();
writer.write(prop == null ? "All" : StringEscapeUtils.escapeHtml(getPropertyLabel(prop)));
writer.write(prop == null ? "All" : escapeHtml4(getPropertyLabel(prop)));
writer.write("</span>");
writer.write("<span class=\"label\">User:</span>");
writer.write("<span class=\"value\">");
writer.write(params.getUser() == null ? "All" : StringEscapeUtils.escapeHtml(params.getUser()));
writer.write(params.getUser() == null ? "All" : escapeHtml4(params.getUser()));
writer.write("</span>");
writer.write("<span class=\"label\">Event:</span>");
writer.write("<span class=\"value\">");
writer.write(params.getEvent() == null ? "All" : StringEscapeUtils.escapeHtml(getAuditEventLabel(params.getEvent())));
writer.write(params.getEvent() == null ? "All" : escapeHtml4(getAuditEventLabel(params.getEvent())));
writer.write("</span>\n");
writer.write("</div>\n");
@@ -1420,26 +1421,26 @@ public class RecordsManagementAuditServiceImpl extends AbstractLifecycleBean
writer.write("<div class=\"audit-entry-header\">");
writer.write("<span class=\"label\">Timestamp:</span>");
writer.write("<span class=\"value\">");
writer.write(StringEscapeUtils.escapeHtml(entry.getTimestamp().toString()));
writer.write(escapeHtml4(entry.getTimestamp().toString()));
writer.write("</span>");
writer.write("<span class=\"label\">User:</span>");
writer.write("<span class=\"value\">");
writer.write(entry.getFullName() != null ?
StringEscapeUtils.escapeHtml(entry.getFullName()) :
StringEscapeUtils.escapeHtml(entry.getUserName()));
escapeHtml4(entry.getFullName()) :
escapeHtml4(entry.getUserName()));
writer.write("</span>");
if (entry.getUserRole() != null && entry.getUserRole().length() > 0)
{
writer.write("<span class=\"label\">Role:</span>");
writer.write("<span class=\"value\">");
writer.write(StringEscapeUtils.escapeHtml(entry.getUserRole()));
writer.write(escapeHtml4(entry.getUserRole()));
writer.write("</span>");
}
if (entry.getEvent() != null && entry.getEvent().length() > 0)
{
writer.write("<span class=\"label\">Event:</span>");
writer.write("<span class=\"value\">");
writer.write(StringEscapeUtils.escapeHtml(getAuditEventLabel(entry.getEvent())));
writer.write(escapeHtml4(getAuditEventLabel(entry.getEvent())));
writer.write("</span>\n");
}
writer.write("</div>\n");
@@ -1448,14 +1449,14 @@ public class RecordsManagementAuditServiceImpl extends AbstractLifecycleBean
{
writer.write("<span class=\"label\">Identifier:</span>");
writer.write("<span class=\"value\">");
writer.write(StringEscapeUtils.escapeHtml(entry.getIdentifier()));
writer.write(escapeHtml4(entry.getIdentifier()));
writer.write("</span>");
}
if (entry.getNodeType() != null && entry.getNodeType().length() > 0)
{
writer.write("<span class=\"label\">Type:</span>");
writer.write("<span class=\"value\">");
writer.write(StringEscapeUtils.escapeHtml(entry.getNodeType()));
writer.write(escapeHtml4(entry.getNodeType()));
writer.write("</span>");
}
if (entry.getPath() != null && entry.getPath().length() > 0)
@@ -1475,7 +1476,7 @@ public class RecordsManagementAuditServiceImpl extends AbstractLifecycleBean
writer.write("<span class=\"label\">Location:</span>");
writer.write("<span class=\"value\">");
writer.write(StringEscapeUtils.escapeHtml(displayPath));
writer.write(escapeHtml4(displayPath));
writer.write("</span>");
}
writer.write("</div>\n");
@@ -1503,17 +1504,17 @@ public class RecordsManagementAuditServiceImpl extends AbstractLifecycleBean
if(DataTypeDefinition.MLTEXT.equals(propDataType))
{
writer.write(values.getFirst() == null ? "&lt;none&gt;" : StringEscapeUtils.escapeHtml(convertToMlText((Map)values.getFirst()).getDefaultValue()));
writer.write(values.getFirst() == null ? "&lt;none&gt;" : escapeHtml4(convertToMlText((Map) values.getFirst()).getDefaultValue()));
writer.write("</td><td>");
writer.write(values.getSecond() == null ? "&lt;none&gt;" : StringEscapeUtils.escapeHtml(convertToMlText((Map)values.getSecond()).getDefaultValue()));
writer.write(values.getSecond() == null ? "&lt;none&gt;" : escapeHtml4(convertToMlText((Map) values.getSecond()).getDefaultValue()));
}
else
{
Serializable oldValue = values.getFirst();
writer.write(oldValue == null ? "&lt;none&gt;" : StringEscapeUtils.escapeHtml(oldValue.toString()));
writer.write(oldValue == null ? "&lt;none&gt;" : escapeHtml4(oldValue.toString()));
writer.write("</td><td>");
Serializable newValue = values.getSecond();
writer.write(newValue == null ? "&lt;none&gt;" : StringEscapeUtils.escapeHtml(newValue.toString()));
writer.write(newValue == null ? "&lt;none&gt;" : escapeHtml4(newValue.toString()));
}
writer.write("</td></tr>");

View File

@@ -31,7 +31,7 @@ import org.alfresco.api.AlfrescoPublicApi;
import org.alfresco.module.org_alfresco_module_rm.audit.RecordsManagementAuditService;
import org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementModel;
import org.alfresco.util.ParameterCheck;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.I18NUtil;
/**

View File

@@ -31,7 +31,7 @@ import org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementModel;
import org.alfresco.module.org_alfresco_module_rm.security.RMMethodSecurityInterceptor;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.security.AccessStatus;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.I18NUtil;
import net.sf.acegisecurity.vote.AccessDecisionVoter;

View File

@@ -27,7 +27,7 @@
package org.alfresco.module.org_alfresco_module_rm.capability;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.I18NUtil;
/**

View File

@@ -64,7 +64,7 @@ import org.alfresco.service.cmr.search.LimitBy;
import org.alfresco.service.cmr.search.PermissionEvaluationMode;
import org.alfresco.service.cmr.search.ResultSet;
import org.aopalliance.intercept.MethodInvocation;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.beans.factory.InitializingBean;

View File

@@ -44,7 +44,7 @@ import org.alfresco.module.org_alfresco_module_rm.util.TransactionalResourceHelp
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.namespace.NamespacePrefixResolver;
import org.aopalliance.intercept.MethodInvocation;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.beans.factory.InitializingBean;

View File

@@ -27,7 +27,7 @@
package org.alfresco.module.org_alfresco_module_rm.dataset;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.I18NUtil;
public class DataSetBase implements DataSet

View File

@@ -53,7 +53,7 @@ import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.alfresco.service.transaction.TransactionService;
import org.alfresco.util.ParameterCheck;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.json.JSONArray;

View File

@@ -53,7 +53,7 @@ import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.namespace.QName;
import org.alfresco.service.transaction.TransactionService;
import org.alfresco.util.ParameterCheck;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.I18NUtil;
/**

View File

@@ -67,7 +67,7 @@ import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.alfresco.util.PathUtil;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang.ArrayUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.json.simple.JSONArray;
import org.json.simple.JSONObject;

View File

@@ -51,7 +51,7 @@ import org.alfresco.repo.security.authentication.AuthenticationUtil.RunAsWork;
import org.alfresco.service.cmr.repository.ChildAssociationRef;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.namespace.QName;
import org.apache.commons.lang.ArrayUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.springframework.extensions.surf.util.I18NUtil;
/**

View File

@@ -58,7 +58,7 @@ import org.alfresco.service.cmr.site.SiteInfo;
import org.alfresco.service.cmr.site.SiteService;
import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.util.ParameterCheck;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.extensions.surf.util.I18NUtil;

View File

@@ -122,8 +122,8 @@ import org.alfresco.util.EqualsHelper;
import org.alfresco.util.Pair;
import org.alfresco.util.ParameterCheck;
import org.alfresco.util.PropertyMap;
import org.apache.commons.lang.ArrayUtils;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.extensions.surf.util.I18NUtil;

View File

@@ -32,7 +32,7 @@ import static org.alfresco.module.org_alfresco_module_rm.model.RecordsManagement
import static org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementModel.PROP_ORIGIONAL_NAME;
import static org.alfresco.module.org_alfresco_module_rm.record.RecordUtils.appendIdentifierToName;
import static org.alfresco.util.ParameterCheck.mandatory;
import static org.apache.commons.lang.StringUtils.isNotBlank;
import static org.apache.commons.lang3.StringUtils.isNotBlank;
import java.io.Serializable;
import java.util.HashMap;

View File

@@ -30,7 +30,7 @@ package org.alfresco.module.org_alfresco_module_rm.recordableversion;
import static org.alfresco.module.org_alfresco_module_rm.version.RecordableVersionPolicy.NONE;
import static org.alfresco.util.ParameterCheck.mandatory;
import static org.alfresco.util.ParameterCheck.mandatoryString;
import static org.apache.commons.lang.StringUtils.isNotBlank;
import static org.apache.commons.lang3.StringUtils.isNotBlank;
import java.util.ArrayList;
import java.util.List;

View File

@@ -30,7 +30,7 @@ package org.alfresco.module.org_alfresco_module_rm.relationship;
import static org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementModel.ASPECT_FROZEN;
import static org.alfresco.util.ParameterCheck.mandatory;
import static org.alfresco.util.ParameterCheck.mandatoryString;
import static org.apache.commons.lang.StringUtils.isBlank;
import static org.apache.commons.lang3.StringUtils.isBlank;
import java.util.HashSet;
import java.util.List;

View File

@@ -54,7 +54,7 @@ import org.alfresco.service.cmr.repository.StoreRef;
import org.alfresco.service.cmr.repository.TemplateService;
import org.alfresco.service.namespace.QName;
import org.alfresco.util.UrlUtil;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.I18NUtil;
/**

View File

@@ -43,7 +43,7 @@ import org.alfresco.service.cmr.repository.ChildAssociationRef;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.namespace.QName;
import org.alfresco.service.namespace.RegexQNamePattern;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
/**
* Transfer report generator.

View File

@@ -54,7 +54,7 @@ import org.alfresco.service.cmr.security.AuthorityService;
import org.alfresco.service.cmr.security.AuthorityType;
import org.alfresco.service.cmr.security.PermissionService;
import org.alfresco.util.ParameterCheck;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;

View File

@@ -37,7 +37,7 @@ import org.alfresco.module.org_alfresco_module_rm.recordfolder.RecordFolderServi
import org.alfresco.repo.content.MimetypeMap;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.util.ParameterCheck;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.json.JSONException;

View File

@@ -28,7 +28,7 @@
package org.alfresco.module.org_alfresco_module_rm.script;
import static org.alfresco.util.WebScriptUtils.getStringValueFromJSONObject;
import static org.apache.commons.lang.StringUtils.isBlank;
import static org.apache.commons.lang3.StringUtils.isBlank;
import org.alfresco.module.org_alfresco_module_rm.relationship.RelationshipDisplayName;
import org.alfresco.module.org_alfresco_module_rm.relationship.RelationshipService;

View File

@@ -35,7 +35,7 @@ import org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementModel;
import org.alfresco.module.org_alfresco_module_rm.model.rma.type.RmSiteType;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.site.SiteService;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.extensions.webscripts.Cache;

View File

@@ -37,7 +37,7 @@ import org.alfresco.module.org_alfresco_module_rm.dataset.DataSetService;
import org.alfresco.module.org_alfresco_module_rm.model.rma.type.RmSiteType;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.site.SiteService;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.webscripts.Cache;
import org.springframework.extensions.webscripts.DeclarativeWebScript;
import org.springframework.extensions.webscripts.Status;

View File

@@ -27,6 +27,7 @@
package org.alfresco.module.org_alfresco_module_rm.script;
import javax.servlet.http.HttpServletResponse;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
@@ -39,8 +40,6 @@ import java.util.HashMap;
import java.util.List;
import java.util.Map;
import javax.servlet.http.HttpServletResponse;
import org.alfresco.model.ContentModel;
import org.alfresco.module.org_alfresco_module_rm.action.RecordsManagementActionService;
import org.alfresco.module.org_alfresco_module_rm.disposition.DispositionSchedule;
@@ -56,7 +55,7 @@ import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.alfresco.service.namespace.RegexQNamePattern;
import org.alfresco.util.TempFileProvider;
import org.apache.commons.lang.StringEscapeUtils;
import org.apache.commons.lang3.StringEscapeUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.json.JSONException;
@@ -292,7 +291,7 @@ public class TransferReportPost extends BaseTransferWebScript
writer.write("<table cellpadding=\"3\" cellspacing=\"3\">");
writer.write("<tr><td class=\"label\">Transfer Date:</td><td>");
Date transferDate = (Date)this.nodeService.getProperty(transferNode, ContentModel.PROP_CREATED);
writer.write(StringEscapeUtils.escapeHtml(transferDate.toString()));
writer.write(StringEscapeUtils.escapeHtml4(transferDate.toString()));
writer.write("</td></tr>");
writer.write("<tr><td class=\"label\">Transfer Location:</td><td>");
if (isAccession)
@@ -301,16 +300,16 @@ public class TransferReportPost extends BaseTransferWebScript
}
else
{
writer.write(StringEscapeUtils.escapeHtml((String)this.nodeService.getProperty(transferNode,
writer.write(StringEscapeUtils.escapeHtml4((String)this.nodeService.getProperty(transferNode,
RecordsManagementModel.PROP_TRANSFER_LOCATION)));
}
writer.write("</td></tr>");
writer.write("<tr><td class=\"label\">Performed By:</td><td>");
writer.write(StringEscapeUtils.escapeHtml((String)this.nodeService.getProperty(transferNode,
writer.write(StringEscapeUtils.escapeHtml4((String)this.nodeService.getProperty(transferNode,
ContentModel.PROP_CREATOR)));
writer.write("</td></tr>");
writer.write("<tr><td class=\"label\">Disposition Authority:</td><td>");
writer.write(dispositionAuthority != null ? StringEscapeUtils.escapeHtml(dispositionAuthority) : "");
writer.write(dispositionAuthority != null ? StringEscapeUtils.escapeHtml4(dispositionAuthority) : "");
writer.write("</td></tr></table>\n");
writer.write("<h2>Transferred Items</h2>\n");
@@ -361,10 +360,10 @@ public class TransferReportPost extends BaseTransferWebScript
throws IOException
{
writer.write("<span class=\"nodeName\">");
writer.write(StringEscapeUtils.escapeHtml((String)this.nodeService.getProperty(folderNode,
writer.write(StringEscapeUtils.escapeHtml4((String)this.nodeService.getProperty(folderNode,
ContentModel.PROP_NAME)));
writer.write("</span>&nbsp;(Unique Folder Identifier:&nbsp;");
writer.write(StringEscapeUtils.escapeHtml((String)this.nodeService.getProperty(folderNode,
writer.write(StringEscapeUtils.escapeHtml4((String)this.nodeService.getProperty(folderNode,
RecordsManagementModel.PROP_IDENTIFIER)));
writer.write(")\n");
@@ -399,10 +398,10 @@ public class TransferReportPost extends BaseTransferWebScript
{
writer.write("<div class=\"record\">\n");
writer.write(" <span class=\"nodeName\">");
writer.write(StringEscapeUtils.escapeHtml((String)this.nodeService.getProperty(recordNode,
writer.write(StringEscapeUtils.escapeHtml4((String)this.nodeService.getProperty(recordNode,
ContentModel.PROP_NAME)));
writer.write("</span>&nbsp;(Unique Record Identifier:&nbsp;");
writer.write(StringEscapeUtils.escapeHtml((String)this.nodeService.getProperty(recordNode,
writer.write(StringEscapeUtils.escapeHtml4((String)this.nodeService.getProperty(recordNode,
RecordsManagementModel.PROP_IDENTIFIER)));
writer.write(")");
@@ -410,10 +409,10 @@ public class TransferReportPost extends BaseTransferWebScript
{
Date declaredOn = (Date)this.nodeService.getProperty(recordNode, RecordsManagementModel.PROP_DECLARED_AT);
writer.write(" declared by ");
writer.write(StringEscapeUtils.escapeHtml((String)this.nodeService.getProperty(recordNode,
writer.write(StringEscapeUtils.escapeHtml4((String)this.nodeService.getProperty(recordNode,
RecordsManagementModel.PROP_DECLARED_BY)));
writer.write(" on ");
writer.write(StringEscapeUtils.escapeHtml(declaredOn.toString()));
writer.write(StringEscapeUtils.escapeHtml4(declaredOn.toString()));
}
writer.write("\n</div>\n");

View File

@@ -27,7 +27,7 @@
package org.alfresco.module.org_alfresco_module_rm.script.admin;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.json.JSONException;
import org.json.JSONObject;
import org.springframework.extensions.webscripts.DeclarativeWebScript;

View File

@@ -35,7 +35,7 @@ import org.alfresco.module.org_alfresco_module_rm.event.RecordsManagementEvent;
import org.alfresco.module.org_alfresco_module_rm.event.RecordsManagementEventService;
import org.alfresco.util.GUID;
import org.alfresco.util.ParameterCheck;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.json.JSONException;
import org.json.JSONObject;
import org.json.JSONTokener;

View File

@@ -31,7 +31,7 @@ import java.util.HashMap;
import java.util.Map;
import org.alfresco.service.cmr.repository.NodeRef;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.webscripts.Cache;
import org.springframework.extensions.webscripts.Status;
import org.springframework.extensions.webscripts.WebScriptException;

View File

@@ -39,7 +39,7 @@ import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.StoreRef;
import org.alfresco.service.cmr.security.AuthorityService;
import org.alfresco.service.cmr.security.AuthorityType;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.webscripts.DeclarativeWebScript;
import org.springframework.extensions.webscripts.WebScriptRequest;

View File

@@ -41,7 +41,7 @@ import org.alfresco.module.org_alfresco_module_rm.fileplan.FilePlanService;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.StoreRef;
import org.alfresco.service.cmr.security.AccessStatus;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.webscripts.Cache;
import org.springframework.extensions.webscripts.DeclarativeWebScript;
import org.springframework.extensions.webscripts.Status;

View File

@@ -43,7 +43,7 @@ import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.service.cmr.repository.StoreRef;
import org.alfresco.service.cmr.security.AccessStatus;
import org.alfresco.service.cmr.security.PermissionService;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.webscripts.Cache;
import org.springframework.extensions.webscripts.DeclarativeWebScript;
import org.springframework.extensions.webscripts.Status;

View File

@@ -53,8 +53,8 @@ import org.alfresco.service.cmr.site.SiteService;
import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.alfresco.util.Pair;
import org.apache.commons.lang.ArrayUtils;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.extensions.webscripts.Cache;

View File

@@ -34,7 +34,7 @@ import static org.alfresco.repo.policy.annotation.BehaviourKind.CLASS;
import static org.alfresco.repo.security.authentication.AuthenticationUtil.getSystemUserName;
import static org.alfresco.service.cmr.security.OwnableService.NO_OWNER;
import static org.alfresco.util.ParameterCheck.mandatory;
import static org.apache.commons.lang.BooleanUtils.isTrue;
import static org.apache.commons.lang3.BooleanUtils.isTrue;
import java.io.Serializable;
import java.util.HashMap;

View File

@@ -55,7 +55,7 @@ import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.alfresco.service.namespace.RegexQNamePattern;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.I18NUtil;
import org.springframework.extensions.surf.util.ParameterCheck;

View File

@@ -27,7 +27,7 @@
package org.alfresco.module.org_alfresco_module_rm.util;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
/**
* Utility class that contains validation not present in {@link org.alfresco.util.ParameterCheck}.

View File

@@ -64,7 +64,7 @@ import org.alfresco.service.namespace.QName;
import org.alfresco.util.Pair;
import org.alfresco.util.ParameterCheck;
import org.alfresco.util.PropertyMap;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.extensions.surf.util.I18NUtil;

View File

@@ -34,7 +34,7 @@ import java.util.List;
import org.alfresco.error.AlfrescoRuntimeException;
import org.alfresco.service.cmr.repository.NodeRef;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
/**
* Date parameter processor.

View File

@@ -45,7 +45,7 @@ import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.apache.commons.lang.ArrayUtils;
import org.apache.commons.lang3.ArrayUtils;
/**
* Node parameter processor.

View File

@@ -27,7 +27,7 @@
package org.alfresco.repo.security.permissions.impl;
import static org.apache.commons.lang.StringUtils.isNotBlank;
import static org.apache.commons.lang3.StringUtils.isNotBlank;
import java.io.Serializable;
import java.util.Arrays;
@@ -57,7 +57,7 @@ import org.alfresco.service.cmr.security.OwnableService;
import org.alfresco.service.cmr.security.PermissionService;
import org.alfresco.util.Pair;
import org.alfresco.util.PropertyCheck;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.context.ApplicationEvent;

View File

@@ -29,7 +29,7 @@ package org.alfresco.repo.web.scripts.dictionary;
import org.alfresco.service.cmr.site.SiteInfo;
import org.alfresco.service.cmr.site.SiteService;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.webscripts.WebScriptRequest;
/**

View File

@@ -31,7 +31,7 @@ import java.util.Map;
import org.alfresco.module.org_alfresco_module_rm.script.admin.RoleDeclarativeWebScript;
import org.alfresco.service.cmr.repository.NodeRef;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.webscripts.Status;
import org.springframework.extensions.webscripts.WebScriptException;
import org.springframework.extensions.webscripts.WebScriptRequest;

View File

@@ -44,6 +44,7 @@
*/
package org.alfresco.repo.web.scripts.roles;
import javax.servlet.http.HttpServletResponse;
import java.io.BufferedWriter;
import java.io.File;
import java.io.FileWriter;
@@ -58,8 +59,6 @@ import java.util.List;
import java.util.Map;
import java.util.Set;
import javax.servlet.http.HttpServletResponse;
import org.alfresco.model.ContentModel;
import org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementModel;
import org.alfresco.module.org_alfresco_module_rm.security.ExtendedReaderDynamicAuthority;
@@ -79,7 +78,7 @@ import org.alfresco.service.namespace.QName;
import org.alfresco.service.transaction.TransactionService;
import org.alfresco.util.Pair;
import org.alfresco.util.TempFileProvider;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.extensions.webscripts.AbstractWebScript;

View File

@@ -44,7 +44,7 @@ import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.service.cmr.repository.StoreRef;
import org.alfresco.service.cmr.security.AccessStatus;
import org.alfresco.service.namespace.QName;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.webscripts.Cache;
import org.springframework.extensions.webscripts.DeclarativeWebScript;
import org.springframework.extensions.webscripts.Status;

View File

@@ -100,7 +100,7 @@ import org.alfresco.service.cmr.usage.ContentQuotaException;
import org.alfresco.service.namespace.QName;
import org.alfresco.util.Pair;
import org.alfresco.util.ParameterCheck;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

View File

@@ -31,7 +31,7 @@ import java.util.Map;
import org.alfresco.rest.framework.core.exceptions.InvalidArgumentException;
import org.alfresco.service.namespace.QName;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.surf.util.Content;
import org.springframework.extensions.webscripts.servlet.FormData;

View File

@@ -42,7 +42,7 @@ import org.alfresco.service.cmr.repository.ChildAssociationRef;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.util.ParameterCheck;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
/**
* Util class for the request info workflow

View File

@@ -42,7 +42,7 @@ import org.alfresco.module.org_alfresco_module_rm.test.util.CommonRMTestUtils;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.namespace.QName;
import org.alfresco.util.GUID;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.junit.Before;
/**

View File

@@ -43,7 +43,7 @@ import org.alfresco.repo.content.MimetypeMap;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.namespace.QName;
import org.apache.commons.io.IOUtils;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.webscripts.GUID;

View File

@@ -82,6 +82,10 @@ public class DeclareAsRecordVersionTest extends RecordableVersionsBaseTest
versionProperties.put(Version.PROP_DESCRIPTION, DESCRIPTION);
versionProperties.put(VersionModel.PROP_VERSION_TYPE, VersionType.MINOR);
//remove the content property as ContentPropertyRestrictionInterceptor will not allow update of
// content property via NodeService.addProperties
nodeService.removeProperty(dmDocument, ContentModel.PROP_CONTENT);
// create version
versionService.createVersion(dmDocument, versionProperties);
@@ -184,7 +188,9 @@ public class DeclareAsRecordVersionTest extends RecordableVersionsBaseTest
versionProperties = new HashMap<>(2);
versionProperties.put(Version.PROP_DESCRIPTION, DESCRIPTION);
versionProperties.put(VersionModel.PROP_VERSION_TYPE, VersionType.MINOR);
//remove the content property as ContentPropertyRestrictionInterceptor will not allow update of
// content property via NodeService.addProperties
nodeService.removeProperty(customDocument, PROP_CONTENT);
// create version
versionService.createVersion(customDocument, versionProperties);

View File

@@ -33,7 +33,7 @@ import org.alfresco.repo.content.MimetypeMap;
import org.alfresco.repo.security.authentication.AuthenticationUtil;
import org.alfresco.service.cmr.action.Action;
import org.alfresco.service.cmr.repository.NodeRef;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.extensions.webscripts.GUID;
/**

View File

@@ -32,7 +32,7 @@ import java.io.Serializable;
import org.alfresco.module.org_alfresco_module_rm.test.util.BaseRMTestCase;
import org.alfresco.repo.jscript.app.JSONConversionComponent;
import org.alfresco.service.cmr.repository.NodeRef;
import org.apache.commons.lang.ArrayUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.json.JSONException;
import org.json.JSONObject;

View File

@@ -46,7 +46,7 @@ import org.alfresco.repo.content.MimetypeMap;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.namespace.QName;
import org.alfresco.util.GUID;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
/**
* Report service implementation unit test.

View File

@@ -65,7 +65,7 @@ import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.context.ApplicationContext;
/**

View File

@@ -4,7 +4,7 @@
# Version label
version.major=6
version.minor=1
version.minor=2
version.revision=0
version.label=

View File

@@ -50,7 +50,7 @@ import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.security.AccessStatus;
import org.alfresco.service.cmr.security.OwnableService;
import org.alfresco.util.Pair;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.junit.Test;
import org.mockito.InjectMocks;
import org.mockito.Mock;