core/src/main/java/nl/nn/adapterframework/lifecycle/IbisApplicationContext.java
/**
	 * Create Spring Bean factory.
	 *
	 * Create the Spring Bean Factory using the default <code>springContext</code>,
	 * if not <code>null</code>.
	 *
	 * @throws BeansException If the Factory can not be created.
	 *
	 */
Create Spring Bean factory.
Create the Spring Bean Factory using the default springContext,
if not null.

@throws BeansException If the Factory can not be created.
Create Spring Bean factory . Create the Spring Bean Factory using the default springContext if not null . @throws BeansException If the Factory can not be created .
protected void createApplicationContext() throws BeansException {
		log.debug("creating Spring Application Context");
		if(!STATE.equals(BootState.FIRST_START))
			STATE = BootState.STARTING;
		long start = System.currentTimeMillis();
		lookupApplicationModules();
		try {
			applicationContext = createClassPathApplicationContext();
			if(parentContext != null) {
				log.debug("found Spring rootContext ["+parentContext+"]");
				applicationContext.setParent(parentContext);
				SpringBus bus = (SpringBus) parentContext.getBean("cxf");
				BusFactory.setDefaultBus(bus);
			}
			applicationContext.refresh();
		} catch (BeansException be) {
			STATE = BootState.ERROR(be);
			throw be;
		}
		log.info("created "+applicationContext.getClass().getSimpleName()+" in " + (System.currentTimeMillis() - start) + " ms");
		STATE = BootState.STARTED;
	}
protected void createApplicationContext ( ) throws BeansException { log . debug ( "creating Spring Application Context" ) ; if ( ! STATE . equals ( BootState . FIRST_START ) ) STATE = BootState . STARTING ; long start = System . currentTimeMillis ( ) ; lookupApplicationModules ( ) ; try { applicationContext = createClassPathApplicationContext ( ) ; if ( parentContext != null ) { log . debug ( "found Spring rootContext [" + parentContext + "]" ) ; applicationContext . setParent ( parentContext ) ; SpringBus bus = ( SpringBus ) parentContext . getBean ( "cxf" ) ; BusFactory . setDefaultBus ( bus ) ; } applicationContext . refresh ( ) ; } catch ( BeansException be ) { STATE = BootState . ERROR ( be ) ; throw be ; } log . info ( "created " + applicationContext . getClass ( ) . getSimpleName ( ) + " in " + ( System . currentTimeMillis ( ) - start ) + " ms" ) ; STATE = BootState . STARTED ; }
Create Spring Bean factory.
Create Spring Bean factory .
// We need to set the SpringBus here, because on WebSphere the IbisApplicationInitalizer is ran from a different ClassLoader. // This causes the WebServiceListeners register them selves on a different (newly created) SpringBus instead of the Ibis one.