Ticket #808 (closed Defect: worksforme)

Opened 9 years ago

Last modified 9 years ago

4.6upgrade: Migration fails unexpectedly with unseen error message

Reported by: Malte Owned by:
Priority: Blocker Milestone: Release 4.7
Component: DeepaMehta Standard Distribution Version: 4.6.1
Keywords: Cc: jri
Complexity: 3 Area:
Module:

Description

INFORMATION: Reading migration file "/migrations/migration2.json"
Aug 15, 2015 12:04:32 AM de.deepamehta.core.impl.PluginImpl installPluginInDB
WARNUNG: ROLLBACK! (plugin "DeepaMehta 4 Sign up")
Aug 15, 2015 12:04:32 AM de.deepamehta.core.impl.PluginImpl handleEvent
SCHWERWIEGEND: Handling PLUGIN_ACTIVATED event from "de.deepamehta.workspaces" for plugin "DeepaMehta 4 Sign up" failed
java.lang.RuntimeException: Activation of plugin "DeepaMehta 4 Sign up" failed
	at de.deepamehta.core.impl.PluginImpl.activate(PluginImpl.java:515)
	at de.deepamehta.core.impl.PluginManager.activatePlugin(PluginManager.java:64)
	at de.deepamehta.core.impl.PluginImpl.checkRequirementsForActivation(PluginImpl.java:481)
	at de.deepamehta.core.impl.PluginImpl.handleEvent(PluginImpl.java:913)
	at org.apache.felix.eventadmin.impl.handler.EventHandlerProxy.sendEvent(EventHandlerProxy.java:415)
	at org.apache.felix.eventadmin.impl.tasks.SyncDeliverTasks$1.run(SyncDeliverTasks.java:145)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.RuntimeException: Installing plugin "DeepaMehta 4 Sign up" in the database failed
	at de.deepamehta.core.impl.PluginImpl.installPluginInDB(PluginImpl.java:551)
	at de.deepamehta.core.impl.PluginImpl.activate(PluginImpl.java:502)
	... 10 more
Caused by: java.lang.RuntimeException: Running migration 2 of plugin "DeepaMehta 4 Sign up" failed
	at de.deepamehta.core.impl.MigrationManager.runMigration(MigrationManager.java:145)
	at de.deepamehta.core.impl.MigrationManager.runPluginMigration(MigrationManager.java:100)
	at de.deepamehta.core.impl.MigrationManager.runPluginMigrations(MigrationManager.java:68)
	at de.deepamehta.core.impl.PluginImpl.installPluginInDB(PluginImpl.java:540)
	... 11 more
Caused by: java.lang.RuntimeException: Reading migration file "/migrations/migration2.json" failed
	at de.deepamehta.core.impl.MigrationManager.readMigrationFile(MigrationManager.java:193)
	at de.deepamehta.core.impl.MigrationManager.runMigration(MigrationManager.java:131)
	... 14 more
Caused by: java.lang.RuntimeException: Creating topic type "org.deepamehta.signup.config_tos_detail" failed (topic type (id=3191, uri="org.deepamehta.signup.config_tos_detail", value="Sign-up Configuration: ToS Detail Text", typeUri="dm4.core.topic_type", dataTypeUri="dm4.core.html", indexModes=[], assocDefs=[], labelConfig=[], view configuration {dm4.webclient.view_config=topic (id=3196, uri="", typeUri="dm4.webclient.view_config", value="", childTopics={dm4.webclient.show_in_create_menu=topic (id=3197, uri="", typeUri="dm4.webclient.show_in_create_menu", value="false", childTopics={}), relating association (id=3200, uri="", typeUri="dm4.core.composition", value="", childTopics={}, 
        topic role (roleTypeUri="dm4.core.parent", playerId=3196), 
        topic role (roleTypeUri="dm4.core.child", playerId=3197)), dm4.webclient.rows=topic (id=-1, uri="null", typeUri="dm4.webclient.rows", value="1", childTopics={}), relating association (id=-1, uri="null", typeUri="null", value="null", childTopics={}, null, null), dm4.webclient.searchable_as_unit=topic (id=3202, uri="", typeUri="dm4.webclient.searchable_as_unit", value="false", childTopics={}), relating association (id=3205, uri="", typeUri="dm4.core.composition", value="", childTopics={}, 
        topic role (roleTypeUri="dm4.core.parent", playerId=3196), 
        topic role (roleTypeUri="dm4.core.child", playerId=3202))})}))
	at de.deepamehta.core.impl.EmbeddedService.createTopicType(EmbeddedService.java:351)
	at de.deepamehta.core.impl.MigrationManager.createTopicTypes(MigrationManager.java:224)
	at de.deepamehta.core.impl.MigrationManager.readEntities(MigrationManager.java:206)
	at de.deepamehta.core.impl.MigrationManager.readMigrationFile(MigrationManager.java:186)
	... 15 more
Caused by: java.lang.RuntimeException: Storing view configuration failed (configurable=
        topic role (roleTypeUri="dm4.core.type", playerId=3191))
	at de.deepamehta.core.impl.TypeStorageImpl.storeViewConfig(TypeStorageImpl.java:703)
	at de.deepamehta.core.impl.TypeStorageImpl.storeType(TypeStorageImpl.java:185)
	at de.deepamehta.core.impl.EmbeddedService.topicTypeFactory(EmbeddedService.java:781)
	at de.deepamehta.core.impl.EmbeddedService.createTopicType(EmbeddedService.java:347)
	... 18 more
