Uploaded image for project: 'Magnolia'
  1. Magnolia
  2. MAGNOLIA-6598

NPE at SetupModuleRepositoriesTask.grantRepositoryToSuperuser

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Duplicate
    • Affects Version/s: 5.4, 5.4.5
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      Occasionally I have following exception, during Magnolia modules installation, and Magnolia fails to start:

      [2016-03-14_15:39:24.275] [Thread-24] ERROR i.m.module.InstallContextImpl - [68/364 tasks - Magnolia Resource Loader (version 5.4.5)]> Could not install or update resource-loader module. Task 'Setup module repositories' failed. (NullPointerException: )
      info.magnolia.module.delta.TaskExecutionException: Could not bootstrap workspace: null
      	at info.magnolia.module.delta.SetupModuleRepositoriesTask.execute(SetupModuleRepositoriesTask.java:91) ~[magnolia-core-5.4.5.jar:na]
      	at info.magnolia.module.ModuleManagerImpl.applyDeltas(ModuleManagerImpl.java:531) [magnolia-core-5.4.5.jar:na]
      	at info.magnolia.module.ModuleManagerImpl.installOrUpdateModule(ModuleManagerImpl.java:513) [magnolia-core-5.4.5.jar:na]
      	at info.magnolia.module.ModuleManagerImpl$1.doExec(ModuleManagerImpl.java:288) [magnolia-core-5.4.5.jar:na]
      	at info.magnolia.context.MgnlContext$VoidOp.exec(MgnlContext.java:421) [magnolia-core-5.4.5.jar:na]
      	at info.magnolia.context.MgnlContext$VoidOp.exec(MgnlContext.java:418) [magnolia-core-5.4.5.jar:na]
      	at info.magnolia.context.MgnlContext.doInSystemContext(MgnlContext.java:392) [magnolia-core-5.4.5.jar:na]
      	at info.magnolia.module.ModuleManagerImpl.performInstallOrUpdate(ModuleManagerImpl.java:282) [magnolia-core-5.4.5.jar:na]
      	at info.magnolia.module.ui.ModuleManagerWebUI$2.run(ModuleManagerWebUI.java:123) [magnolia-core-5.4.5.jar:na]
      	at java.lang.Thread.run(Thread.java:745) [na:1.8.0_72]
      Caused by: java.lang.NullPointerException: null
      	at info.magnolia.module.delta.SetupModuleRepositoriesTask.grantRepositoryToSuperuser(SetupModuleRepositoriesTask.java:99) ~[magnolia-core-5.4.5.jar:na]
      	at info.magnolia.module.delta.SetupModuleRepositoriesTask.execute(SetupModuleRepositoriesTask.java:86) ~[magnolia-core-5.4.5.jar:na]
      	... 9 common frames omitted
      

      It looks like a data race between modules installation and RoleManager creation: when SetupModuleRepositoriesTask tries to retrieve RoleManager sometimes it hasn't created yet.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              aifgi Alexey Ivanov
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: