title: Getting Spring to work with Play Framework 2.1 (java)
body: <p>I'm trying to get Spring working in my Playframework 2.1 project but with no success yet.
  I'm following <a href="https://github.com/guillaumebort/play20-spring-demo" rel="nofollow noreferrer">Guilliaume Bort's tutorial</a> on how to get it to work.
  The project starts correctly, it calls the action (via GET) signupForm fine(described below) but when I try to submit the form, I get the next Exception:</p>
  
  <p><img src="https://i.stack.imgur.com/24Ac5.png" alt="Exception gotten"></p>
  
  <p>It seems to not like the @Transactional annotation.
  This is part my controller code:</p>
  
  <pre><code>@org.springframework.stereotype.Controller
  public class UserController extends Controller {
      @Autowired
      private UserService userService;
  
      public Result signupForm() {
          // This is the initial method called via GET (works fine)
      }
  
      @Transactional
      public Result signup() {
              ... code ....
              userService.save(user); // call to the injected service
              ... more code ...
          }
      }
      ... mode code ...
  </code></pre>
  
  <p>This is my components.xml (placed in /conf):</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;beans xmlns="http://www.springframework.org/schema/beans"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xmlns:context="http://www.springframework.org/schema/context"
         xsi:schemaLocation="http://www.springframework.org/schema/beans
           http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
           http://www.springframework.org/schema/context
           http://www.springframework.org/schema/context/spring-context-3.0.xsd"&gt;
  
      &lt;context:component-scan base-package="controllers, services, dataaccess, models"/&gt;
  &lt;/beans&gt;
  </code></pre>
  
  <p>(dataaccess is where my dao's are placed)</p>
  
  <p>This is part of my service (just in case it is necessary):</p>
  
  <pre><code>@Service("userService")
  public class UserService {
      @Autowired
      private UserDao userDao;
      ... more code ...
  </code></pre>
  
  <p>And finally this is part of the relevant Dao for this case:</p>
  
  <pre><code>@Repository("userDao")
  public class UserDaoJpa implements UserDao {
      ... more code ...
  </code></pre>
  
  <p>As you can see in the image below, the getControllerInstance method in Global is trying to get an instance of the Transactional annotation and I don't know why. To me, it shouldn't be trying to instantiate it. It isn't event in the auto scanned packages by spring.</p>
  
  <p><img src="https://i.stack.imgur.com/LnBy9.png" alt="This is what spring tries to instantiate"></p>
  
  <p>Thank you for any help you could provide.</p>
  
  <p>PS: I'm new to spring.</p>