Results 1 to 10 of 20

Thread: Roo customization - a major issue?

Hybrid View

  1. #1
    Join Date
    Jul 2011
    Posts
    11

    Default Roo customization - a major issue?

    I started looking Roo recently. I have very rich experience in J2EE but has Beginner knowledge in Spring and Hibernate.

    I really find difficult to customize the roo generated code. I have seen some documentation where UI look and feel can be modified.

    Alteast I couldn't find documentations related to my question

    Here are my questions:

    1) How to customize or modify the jsps?

    2) How do I modify or create my own controller while rest of the code are Roo generated?

    3) How can I customize the finders?

    4) How can I do Internationalization - i18n?

    5) How can I create search or list screen which brings data from more than one table (joins)

  2. #2
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    667

    Post

    Well you're our target audience, so I'll do my best to answer your questions:

    Quote Originally Posted by nprabakaran View Post
    1) How to customize or modify the jsps?
    That's quite a broad question; what do you want to do specifically?

    Quote Originally Posted by nprabakaran View Post
    2) How do I modify or create my own controller while rest of the code are Roo generated?
    Roo can generate (and subsequently maintain) Spring MVC controllers for some/all of your domain entities via the "web mvc scaffold" and "web mvc all" commands. You can customise these controllers either by adding new methods to them or by pushing some or all of the methods from the ITDs into the controllers' .java files.

    Roo can also generate (but not maintain) a new controller via the "web mvc controller" command. It's up to you to code this controller as required (see the Spring MVC doco for details).

    Quote Originally Posted by nprabakaran View Post
    3) How can I customize the finders?
    You can write your own finders as static methods in whatever class you like, or you can ask Roo to generate finders for you using the "finder add" command. This puts a finder into the "_Roo_Finder" ITD, from where you can push it in and customise it as desired.

    Quote Originally Posted by nprabakaran View Post
    4) How can I do Internationalization - i18n?
    Roo already generates internationalized applications, with English as the default language. To add another supported language to a Roo app, simply use the "web mvc language" command. Any language can be supported as long as the Roo team or someone in the community writes an addon (using the "addon create i18n" command).

    Quote Originally Posted by nprabakaran View Post
    5) How can I create search or list screen which brings data from more than one table (joins)
    Like with most JPA apps, Roo's presentation layer works with a rich domain model rather than concerning itself directly with persistence-related concerns such as tables. You can show fields from more than one entity by writing a view (e.g. a JSP) that navigates the associations from one entity to another. These will be lazily loaded by default (Roo loads an OpenEntityManagerInViewFilter via web.xml), so you might want to tune the relevant finders to fetch some parts of your object graph eagerly. How and when to do this is getting outside the scope of this forum, however.

    I hope this answers your questions.

  3. #3
    Join Date
    Jul 2011
    Posts
    11

    Default

    Very Nice! Thanks - thats a very quick reply. I will try out based on your suggestion and get back.

    I want to tell something to you "Andrew Swan".

    I work for one of the largest software servicing company in the world. One of our team wanted to introduce Roo through out the organization for J2EE app development. The group validated Roo and Skyway. They concluded that Roo's customization is very difficult or atleast lacks enough documentation ; then for skyway they concluded that its introduces dependency on skyway plus it is not purely open source. Finally they created new spring based code generator from scratch in 5 months and that rocks throughout the org.


    I strongly suggest Spring Roo team to concentrate more on releasing step by step documentation for customization with multiple scenarios. This will make Roo more popular.

  4. #4
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    667

    Question Thanks for the feedback

    Quote Originally Posted by nprabakaran View Post
    I work for one of the largest software servicing company in the world. One of our team wanted to introduce Roo through out the organization for J2EE app development. The group validated Roo and Skyway. They concluded that Roo's customization is very difficult or atleast lacks enough documentation ; then for skyway they concluded that its introduces dependency on skyway plus it is not purely open source. Finally they created new spring based code generator from scratch in 5 months and that rocks throughout the org.
    Interesting! Not many shops would go the route of writing their own code generator. How does its feature set compare with Roo, e.g. how does it support round-tripping, is it extensible via addons/plugins, etc? I understand if the details are commercially sensitive. By the way, the Roo 1.2 release will add a lot of scope for customisation, particularly in the area of application architecture.

    Quote Originally Posted by nprabakaran View Post
    I strongly suggest Spring Roo team to concentrate more on releasing step by step documentation for customization with multiple scenarios. This will make Roo more popular.
    Thanks for the feedback, it's always useful. As you can appreciate, we're a busy lot on the Roo team; what parts of the existing documentation do you think are most urgently in need of improvement?

    P.S. You can call me "Andrew"...

  5. #5
    Join Date
    Jun 2010
    Posts
    440

    Default

    @nprabakaran,

    I work for the smallest software servicing org. in the world...
    I was able to accomplish the following Java web development projects using Roo-
    This is the link http://pragmatikroo.blogspot.com/201...ductivity.html- all by myself. All the projects are Roo based just lightly tweaking the UI part.

    B. Roogards
    jD

  6. #6
    Join Date
    Jul 2011
    Posts
    11

    Default

    Excellent jD!

    If your work is for community, can you share the source of your work and if there is any documentation on top of it?

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •