Uploader plus не работает для perticular сайта в Alfresco - PullRequest
0 голосов
/ 10 сентября 2018

У меня есть несколько сайтов на Alfresco, программа uploader plus отлично работает для других сайтов, кроме одного, выдает исключение и появляется всплывающее сообщение об ошибке «сбой операции».

Uploader Plus отлично работает для отдельных папок. но проблема возникает, когда мы применяем это к папке documentLibrary определенного веб-сайта.

Также невозможно загрузить какой-либо документ на этом конкретном сайте, что приводит к ошибке внутреннего сервера 500.

Для получения более подробной информации см. Прилагаемые снимки экрана.

Дайте мне знать, если у вас есть какое-либо решение / решение для этой проблемы.

Спасибо в Advance.enter описание изображения здесь enter image description here

upload-folder-new.post.json.ftl Код файла:

<#escape x as jsonUtils.encodeJSONString(x)>
{
"status": ${status},
"node": {
"nodeRef": "${node.nodeRef}",
"path": "${node.displayPath}\/${node.properties.name}",
"allowedTypes": []
}
}
</#escape>

Ошибка:

    2018-09-07 06:27:26,210  ERROR [extensions.webscripts.AbstractRuntime] [http-apr-8080-exec-21] Exception from executeScript: 08070089 Wrapped Exception (with status template): 08070869 Error during processing of the template 'get(properties) failed on instance of org.alfresco.repo.template.TemplateNode. See cause exception.

The failing instruction:
==> ${node.properties.name} auto-escaped  [in template "com/piridn/uploader/upload-folders-new.post.json.ftl" at line 6, column 31]'. Please contact your system administrator.
org.springframework.extensions.webscripts.WebScriptException: 08070089 Wrapped Exception (with status template): 08070869 Error during processing of the template 'get(properties) failed on instance of org.alfresco.repo.template.TemplateNode. See cause exception.

The failing instruction:
==> ${node.properties.name} auto-escaped  [in template "com/piridn/uploader/upload-folders-new.post.json.ftl" at line 6, column 31]'. Please contact your system administrator.
    at org.springframework.extensions.webscripts.AbstractWebScript.createStatusException(AbstractWebScript.java:1138)
    at org.springframework.extensions.webscripts.DeclarativeWebScript.execute(DeclarativeWebScript.java:171)
    at org.alfresco.repo.web.scripts.RepositoryContainer$3.execute(RepositoryContainer.java:519)
    at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:464)
    at org.alfresco.repo.web.scripts.RepositoryContainer.transactionedExecute(RepositoryContainer.java:587)
    at org.alfresco.repo.web.scripts.RepositoryContainer.transactionedExecuteAs(RepositoryContainer.java:656)
    at org.alfresco.repo.web.scripts.RepositoryContainer.executeScriptInternal(RepositoryContainer.java:428)
    at org.alfresco.repo.web.scripts.RepositoryContainer.executeScript(RepositoryContainer.java:308)
    at org.springframework.extensions.webscripts.AbstractRuntime.executeScript(AbstractRuntime.java:399)
    at org.springframework.extensions.webscripts.AbstractRuntime.executeScript(AbstractRuntime.java:210)
    at org.springframework.extensions.webscripts.servlet.WebScriptServlet.service(WebScriptServlet.java:132)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.alfresco.module.aosmodule.service.ContextRootFilter.doFilter(ContextRootFilter.java:93)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at net.bull.javamelody.MonitoringFilter.doFilter(MonitoringFilter.java:237)
    at net.bull.javamelody.MonitoringFilter.doFilter(MonitoringFilter.java:214)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.alfresco.repo.webdav.auth.BaseSSOAuthenticationFilter.doFilter(BaseSSOAuthenticationFilter.java:197)
    at sun.reflect.GeneratedMethodAccessor585.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.alfresco.repo.management.subsystems.ChainingSubsystemProxyFactory$1.invoke(ChainingSubsystemProxyFactory.java:119)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
    at com.sun.proxy.$Proxy156.doFilter(Unknown Source)
    at org.alfresco.repo.web.filter.beans.BeanProxyFilter.doFilter(BeanProxyFilter.java:89)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.alfresco.web.app.servlet.WebScriptSSOAuthenticationFilter.doFilter(WebScriptSSOAuthenticationFilter.java:121)
    at sun.reflect.GeneratedMethodAccessor585.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.alfresco.repo.management.subsystems.ChainingSubsystemProxyFactory$1.invoke(ChainingSubsystemProxyFactory.java:119)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
    at com.sun.proxy.$Proxy156.doFilter(Unknown Source)
    at org.alfresco.repo.web.filter.beans.BeanProxyFilter.doFilter(BeanProxyFilter.java:89)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.alfresco.web.app.servlet.WebscriptCookieAuthenticationFilter.doFilter(WebscriptCookieAuthenticationFilter.java:84)
    at sun.reflect.GeneratedMethodAccessor585.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.alfresco.repo.management.subsystems.ChainingSubsystemProxyFactory$1.invoke(ChainingSubsystemProxyFactory.java:132)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
    at com.sun.proxy.$Proxy156.doFilter(Unknown Source)
    at org.alfresco.repo.web.filter.beans.BeanProxyFilter.doFilter(BeanProxyFilter.java:89)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.alfresco.web.app.servlet.GlobalLocalizationFilter.doFilter(GlobalLocalizationFilter.java:68)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:218)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:110)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:506)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
    at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:962)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:445)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1115)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:637)
    at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.doRun(AprEndpoint.java:2549)
    at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:2538)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    at java.lang.Thread.run(Unknown Source)
