cancel
Showing results for 
Search instead for 
Did you mean: 

Full repository import (restore) throws dictionary exception

bpeters
Champ in-the-making
Champ in-the-making
Hi,

When I try to execute a full repository import using the boorstrap restore I receive an exception (system cannot locate apsect-root in the repository dictionary, see exception below).

I am using Alfresco 2.1.0 and tried to execute the restore with both the war and tomcat distributions. I am using a fresh install (removed alf_data and created a new alfresco database in MySQL).

In previous versions (1.4) I never had problems doing a restore. Is something changed? Am I missing something, or is this a known problem?

Thanks in advance for any help.


09:11:40,002 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Created store: user://alfrescoUserStore
09:11:40,042 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Importing alfresco/extension/restore/export_users.acp
09:11:41,234 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Import started at Wed Aug 01 09:11:41 CEST 2007 (1185952301234)
09:11:41,244 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Import completed at Wed Aug 01 09:11:41 CEST 2007 (1185952301244)
09:11:41,244 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Error occured at Wed Aug 01 09:11:41 CEST 2007 (1185952301244)
09:11:41,244 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Exception: org.alfresco.service.cmr.view.ImporterException: Failed to import package at line 11; column 24 due to error: Aspect name {http://www.alfresco.org/model/system/1.0}aspect_root is not valid; cannot find in Repository dictionary
09:11:41,244 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Import duration: 10 ms (Note: excluding commit time)
09:11:41,244 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Nodes created: 0
09:11:41,244 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Nodes linked: 0
09:11:41,244 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Aspects Added: 0
09:11:41,244 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Properties set: 0
09:11:41,244 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Content set: 0
09:11:41,244 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Permissions set: 0
09:11:41,294 ERROR [org.springframework.web.context.ContextLoader] Context initialization failed
org.alfresco.error.AlfrescoRuntimeException: Bootstrap failed
   at org.alfresco.repo.importer.ImporterBootstrap.bootstrap(ImporterBootstrap.java:444)
   at org.alfresco.repo.importer.ImporterBootstrap.onBootstrap(ImporterBootstrap.java:666)
   at org.alfresco.util.AbstractLifecycleBean.onApplicationEvent(AbstractLifecycleBean.java:62)
   at org.springframework.context.event.SimpleApplicationEventMulticaster$1.run(SimpleApplicationEventMulticaster.java:77)
   at org.springframework.core.task.SyncTaskExecutor.execute(SyncTaskExecutor.java:49)
   at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:75)
   at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:241)
   at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:349)
   at org.springframework.web.context.support.AbstractRefreshableWebApplicationContext.refresh(AbstractRefreshableWebApplicationContext.java:156)
   at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:246)
   at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:184)
   at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)
   at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3763)
   at org.apache.catalina.core.StandardContext.start(StandardContext.java:4211)
   at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
   at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
   at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
   at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:809)
   at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:698)
   at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:472)
   at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1122)
   at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
   at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
   at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
   at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
   at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
   at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
   at org.apache.catalina.core.StandardService.start(StandardService.java:450)
   at org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
   at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:585)
   at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
   at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432)
