Multiple occurrences of the same site

148 Views Asked by At

I'm using Alfresco Community Edition 5.0.0d and I tried to import a site made on another server with alfresco-share-import-export extension. I tried 2-3 times because I didn't see the .acp's limitation with tags and now I have duplications of the site in the site-finder.

Duplicates

They are all linked, if I delete one they are all deleted and they also share the same url.

In the repository/Sites, it appears once.

If I delete anyone of them, they are all deleted but then I can't search sites anymore and this log is generated when I try to search in the site-finder :

2016-12-14 15:25:31,101 ERROR
[org.springframework.extensions.webscripts.AbstractRuntime]
[http-apr-80-exec-56] Exception from executeScript - redirecting to status template error: 11140106 Wrapped Exception (with status
template): 11145585 Error during processing of the template 'Method "public java.lang.String org.alfresco.repo.site.script.Site.getMembersRole(java.lang.String)"
threw an exception when invoked on org.alfresco.repo.site.script.Site
object "org.alfresco.repo.site.script.Site@7803ba02". See cause exception.

The failing instruction (print stack trace for 2 more):
==> ${site.getMembersRole(userid)!""} aut...  [in template "org/alfresco/repository/site/site.lib.ftl" in macro "siteJSONManagers"
at line 44, column 22]'. Please contact your system administrator.
org.springframework.extensions.webscripts.WebScriptException: 11140106 Wrapped Exception (with status template): 11145585 Error during processing of the template 'Method "public java.lang.String org.alfresco.repo.site.script.Site.getMembersRole(java.lang.String)"
threw an exception when invoked on org.alfresco.repo.site.script.Site
object "org.alfresco.repo.site.script.Site@7803ba02". See cause exception.

The failing instruction (print stack trace for 2 more):
==> ${site.getMembersRole(userid)!""} aut...  [in template "org/alfresco/repository/site/site.lib.ftl" in macro "siteJSONManagers"
at line 44, column 22]'. Please contact your system administrator.
    at
org.springframework.extensions.webscripts.AbstractWebScript.createStatusException(AbstractWebScript.java:1127)
    at
org.springframework.extensions.webscripts.DeclarativeWebScript.execute(DeclarativeWebScript.java:171)
    at
org.alfresco.repo.web.scripts.RepositoryContainer$3.execute(RepositoryContainer.java:482)
    at
org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:457)
    at
org.alfresco.repo.web.scripts.RepositoryContainer.transactionedExecute(RepositoryContainer.java:551)
    at
org.alfresco.repo.web.scripts.RepositoryContainer.transactionedExecuteAs(RepositoryContainer.java:619)
    at
org.alfresco.repo.web.scripts.RepositoryContainer.executeScriptInternal(RepositoryContainer.java:399)
    at
org.alfresco.repo.web.scripts.RepositoryContainer.executeScript(RepositoryContainer.java:280)
    at
org.springframework.extensions.webscripts.AbstractRuntime.executeScript(AbstractRuntime.java:378)
    at
org.springframework.extensions.webscripts.AbstractRuntime.executeScript(AbstractRuntime.java:209)
    at
org.springframework.extensions.webscripts.servlet.WebScriptServlet.service(WebScriptServlet.java:132)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
    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.web.app.servlet.GlobalLocalizationFilter.doFilter(GlobalLocalizationFilter.java:61)
    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:220)
    at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)
    at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:504)
    at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)
    at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
    at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950)
    at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
    at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:421)
    at
org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1074)
    at
org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611)
    at
org.apache.tomcat.util.net.AprEndpoint$SocketWithOptionsProcessor.run(AprEndpoint.java:2403)
    at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at
org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    at java.lang.Thread.run(Thread.java:745)
Caused by: org.alfresco.service.cmr.repository.TemplateException:
11145585 Error during processing of the template 'Method "public java.lang.String org.alfresco.repo.site.script.Site.getMembersRole(java.lang.String)"
threw an exception when invoked on org.alfresco.repo.site.script.Site
object "org.alfresco.repo.site.script.Site@7803ba02". See cause exception.

The failing instruction (print stack trace for 2 more):
==> ${site.getMembersRole(userid)!""} aut...  [in template "org/alfresco/repository/site/site.lib.ftl" in macro "siteJSONManagers"
at line 44, column 22]'. Please contact your system administrator.
    at
org.alfresco.repo.template.FreeMarkerProcessor.process(FreeMarkerProcessor.java:221)
    at