Caused by: org.alfresco.service.cmr.repository.TemplateException: 08070869 Error during processing of the template 'get(properties) failed on instance of org.alfresco.repo.template.TemplateNode. See cause exception.

The failing instruction:
==> ${node.properties.name} auto-escaped  [in template "com/xyz/uploader/upload-folders-new.post.json.ftl" at line 6, column 31]'. Please contact your system administrator.
    at org.alfresco.repo.template.FreeMarkerProcessor.process(FreeMarkerProcessor.java:234)
    at org.springframework.extensions.webscripts.AbstractWebScript.renderTemplate(AbstractWebScript.java:967)
    at org.springframework.extensions.webscripts.DeclarativeWebScript.renderFormatTemplate(DeclarativeWebScript.java:267)
    at org.springframework.extensions.webscripts.DeclarativeWebScript.execute(DeclarativeWebScript.java:147)
    ... 74 more
Caused by: freemarker.template.TemplateModelException: get(properties) failed on instance of org.alfresco.repo.template.TemplateNode. See cause exception.

The failing instruction:
==> ${node.properties.name} auto-escaped  [in template "com/piridn/uploader/upload-folders-new.post.json.ftl" at line 6, column 31]
    at freemarker.ext.beans.BeanModel.get(BeanModel.java:222)
    at freemarker.core.Dot._eval(Dot.java:76)
    at freemarker.core.Expression.eval(Expression.java:111)
    at freemarker.core.Dot._eval(Dot.java:74)
    at freemarker.core.Expression.eval(Expression.java:111)
    at freemarker.core.ListLiteral.getModelList(ListLiteral.java:126)
    at freemarker.core.MethodCall._eval(MethodCall.java:94)
    at freemarker.core.Expression.eval(Expression.java:111)
    at freemarker.core.Expression.evalAndCoerceToString(Expression.java:115)
    at freemarker.core.DollarVariable.accept(DollarVariable.java:76)
    at freemarker.core.Environment.visit(Environment.java:265)
    at freemarker.core.MixedContent.accept(MixedContent.java:93)
    at freemarker.core.Environment.visit(Environment.java:265)
    at freemarker.core.EscapeBlock.accept(EscapeBlock.java:85)
    at freemarker.core.Environment.visit(Environment.java:265)
    at freemarker.core.Environment.process(Environment.java:243)
    at org.alfresco.repo.template.FreeMarkerProcessor.process(FreeMarkerProcessor.java:230)
    ... 77 more
Caused by: java.lang.reflect.InvocationTargetException
    at sun.reflect.GeneratedMethodAccessor633.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at freemarker.ext.beans.BeansWrapper.invokeMethod(BeansWrapper.java:912)
    at freemarker.ext.beans.BeanModel.invokeThroughDescriptor(BeanModel.java:275)
    at freemarker.ext.beans.BeanModel.get(BeanModel.java:182)
    ... 93 more
Caused by: java.lang.NullPointerException: Object cannot be null.
    at com.hazelcast.impl.Util.checkSerializable(Util.java:39)
    at com.hazelcast.impl.MProxyImpl.check(MProxyImpl.java:473)
    at com.hazelcast.impl.MProxyImpl.access$900(MProxyImpl.java:49)
    at com.hazelcast.impl.MProxyImpl$MProxyReal.get(MProxyImpl.java:778)
    at com.hazelcast.impl.MProxyImpl.get(MProxyImpl.java:114)
    at org.alfresco.enterprise.repo.cluster.cache.HazelcastSimpleCache.get(HazelcastSimpleCache.java:82)
    at sun.reflect.GeneratedMethodAccessor148.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.alfresco.enterprise.repo.cluster.core.ClusteredObjectProxyFactory$AbstractClusteredObjectProxyInvoker.invoke(ClusteredObjectProxyFactory.java:293)
    at org.alfresco.enterprise.repo.cluster.core.ClusteredObjectProxyFactory$CacheProxyInvoker.invoke(ClusteredObjectProxyFactory.java:204)
    at com.sun.proxy.$Proxy13.get(Unknown Source)
    at org.alfresco.repo.cache.TransactionalCache.getSharedCacheValue(TransactionalCache.java:454)
    at org.alfresco.repo.cache.TransactionalCache.get(TransactionalCache.java:641)
    at org.alfresco.repo.tagging.TagScopePropertyMethodInterceptor.getTagSummary(TagScopePropertyMethodInterceptor.java:186)
    at org.alfresco.repo.tagging.TagScopePropertyMethodInterceptor.invoke(TagScopePropertyMethodInterceptor.java:127)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.alfresco.repo.node.MLPropertyInterceptor.invoke(MLPropertyInterceptor.java:181)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.alfresco.enterprise.repo.sync.SyncPropertyInterceptor.invoke(SyncPropertyInterceptor.java:161)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.alfresco.repo.node.NodeRefPropertyMethodInterceptor.invoke(NodeRefPropertyMethodInterceptor.java:219)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
    at com.sun.proxy.$Proxy23.getProperties(Unknown Source)
    at sun.reflect.GeneratedMethodAccessor295.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:198)
    at com.sun.proxy.$Proxy23.getProperties(Unknown Source)
    at sun.reflect.GeneratedMethodAccessor295.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
    at org.alfresco.repo.audit.DisableAuditableBehaviourInterceptor.invoke(DisableAuditableBehaviourInterceptor.java:120)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at net.sf.acegisecurity.intercept.method.aopalliance.MethodSecurityInterceptor.invoke(MethodSecurityInterceptor.java:80)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.alfresco.repo.security.permissions.impl.ExceptionTranslatorMethodInterceptor.invoke(ExceptionTranslatorMethodInterceptor.java:53)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.alfresco.repo.audit.AuditMethodInterceptor.invoke(AuditMethodInterceptor.java:166)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.alfresco.repo.transaction.RetryingTransactionInterceptor$1.execute(RetryingTransactionInterceptor.java:86)
    at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:464)
    at org.alfresco.repo.transaction.RetryingTransactionInterceptor.invoke(RetryingTransactionInterceptor.java:76)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.alfresco.enterprise.repo.authorization.AuthorizationStatusInterceptor.invoke(AuthorizationStatusInterceptor.java:91)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
    at com.sun.proxy.$Proxy23.getProperties(Unknown Source)
    at org.alfresco.repo.template.TemplateNode.getProperties(TemplateNode.java:269)
    ... 99 more
2018-09-07 06:27:30,038  ERROR [solr.tracker.AbstractTracker] [org.alfresco.solr.AlfrescoCoreAdminHandler@5ed2d0e7_Worker-3] Model tracking failed
 org.alfresco.error.AlfrescoRuntimeException: 080721297 archive GetModelsDiff return status is 403
    at org.alfresco.solr.client.SOLRAPIClient.getModelsDiff(SOLRAPIClient.java:1181)
    at org.alfresco.solr.tracker.ModelTracker.trackModelsImpl(ModelTracker.java:248)
    at org.alfresco.solr.tracker.ModelTracker.trackModels(ModelTracker.java:206)
    at org.alfresco.solr.tracker.ModelTracker.ensureFirstModelSync(ModelTracker.java:228)
    at org.alfresco.solr.component.EnsureModelsComponent.prepare(EnsureModelsComponent.java:87)
    at org.apache.solr.handler.component.AlfrescoSearchHandler.handleRequestBody(AlfrescoSearchHandler.java:292)
    at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:135)
    at org.alfresco.solr.Cloud.getResponse(Cloud.java:165)
    at org.alfresco.solr.Cloud.getSolrDocumentList(Cloud.java:149)
    at org.alfresco.solr.SolrInformationServer.getDocsWithUncleanContent(SolrInformationServer.java:722)
    at org.alfresco.solr.tracker.ContentTracker.doTrack(ContentTracker.java:76)
    at org.alfresco.solr.tracker.AbstractTracker.track(AbstractTracker.java:179)
    at org.alfresco.solr.tracker.TrackerJob.execute(TrackerJob.java:54)
    at org.quartz.core.JobRunShell.run(JobRunShell.java:216)
    at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:563)

1 Ответ

0 голосов
/ 10 сентября 2018

Кажется, что имя вашего файла пустое (для меня непонятно, почему). Это может быть связано с тем, что загружаемый вами документ еще не проиндексирован.

Попробуйте использовать fileName загруженного вами файла вместо свойства name узла или защитите свою строку следующим образом:

<#escape x as jsonUtils.encodeJSONString(x)>
{
   "status": ${status},
   "node": {
     "nodeRef": "${node.nodeRef}",
     <#if node.properties.name??>
     "path": "${node.displayPath}\/${node.properties.name}",
     </#if>
     "allowedTypes": []
    }
}
</#escape>
...