Caused by: org.alfresco.service.cmr.view.ImporterException: Failed to import package at line 11; column 24 due to error: Aspect name {http://www.alfresco.org/model/system/1.0}aspect_root is not valid; cannot find in Repository dictionary
   at org.alfresco.repo.importer.view.ViewParser.parse(ViewParser.java:190)
   at org.alfresco.repo.importer.ImporterComponent.parserImport(ImporterComponent.java:360)
   at org.alfresco.repo.importer.ImporterComponent.importView(ImporterComponent.java:235)
   at org.alfresco.repo.importer.ImporterBootstrap.bootstrap(ImporterBootstrap.java:430)
   … 35 more
Caused by: org.alfresco.service.cmr.view.ImporterException: Aspect name {http://www.alfresco.org/model/system/1.0}aspect_root is not valid; cannot find in Repository dictionary
   at org.alfresco.repo.importer.view.ViewParser.processStartElement(ViewParser.java:309)
   at org.alfresco.repo.importer.view.ViewParser.parse(ViewParser.java:176)
   … 38 more
34 REPLIES 34

derek
Star Contributor
Star Contributor
Hi,

That is a valid aspect and should be found in WEB-INF/classes/alfresco/model/systemModel.xml.

Regards

bpeters
Champ in-the-making
Champ in-the-making
Thanks for your reply,

I know it is part of the Repository dictionary, therefore I expected it to be already available.

Bas

kosumi
Champ in-the-making
Champ in-the-making
i too encountered this exact error, could someone provide a more specific instruction to solve this? TIA

derek
Star Contributor
Star Contributor
Could you confirm that the model is there and that the aspect is defined.

Regards

bpeters
Champ in-the-making
Champ in-the-making
I tried again today, but still receive the same exception.

I deleted alf_data
I dropped the alfresco database and created a new one using the db_setup script
The war is in the Tomcat webapps and contains the Dictionary model (it is the regular 2.1 community war edition).
I used the example restore from the extension examples
The files are in restore folder under extension in tomcat shared/classes/alfresco

Alfresco is able to find the import files since the import starts.

there is no custom model or any other kind of customization involved.

derek
Star Contributor
Star Contributor
So, the aspect is in systemModel.xml?  This is not something we've encountered as yet.  What are your system details?

davidc
Star Contributor
Star Contributor
Can you uncomment…

log4j.logger.org.alfresco.repo.dictionary.DictionaryDAO=info

in log4j.properties.

This will let us know if systemModel is being registered.

gilles
Champ in-the-making
Champ in-the-making
Struggling with the same error,
here is an extract of the logs I get (having uncommented 'log4j.logger.org.alfresco.repo.dictionary.DictionaryDAO=info'):



11:25:23,124 INFO  [repo.dictionary.DictionaryDAO] Loading model from alfresco/model/dictionaryModel.xml
11:25:23,202 INFO  [repo.dictionary.DictionaryDAO] Registered model d:dictionary
11:25:23,202 INFO  [repo.dictionary.DictionaryDAO] Registered namespace '' (prefix '')
11:25:23,202 INFO  [repo.dictionary.DictionaryDAO] Registered namespace 'http://www.alfresco.org' (prefix 'alf')
11:25:23,202 INFO  [repo.dictionary.DictionaryDAO] Registered namespace 'http://www.alfresco.org/model/dictionary/1.0' (
prefix 'd')
11:25:23,202 INFO  [repo.dictionary.DictionaryDAO] Registered namespace 'http://www.alfresco.org/view/repository/1.0' (p
refix 'view')
11:25:23,218 INFO  [repo.dictionary.DictionaryDAO] Loading model from alfresco/model/systemModel.xml
11:25:23,265 INFO  [repo.dictionary.DictionaryDAO] Registered model sys:systemmodel
11:25:23,265 INFO  [repo.dictionary.DictionaryDAO] Registered namespace 'http://www.alfresco.org/model/system/1.0' (pref
ix 'sys')
11:25:23,265 INFO  [repo.dictionary.DictionaryDAO] Registered namespace 'http://www.alfresco.org/system/registry/1.0' (p
refix 'reg')
11:25:23,265 INFO  [repo.dictionary.DictionaryDAO] Registered namespace 'http://www.alfresco.org/system/modules/1.0' (pr
efix 'module')
11:25:23,265 INFO  [repo.dictionary.DictionaryDAO] Loading model from org/alfresco/repo/security/authentication/userMode
l.xml
11:25:23,296 INFO  [repo.dictionary.DictionaryDAO] Registered model usr:usermodel
11:25:23,296 INFO  [repo.dictionary.DictionaryDAO] Registered namespace 'http://www.alfresco.org/model/user/1.0' (prefix
'usr')
(I also import a custom model but the bootstrap is dealing with that later, and I don't thing it the cause of the error.)
Thanks in advance,
Gilles

schneika
Champ in-the-making
Champ in-the-making
I have the same error while 2.0-Export to 2.1.0-Import, the Full Repository Import is not possible:

15:28:46,821 WARN  [org.springframework.remoting.rmi.RmiRegistryFactoryBean] Could not detect RMI registry - creating new one
15:28:50,609 WARN  [org.alfresco.util.OpenOfficeConnectionTester] A connection to OpenOffice could not be established.
15:28:56,358 INFO  [org.alfresco.repo.domain.schema.SchemaBootstrap] Schema managed by database dialect org.hibernate.dialect.MySQLInnoDBDialect.
15:28:56,570 INFO  [org.alfresco.repo.domain.schema.SchemaBootstrap] Executing database script /opt/alfresco/tomcat/temp/Alfresco/AlfrescoSchemaCreate-org.hibernate.dialect.MySQLInnoDBDialect-52838.sql (Generated).
15:29:15,462 INFO  [org.alfresco.repo.domain.schema.SchemaBootstrap] Executing database script /opt/alfresco/tomcat/temp/Alfresco/AlfrescoSchemaUpdate-org.hibernate.dialect.MySQLInnoDBDialect-52839.sql (Copied from classpath:alfresco/dbscripts/create/2.1/org.hibernate.dialect.MySQLInnoDBDialect/AlfrescoPostCreate-2.1-FKIndexes.sql).
15:29:15,551 INFO  [org.alfresco.repo.domain.schema.SchemaBootstrap] All executed statements written to file /opt/alfresco/tomcat/temp/Alfresco/AlfrescoSchemaUpdate-All_Statements-52840.sql.
15:29:17,024 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Created store: user://alfrescoUserStore
15:29:17,038 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Importing alfresco/extension/restore/export_users.acp
15:29:17,403 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Import started at Mon Aug 13 15:29:17 CEST 2007 (1187011757401)
15:29:17,413 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Import completed at Mon Aug 13 15:29:17 CEST 2007 (1187011757413)
15:29:17,414 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Error occured at Mon Aug 13 15:29:17 CEST 2007 (1187011757413)
15:29:17,414 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Exception: org.alfresco.service.cmr.view.ImporterException: Failed to import package at line 11; column 24 due to error: Aspect name {http://www.alfresco.org/model/system/1.0}aspect_root is not valid; cannot find in Repository dictionary
15:29:17,414 DEBUG [org.alfresco.repo.importer.ImporterBootstrap] Import duration: 12 ms (Note: excluding commit time)
15:29:17,414 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Nodes created: 0
15:29:17,414 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Nodes linked: 0
15:29:17,415 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Aspects Added: 0
15:29:17,415 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Properties set: 0
15:29:17,415 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Content set: 0
15:29:17,415 DEBUG [org.alfresco.repo.importer.ImporterBootstrap]  Permissions set: 0
15:29:17,544 ERROR [org.springframework.web.context.ContextLoader] Context initialization failed