0 Replies Latest reply on Sep 25, 2005 11:08 AM by Sven Wappler

    Loading optimization of Dtos / CMR Relations with JBuilder?

    Sven Wappler Newbie

      Hi,
      i have a problem with jbuilder, i think. there are no other forums in which i can post, so i hope, someone can help me here.
      If i create cmp entity beans, jbuilder creates automatically DTOs for each entity bean and creates DtoAssembler with creatDto - methods. In these createDto-methods jbuilder calls other assembler, if a cmr-relation exist. here an example:

      companyDto.setActivated(company.getActivated());
      companyDto.setCompanyusers(CompanyuserDtoAssembler.createDtos(company.getCompanyuser()));

      company is the Entity Bean
      So jbuilder converts the entity beans in dtos.
      My comapany has users. the database-tables stands in a relationship.
      the problem is, if i load datas from the tables to work with them, jboss is forced to load all the datas in the relationship and this takes too much time. Loading-strategies like on-find, on-load or loading-groups don't help.
      I think the problem are these createDto-methods. Has anybody these problems too? The application is too slow.
      A solution is, to create my own createDto-methods, but this is stupid.

      Thanks for help, sven