Announcement Announcement Module
No announcement yet.
Spring AOP Doubts Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Spring AOP Doubts

    Hi all, I am new to Spring AOP and I have some doubts which I am hoping someone can shed some light on:

    @Transactional(timeout = 5, readOnly=true)
    public void runLongQuery()
     jdbcTemplate.queryForList("Select * from sometable); // Takes long time
    IN debug mode, I see that a new transaction is been created; but the timeout does not take effect; and does not rollback either... Is there any reason why?

    I read that it is because the oracle driver does not support readonly transactions. Is that true?

  • #2
    Almost no JDBC driver supports readonly... Also readonly is only a hint in general only useful when using something else as JDBC (like ORM provider hibernate for instance).