Saturday, May 19, 2007

Eclipse RCP missing the Business Desktop opportunity?

I was recently involved (tangentially) with a biz app proof-of-concept effort that used an eclipse RCP front-end for a J2EE middle tier. The prototype was quite successful. However, when considering adopting the RCP approach, there’s concern that if we just start knocking off a bunch of apps as plug-ins, we’ll run into some problems:

  • duplication (code, functionality)
  • managing relationships/dependencies between plug-in
  • biz users complaining about the update mechanism

I’m willing to bet there are others I’m not thinking of. Not to suggest that these are problems with RCP or Eclipse--I’m sure a team of seasoned plug-in developers could produce and maintain an excellent suite of custom RCP biz apps. But after doing a few such plug-ins, they’d probably realize that they could refactor out a foundational plug-in that provides common support services that were duplicated among the various app plug-in. In fact, this concept already has a name… the “Business Desktop”. I heard this term from a presentation titled "Enterprise applications with Rich iDesktop applications on Eclipse" (see link below). Essentially, a Business Desktop would be an RCP-based business application environment. The Business Desktop could provide services including:

  • provisioning
  • search
  • authentication/authorization
  • preferences
  • Expression Language (assuming contexts are set up)
  • scripting
  • logging
  • error handling
  • service locator

The overarching theme is something like “app plug-ins do biz logic, the business desktop does everything else”. Such an approach would greatly reduce the learning curve for RCP adoption for business apps.

There are already some pieces of this available too. The Maya project is working the provisioning piece. And I’m sure others are out there (or are available via the Eclipse api but could be wrappered for convenient plug-in use). But I don’t see anything like the Business Desktop on the horizon. Is it there but I am missing it? Is it not needed? Comments welcome.


Enterprise applications with Rich iDesktop applications on Eclipse:
I can’t give a direct link to the "" since it is flash based. Registration required unfortunately--but there are some good technical screencasts there:

Maya project:

Friday, May 4, 2007

Using seam-gen.reveng.xml to control tables used for entity generation

I was having problems using seam-gen to try out reverse engineering on an Oracle Express database. Seam-gen was finding all sorts of objects somehow exposed to the user, rather than the DEMO_ tables I was trying to generate off of. Turns out that a feature (undocumented?) was added in 1.2.1.GA that let's you use a reveng.xml file to control this. After you run:

C:\temp\jboss-seam-1.2.1.GA>seam new-project

You can go to the \resources\seam-gen.reveng.xml

And add a line such as this:
<table-filter match-schema="MYSCHEMA" match-name="DEMO.*" exclude="false"/>

This should effectively restrict the tables as desired. Note you can use multiple of these entries to "carve out" the set of tables you want (although I'm not sure what the exact semantics are of using various combinations of exclude=true/false for different entries).

Some things to watch out for:
  • Case sensitivity
    At least for Oracle, you need to use upper case (I suppose you could attemp some kind of case insensitive regex).
  • Owning schema in seam-gen.reveng.xml
    Seems like you have to specify the owning schema for the tables, even if you are connecting with a user that has privileges for the tables.
  • Owning schema in
    You need to specify connection properties to the owning schema, at least temporarily, or you may get WARNING: Exception while trying to get indexinfo on...
I haven't tried enough variations to prove all of the above bullets, but if you're experiencing problems, try out some of these suggestions.

Reference for table-filter