X

Geertjan's Blog

  • July 15, 2010

Ouagadougou on the NetBeans Platform (Part 2)

Geertjan Wielenga
Product Manager
In part 1, you can read how Skype and WebEx were used in Prague to provide a NetBeans Platform Certified Training to students in Burkina Faso. The second part of the training will be a workshop. In the workshop, the students will port one of their existing applications to the NetBeans Platform. To prepare for the workshop, I've been studying the application the students provided, i.e., a CMS in Java and Swing, with this source structure:

When you run the above application, you see a general workspace with many different menu items:

Each of the main menus produces a different dialog for handling some data:

The benefit of the current state of the application is that (1) it is well organized, e.g., all the forms in the same package, and (2) all the forms are designed in the Matisse GUI Builder. These two decisions will definitely simplify porting to the NetBeans Platform.

Now, what's the first step in the porting procedure? Simple. We need to identify who the users of the application are. What are they doing with the application? Do all the users need all of the features? Based on the answers to these questions, we can decide where the module boundaries will be. It would be useful to the end user to have only those features available that are actually needed.

What if all features are needed by all users? Then we should determine module boundaries in some other way. Maybe we should identify a workflow in the application, with each step in the workflow being provided by a different module (or set of modules, i.e., a cluster of modules).

Definitely, there could be one single module containing all the entity classes. Then all other modules would depend on the entity module (i.e., this would be the model of the application, providing the API that the rest of the application would implement), without depending on each other. That would result in a modular loosely coupled application, which is the ideal endpoint of a NetBeans Platform porting procedure.

Either way, in rearchitecting this application from monolithic to modular, the above concerns are the first that should be addressed before any other. Probably, after that, we could look at how the NetBeans window system can be leveraged to better organize the UI of the application, i.e., the JPanels in the various dialogs could be displayed in TopComponents instead, each provided by modules dedicated to the feature for which they have been created.

Join the discussion

Comments ( 1 )
  • KONOMBO Oumar Abdou Nassur Thursday, July 22, 2010

    hi.

    I am mr KONOMBO, and i am very happy to see my interface in your blog, and yours advice. But i have a cache problem. When i persist an element, after that i remove it, and i persist the same element with the same PK, i have an exeption. i look in internet and i try entitymanager.refresh(),entitymanager.clear() after deleting but the problem is not solved...,

    i don't known how to to. pls help.

    KONOMBO Oumar Abdou Nassur

    konombo@hotmail.com


Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.