Transaction management

BEA WebLogic On WebLogic 8.1 or above, you will generally prefer to use the WebLogicJtaTransactionManager instead of the stock JtaTransactionManager class. This special WebLogic-specific subclass of the normal JtaTransactionManager supports the full power of Spring’s transaction definitions in a WebLogic-managed transaction environment, beyond standard JTA semantics: Features include transaction names, per-transaction isolation levels, and proper… Read More Transaction management

Spring AOP

AOP is a tool for implementing crosscutting concerns, which means that you use AOP for modularizing individual pieces of logic, known as concerns, and you apply these concerns to many parts of an application Logging and security are typical examples of crosscutting concerns that are present in many applications. The two distinct types of AOP:… Read More Spring AOP

The Spring ApplicationContext

ApplicationContext is an extension of BeanFactory: it provides all the same functionality, but it reduces the amount of code you need to interact with it and adds new features into the pot for good measure. When using an ApplicationContext, you can control bean instantiation declaratively on a bean-by-bean basis, and any BeanPostProcessors and BeanFactoryPostProcessors registered in the ApplicationContext are… Read More The Spring ApplicationContext

The BeanPostProcessor

The BeanPostProcessor Sometimes, youmay find yourself in a position where you need to performsome additional processing immediately before and after Spring instantiates the bean. The processing can be as simple as modifying the bean or as complex as returning a completely different object! The BeanPostProcessor interface has two methods: postProcessBeforeInitialization, which is called before Spring calls any bean initialization… Read More The BeanPostProcessor

The BeanFactoryPostProcessor

The BeanFactoryPostProcessor The concept of the BeanFactoryPostProcessor is similar to the BeanPostProcessor: the BeanFactoryPostProcessor executes after Spring has finished constructing the BeanFactory but before the BeanFactory constructs the beans.Using the BeanFactoryPostProcessor, we can adapt the beans’ values according to the BeanFactory’s environment BeanFactory Post-Processors in Spring AspectJWeavingEnabler  – This post-processor registers AspectJ’s ClassPreProcessorAgentAdapter to be… Read More The BeanFactoryPostProcessor

Using FactoryBean

Using FactoryBean Spring provides the FactoryBean interface that acts as an adaptor for objects that cannot be created and managed using the standard Spring semantics. Typically, you use a FactoryBean to create beans you cannot use the new operator to create, such as those you access through static factory methods, although this is not always the… Read More Using FactoryBean