title: wrapping multiple calls in a transaction in spring boot application?
body: <p>I am using jdbctemplate to execute queries against db in my spring application.</p>
  
  <p>Here is the method that is annotated with @Transactional</p>
  
  <pre><code>@Transactional
  public boolean doSomething(){    
      try {
          jdbcTemplate.update(sql1); //1
          jdbcTemplate.update(sql2); //2
          jdbcTemplate.update(sql3); //3
          return true; 
      } catch (Exception ex){
          return false;
      }
  }
  </code></pre>
  
  <p>My question is if 1 and 2 succeeds and 3 fails, will the transaction on 1 and 2 rolls back or not? How can I test this?</p>
  
  <p>Additionally is having a boolean as return value a good practice to indicate the state of transaction?</p>