title: Setting Up Annotation Driven Transactions in Spring in @Configuration Class
body: <p>So in the latest version of Spring we are able to use the <code>@Configuration</code> annotation to setup our configurations for Spring. Now in JavaConfig it is possible to use the <code>@AnnotationDrivenTx</code> (<a href="http://static.springsource.org/spring-javaconfig/docs/1.0.0.M4/reference/html/ch07.html" rel="noreferrer">@AnnotationDrivenTx Reference Link)</a> annotation to setup transactions in our Config class. But since JavaConfig has been decommissioned I was wondering if anyone knew how to setup something similar without JavaConfig and without needing to add anything to the <code>application-context.xml</code>. Here is what I basically have for my Config class</p>
  
  <pre><code>@Configuration
  @ImportResource("config/application-context.xml")
  public class Config {
  
       public @Bean DataSource dataSource() {
             //get and return datasource
       }
  
       public @Bean Service1 getService1() {
            //return service1Impl
       }
  }
  </code></pre>
  
  <p>And I'd like to make <code>Service1</code> transactional. If anyone has any ideas on how to do this or if this is just not possible please let me know. </p>
  
  <p>Thanks!</p>