ApplicationModuleLoader applicationModuleLoader = new ApplicationModuleLoader();
registry.addItem("spring-"+ModuleTypes.APPLICATION, applicationModuleLoader);
DefaultApplicationContextLoader contextLoader = new DefaultApplicationContextLoader();
contextLoader.setModuleLoaderRegistry(registry);
contextLoader.setDelegatingContextLoaderRegistry(new DelegatingContextLoaderRegistry());
TransitionProcessorRegistry transitionProcessors = new TransitionProcessorRegistry();
LoadTransitionProcessor loadTransitionProcessor = new LoadTransitionProcessor();
SpringModuleRuntime moduleRuntime = new SpringModuleRuntime();
moduleRuntime.setApplicationContextLoader(contextLoader);