org.springframework.extensions.webscripts.AbstractWebScript.renderTemplate(AbstractWebScript.java:955)
    at
org.springframework.extensions.webscripts.DeclarativeWebScript.renderFormatTemplate(DeclarativeWebScript.java:267)
    at
org.springframework.extensions.webscripts.DeclarativeWebScript.execute(DeclarativeWebScript.java:147)
    ... 33 more
Caused by: freemarker.template.TemplateModelException: Method "public java.lang.String org.alfresco.repo.site.script.Site.getMembersRole(java.lang.String)"
threw an exception when invoked on org.alfresco.repo.site.script.Site
object "org.alfresco.repo.site.script.Site@7803ba02". See cause exception.

The failing instruction (print stack trace for 2 more):
==> ${site.getMembersRole(userid)!""} aut...  [in template "org/alfresco/repository/site/site.lib.ftl" in macro "siteJSONManagers"
at line 44, column 22]
    at
freemarker.ext.beans.SimpleMethodModel.exec(SimpleMethodModel.java:135)
        at freemarker.core.MethodCall._eval(MethodCall.java:98)
        at freemarker.core.Expression.eval(Expression.java:111)
        at
freemarker.core.DefaultToExpression._eval(DefaultToExpression.java:116)
        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.IfBlock.accept(IfBlock.java:84)
        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.MixedContent.accept(MixedContent.java:93)
        at freemarker.core.Environment.visit(Environment.java:265)
        at freemarker.core.Macro$Context.runMacro(Macro.java:209)
        at freemarker.core.Environment.visit(Environment.java:694)
        at freemarker.core.UnifiedCall.accept(UnifiedCall.java:116)
        at freemarker.core.Environment.visit(Environment.java:265)
        at freemarker.core.MixedContent.accept(MixedContent.java:93)
        at
freemarker.core.Environment.visitByHiddingParent(Environment.java:286)
        at
freemarker.core.IteratorBlock$Context.runLoop(IteratorBlock.java:193)
        at
freemarker.core.Environment.visitIteratorBlock(Environment.java:509)
        at freemarker.core.IteratorBlock.accept(IteratorBlock.java:103)
        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.Environment.process(Environment.java:243)
        at
org.alfresco.repo.template.FreeMarkerProcessor.process(FreeMarkerProcessor.java:217)
        ... 36 more
Caused by: org.alfresco.repo.site.SiteDoesNotExistException: 11145584 Site veille-documentaire does not exist.
        at
org.alfresco.repo.site.SiteServiceImpl.getPermissionGroups(SiteServiceImpl.java:2297)
        at
org.alfresco.repo.site.SiteServiceImpl.getMembersRoles(SiteServiceImpl.java:2270)
        at
org.alfresco.repo.site.SiteServiceImpl.getMembersRole(SiteServiceImpl.java:2245)
        at sun.reflect.GeneratedMethodAccessor1051.invoke(Unknown Source)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:483)
        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
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:46)
        at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
        at
org.alfresco.repo.audit.AuditMethodInterceptor.invoke(AuditMethodInterceptor.java:159)
        at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
        at
org.alfresco.repo.transaction.CheckTransactionAdvice.invoke(CheckTransactionAdvice.java:47)
        at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
        at
org.alfresco.repo.transaction.RetryingTransactionAdvice$1.execute(RetryingTransactionAdvice.java:64)
        at
org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:457)
        at
org.alfresco.repo.transaction.RetryingTransactionAdvice.invoke(RetryingTransactionAdvice.java:67)
        at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
        at
org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
        at com.sun.proxy.$Proxy102.getMembersRole(Unknown Source)
        at org.alfresco.repo.site.script.Site.getMembersRole(Site.java:425)
        at sun.reflect.GeneratedMethodAccessor1050.invoke(Unknown Source)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:483)
        at
freemarker.ext.beans.BeansWrapper.invokeMethod(BeansWrapper.java:912)
        at
freemarker.ext.beans.SimpleMethodModel.exec(SimpleMethodModel.java:107)
        ... 70 more

If I create a new site with the exact same name, search works again but I also have again three times the same site...

How could I cleanup the site's list ?

1

There are 1 best solutions below

1
On BEST ANSWER

Looks like it is having issue with indexing in solr4. I was facing this same issue for content.

You can find similar thread on Alfresco forum :

https://community.alfresco.com/thread/212341-solved-duplicate-node-index-in-alfresco-5

They have also created issue in JIRA.

https://issues.alfresco.com/jira/browse/MNT-13767

It is fixed in 5.0.2 version.