Project

General

Profile

« Previous | Next » 

Revision 7b567c03

Added by Anahit Babadshanjan over 15 years ago

Added some tests

View differences:

cdmlib-services/src/main/java/eu/etaxonomy/cdm/api/application/CdmApplicationController.java
162 162
			appContext.refresh();
163 163
			appContext.start();
164 164
			
165
//			CdmTermInitializer.omit = false;
166

  
167 165
		} catch (BeanCreationException e) {
168 166
			// create new schema
169 167
			if (dbSchemaValidation == DbSchemaValidation.VALIDATE) {
......
178 176
			return false;
179 177
		}
180 178
		setApplicationContext(appContext);
181
		// load defined terms if necessary 
182
		//TODO not necessary any more
183
//		if (CdmTermInitializer.omit == false) {
184
//			if (testDefinedTermsAreMissing()){
185
//				throw new TermNotFoundException("Some needed Terms are Missing.");
186
//			}
187
//		}
188
//		
189
//		CdmTermInitializer.omit = false;
190 179
		return true;
191 180
	}
192 181
	
......
354 343
		TransactionDefinition txDef = defaultTxDef;
355 344

  
356 345
		// Log some transaction-related debug information.
357
		logger.debug("Transaction name = " + txDef.getName());
358
		logger.debug("Transaction facets:");
359
		logger.debug("Propagation behavior = " + txDef.getPropagationBehavior());
360
		logger.debug("Isolation level = " + txDef.getIsolationLevel());
361
		logger.debug("Timeout = " + txDef.getTimeout());
362
		logger.debug("Read Only = " + txDef.isReadOnly());
363
		// org.springframework.orm.hibernate3.HibernateTransactionManager
364
		// provides more transaction/session-related debug information.
346
		if (logger.isDebugEnabled()) {
347
			logger.debug("Transaction name = " + txDef.getName());
348
			logger.debug("Transaction facets:");
349
			logger.debug("Propagation behavior = " + txDef.getPropagationBehavior());
350
			logger.debug("Isolation level = " + txDef.getIsolationLevel());
351
			logger.debug("Timeout = " + txDef.getTimeout());
352
			logger.debug("Read Only = " + txDef.isReadOnly());
353
			// org.springframework.orm.hibernate3.HibernateTransactionManager
354
			// provides more transaction/session-related debug information.
355
		}
365 356
		
366 357
		TransactionStatus txStatus = txManager.getTransaction(txDef);
367 358
		return txStatus;

Also available in: Unified diff