Re-discussion on Ibatisnet + Castle for project development

Source: Internet
Author: User

      As the project progresses, Castle and ibatisnet give me more surprises. COM + is very heavy, do not need to use the distributed medium and small projects, nhibernate, although good, NHibernate 2005-9-20 released the latest version of 1.0-RC1, the lack of a high level of OO designers, project team programmer level   application Castle + Ibatisnet people will not waste their energies on data access, transaction processing, primary key generation and so on, and can concentrate on writing business components. The project is progressing well.
    architecturally, Castle as a lightweight IOC container is undoubtedly at a high level, so ibatisnet now only has to work on the sql-object mapping of the persistence layer, and the rest is assembled by castle.  
      the two major tasks of Daomanager in Ibatisnet: DAO transaction Management, DAO interface and implementation decoupling, Castle transactions Use an extension unit that is castle, which can be configured at the method level, similar to COM +, and requires a declarative transaction property to be set on the class to determine its transactional behavior. Specifies which classes of which methods require transactions, whether you are DAO or service, are free to specify here, do not invade the class you write, if it is COM +, will force you to implement COM + ServicedComponent.  
     Ibatisnet's cache is very good, we need to use it. In Ibatisnet, cachemodelsenabled is true by default, and do not forget to make cache-related configuration work when writing specific po.xml. But the specific use of which (memory  lur  fifo  oscache) capacity to set how much, according to the actual situation of the project, I usually prefer lur. Correctly set the flush statement of the cache, eliminating the possibility of dirty data in the cache. The premise of caching is that the reading and writing of the table in the system must be done through ibatisnet, which is closed.     
    Dynamic SQL is really a strong one. I feel very good when I am familiar. All DAO methods in Ibatisnet are only one value object, and complex queries are certainly no exception.  

Re-discuss ibatisnet + Castle for project development

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.