Search code examples
springibatisspring-orm

What is the purpose of using Spring-orm?


I have the following maven dependency in my project.

<dependency>
    <groupId>org.springframework</groupId>
    <artifactId>spring-orm</artifactId>
    <version>2.5.6</version>
</dependency>

We are using iBatis for ORM.

  • What is the purpose of giving this dependency?
  • Is this required if I to have bridge between Spring and iBatis?
  • In general how Spring and iBatis linked?

Thanks for your response.


Solution

  • What is the purpose of giving this dependency? Is this required if I to have bridge between Spring and iBatis?

    It adds support (glue code) to integrate various ORM solutions with Spring, including Hibernate 3/4, iBatis, JDO and JPA. Of course it's not an ORM on its own, it's just a bridge. You still need to include relevant libraries.

    In general how Spring and iBatis linked?

    Quoting official documentation: 12.5. iBATIS SQL Maps:

    iBATIS support works with Spring's exception hierarchy and let's you enjoy the all IoC features Spring has.

    Transaction management can be handled through Spring's standard facilities.