Caused by: java.lang.RuntimeException: Creating topic failed (topic (id=3196, uri="", typeUri="dm4.webclient.view_config", value="", childTopics={dm4.webclient.show_in_create_menu=topic (id=3197, uri="", typeUri="dm4.webclient.show_in_create_menu", value="false", childTopics={}), relating association (id=3200, uri="", typeUri="dm4.core.composition", value="", childTopics={}, 
        topic role (roleTypeUri="dm4.core.parent", playerId=3196), 
        topic role (roleTypeUri="dm4.core.child", playerId=3197)), dm4.webclient.rows=topic (id=-1, uri="null", typeUri="dm4.webclient.rows", value="1", childTopics={}), relating association (id=-1, uri="null", typeUri="null", value="null", childTopics={}, null, null), dm4.webclient.searchable_as_unit=topic (id=3202, uri="", typeUri="dm4.webclient.searchable_as_unit", value="false", childTopics={}), relating association (id=3205, uri="", typeUri="dm4.core.composition", value="", childTopics={}, 
        topic role (roleTypeUri="dm4.core.parent", playerId=3196), 
        topic role (roleTypeUri="dm4.core.child", playerId=3202))}))
	at de.deepamehta.core.impl.EmbeddedService.createTopic(EmbeddedService.java:718)
	at de.deepamehta.core.impl.EmbeddedService.createTopic(EmbeddedService.java:155)
	at de.deepamehta.core.impl.TypeStorageImpl.storeViewConfigTopic(TypeStorageImpl.java:708)
	at de.deepamehta.core.impl.TypeStorageImpl.storeViewConfig(TypeStorageImpl.java:700)
	... 21 more
Caused by: java.lang.RuntimeException: RelatedTopic instantiation failed (topic (id=-1, uri="null", typeUri="dm4.webclient.rows", value="1", childTopics={}), relating association (id=-1, uri="null", typeUri="null", value="null", childTopics={}, null, null))
	at de.deepamehta.core.impl.AttachedChildTopics.instantiateRelatedTopic(AttachedChildTopics.java:823)
	at de.deepamehta.core.impl.AttachedChildTopics.initAttachedObjectCache(AttachedChildTopics.java:804)
	at de.deepamehta.core.impl.AttachedChildTopics.initAttachedObjectCache(AttachedChildTopics.java:785)
	at de.deepamehta.core.impl.AttachedChildTopics.<init>(AttachedChildTopics.java:51)
	at de.deepamehta.core.impl.AttachedDeepaMehtaObject.<init>(AttachedDeepaMehtaObject.java:54)
	at de.deepamehta.core.impl.AttachedTopic.<init>(AttachedTopic.java:34)
	at de.deepamehta.core.impl.EmbeddedService.topicFactory(EmbeddedService.java:745)
	at de.deepamehta.core.impl.EmbeddedService.createTopic(EmbeddedService.java:714)
	... 24 more
Caused by: java.lang.RuntimeException: Unexpected RoleModel object (null)
	at de.deepamehta.core.impl.AttachedAssociation.createAttachedRole(AttachedAssociation.java:372)
	at de.deepamehta.core.impl.AttachedAssociation.<init>(AttachedAssociation.java:45)
	at de.deepamehta.core.impl.AttachedRelatedTopic.<init>(AttachedRelatedTopic.java:22)
	at de.deepamehta.core.impl.AttachedChildTopics.instantiateRelatedTopic(AttachedChildTopics.java:821)
	... 31 more

Type declaration (has not changed and) is the following:

 {
            "value": "Sign-up Configuration: ToS Detail Text",
            "uri": "org.deepamehta.signup.config_tos_detail",
            "data_type_uri": "dm4.core.html",
            "view_config_topics": [
                {
                    "type_uri": "dm4.webclient.view_config",
                    "childs": {
                        "dm4.webclient.show_in_create_menu": false,
                        "dm4.webclient.searchable_as_unit": false,
                        "dm4.webclient.rows": 1
                    }
                }
            ]
        },

Any ideas?
Thanks for your support!

Change History

comment:1 follow-up: ↓ 2 Changed 9 years ago by jri

In your type declaration it must be dm4.webclient.input_field_rows instead of dm4.webclient.rows.
I think this will fix your problem.
And I admit DM's error message should be more clear in this case :-)

comment:2 in reply to: ↑ 1 Changed 9 years ago by jri

Replying to jri:

In your type declaration it must be dm4.webclient.input_field_rows instead of dm4.webclient.rows.

Background: this renamed URI is since DM 4.1. But only since DM 4.6 a wrong URI causes an exception. Before 4.6 a wrong child URI was ignored. 1 is the default value for Input Field Rows anyway.

Last edited 9 years ago by jri (previous) (diff)

comment:3 Changed 9 years ago by Malte

  • Status changed from new to closed
  • Resolution set to worksforme

Thanks, that was the issue.

Note: See TracTickets for help on using tickets.