Archive for the ‘enterprise systems’ Category
February 22nd, 2010 by Simon Zambrovski

Abstract
The JavaServer Faces (JSF) 2.0 is the newest Java presentation technology that is covered in JSR-314 and was publicly released on July 01, 2009. It became a part of the JEE6 standard and can be comfortably used in conjunction with other JEE frameworks, with Spring or just on its own. This article reveals the possible scenarios and shows the required configuration for the usage of JSF 2.0 with EJB 3.1 and with Spring 3.0. It also discusses several auxilary technologies which can be used along with JSF 2.0.
(more…)
Posted in enterprise systems, java, technology | No Comments »
February 3rd, 2010 by Simon Zambrovski
The Eclipse RCP became a prominent platform for building client software. One of the delivery mechanisms supported by Eclipse RCP is Sun’s Java Web Start (JWS). Since Galileo Edition some changes has been introduced in the platform. This article provides some hints for creation of the RCP delivered by Java Web Start.
Packaging
In order to package the RCP I suggest to use feature-based products as described in
a previous article. Following it, you should have a top-level plug-in (also refered as product-defining plug-in) and top-level feature, which is called “wrap”-feature in the context of the Java Web Start.
Exporting the product
Before you start with Java Web Start (JWS), export the product and make sure it starts as a standalone application. In doing so, you have to ensure that your references to the plug-ins are correct. One of the way of doing it is to hit the Validate button in the top left of the product editor.
If the validation is successful, try to export the product. The PDE builder will run and create a distribution. The errors of the compiler/builder/assembler, if any, are reported to files zipped to the logs.zip file in the distribution directory.
Posted in eclipse, enterprise systems, rcp | 2 Comments »
February 3rd, 2010 by Simon Zambrovski

I just returned from the furious event given by Adam Bien on
Real World Java EE Practices. The presentation has been held in Lehmanns Bookstore in Hamburg in co-operation with the JUGHH. It was a full success with no space left in the bookstore. I think, I got the last seat and there were some people standing.
Adam made it in an hour and presented many interesting topics. He started with new subjects introduces in JEE6, like optional local interfaces, cronjob-like Timer Service and other nice goodies. Then he covered new stuff from JEE like REST and CDI (Context and Dependency Injection). Finally, he moved to the best practices, patterns and anti-pattern. As usual, it was quick and precise – Adam answered many questions and gave a good overview of the technology.
After the presentation, JUGHH / Lehmanns offer a glass of sparkling wine for the smaller audience and Adam spoke about the possibility to speak about JavaFX next time. This time I left my camera at home and only had my phone with me, so sorry for the low-resolutioned picture…
Posted in enterprise systems, java | No Comments »
January 7th, 2010 by Simon Zambrovski
Abstract
About two years ago, I published an
article about Exposing the Functionality implemented in Stateless Session Beans (EJB 2.1) using Web Services. J2EE 1.4 times are over and the new version of the Java Enterprise framework, called Java Enterprise Edition 5 (JavaEE 5, or simply JEE) has emerged. In this article the same business scenario is repeated in the new framework.
Requirements
Before we dive into code examples, some software is required. The good news about the software is, that it also evolved over time. Here is what we use:
- Sun’s Java 6 SDK
- JBoss AS 5.1.0 GA for JDK6
- Eclipse Galileo 3.5.1 for JEE development
(more…)
Posted in enterprise systems, java, jboss, technology | 3 Comments »
January 4th, 2010 by shuron

Accessing a relational database system from Java is a basic step required for many applications. The JEE architecture defines a standard for gaining this access, calls Java Connector Architecture (JCA). This article is a short HOWTO of configuring JCA-compliant datasource to a Firebird 2.x RDBMs using JBoss AS 5.1.0 as example. This tutorial is based on a Windows installation, but can be easily ported to Linux, or other OS.
For the configuration of the datasource two steps are required:
- Deployment of the Firebird RAR resource adapter (
jaybird-*.rar)
- Creation of the
firebird-ds.xml configuration
(more…)
Posted in enterprise systems, java, jboss | 7 Comments »
November 10th, 2009 by Simon Zambrovski
Even if some time has passed since the events EWiTa 2009 and Eclipse Summit Europe 2009, I would like to share my impressions, since I took part in both events…
EWiTa 2009
EWiTa 2009 stands for Elmshorner Wirtschaftsinfromatiktag, that is German for “Elmshorn Business Information Systems Day”. The event has been organized by Frank Zimmermann, of
Nordakademie – a private university in Northern Germany. Even if the event is not an official sequel of the
MDSD Today, there were many similarities. The event had two tracks: the process modeling track and the MDSD track. After an excellent keynote from Mathias Weske about the importance of collaboration during the process of (business) modeling I stayed in the business track to listen to the Andrea Grass (
oose GmbH) on the combination of UML and BPMN 2.0. To say the truth, I’m not a big fan of this approach, especially, because the conceptual mismatch of modeling of business behavior and technical behavior. After a coffee break I enjoyed an excellent talk of
itemis), reporting about the success story of xText in a big project of Deutsche Börse AG (German Stock Exchange).
After a small lunch, I was listening to two Arcando consultants reporting about their eTicketing project. The strange thing about this talk was that they just made some ads on a standard Microsoft product. After this, I enjoyed an interesting talk on business modeling based on CobIT process. Finally, I switched the track again to MDSD and listend to the an interesting usage of MDSD techniques for generation of DynPro and ABAP code.

In general I enjoyed the event. I think the MDSD track was a little more technical, but the combination was good.
Eclipse Summit Europe 2009
The Eclipse Summit Europe 2009 (ESE 2009) took place on October 27-29 in Ludwigsburg, Germany, it is the European complement to the EclipseCon in the US. In contrast to the spring event in Santa Clara, CA, the ESE is an autumn event in a beautiful baroque town near Stuttgart. The event lasted three days and is a must for Eclipse-related technology people. As usual, the venue was great, the keynotes excellent and the talks interesting. And of course it was the place to meet the committers, evangelists, see them in action, talk to them and discuss the future directions.
Symposium Day
The first day is an arrival day. People arrive during the day, some of them are already there. I was visiting the Modeling Track the whole day and had much fun with Ed Merks, Eike Stepper and Thomas Schindl in the morning. Later, in the Modeling Symposium, Eike showed the eDine RCP based on CDO, UBS envisioned the modeling tool pipeline and so on, and so on. About 10 people showed different technologies on and about modeling. Intersting, unstructured and relaxed. And of course, the first evening is the opportunity to speak with all the Eclipse VIPs and drink a cold beer.
First Day
The main conference day was Wednesday and it started with a great keynote on functional programming held by Don Syme, the father of F#. Suprisingly, the talk was about F#. For some of us, there was not enough functional beauty exposed in the talk, so I scheduled a private session with Don and he told
Markus Voelter,
Heiko Behrens and
me about some interesting F# features.
I took part in the
How about I/O session on
JPicus. A very interesting tool for tracking I/O problems in Java programs developed by SAP. The
Climb The Tower of Babel was about the Eclipse translation project. Intersting is the runtime editor allowing you to translate you runnig application. After a delicios lunch, I enjoyed two modeling talks: Xtext and EMF Query. The itemis team introduced some really new features, which make Xtext in my oppinion to a unique technology. Just to mention few of them: white-space aware parsing, usage of scopes and qualified names, usage of index (construted by a builder) in your own language, separation of markers and annotations in the editor, integration of the generator on-save, declarative quick-fix in your DSL, strings with special meaning, references to java types, and much more… The EMF Query is a project developed by the SAP team, that leverages the index by a query language. The language is a SQL-like DSL for querying the EMF-based models. The infrastructure is very intersting and allows complex scenarios with multiple model providers – very technical, and I believe, very interesting project.
Second Day

After the keynote on the importance of software ecosystems and a deep economical analysis of Eclipse ecosystem, I switched off the track to be able to prepare
my talk. I was reporting about the IDE for TLA+ which I was building the last nine month at Microsoft Research, and which will be
available soon. The main emphasis of the talk, was not the demo of the IDE, but the exchange of experiences on building one. Especially, I focused on the possible pitfalls and conceptual mismatches of IDEs depending on the integrated language. The slides will be available soon.
At the end, I enjoyed the event very much. I even liked it more than EclipseCon. Modeling still seems to be the most interesting part of Eclipse ecosystem. Technologies like Xtext and CDO gain maturity, new technolgoes like EMF Query are being developed. It was nice to see the people again… As usual, some pictures:

Posted in announce, eclipse, enterprise systems, technology | 1 Comment »
July 8th, 2009 by Simon Zambrovski

Abstract
Using Eclipse-based rich-clients as stand-alone applications is discussed in many
books and
articles. In the context of enterprise systems, the software development adopted several paradigms to improve the quality of the overall architecture. This short article describes some issues in packaging the application for using it in the context of enterprise systems.
Architectural Assumptions
Designing enterprise architectures is a standard discipline for IT-consulting companies or freelancers involved in software development. Maybe one of the main characteristics of enterprise architectures is the framework-driven approach of software creation. Thus, the software has to comply certain rules and standards adopted inside the enterprise. In order to simplify such constrained development process, it is common to use an in-house software framework, which enforces the compliance of the enterprise-internal standards and acts as glue between different technologies adopted as parts of the enterprise architecture.
Using such frameworks has major implications for the software development in general, and especially for the rich client development. The design issues are summarized in the next section.
Usaging an Enterprise Framework
The major goal of the enterprise in-house framework is to simplify the process of software systems development and to enforce standardization among the software systems. This usually includes the following aspects:
- Domain-specific component framework
- Methods for master data management
- Infrastructure services: authentication, authorization, communication, security, printing, reporting
- Application skeletons and launchers
The more unification and standardization is included inside the framework, the easier it is for a software developer to concentrate on the particular business task and the easier is the maintenance of the software system.
From the previous list, the most interesting part related to RCP packaging and deployment is the existence of the application skeletons and launchers. So, when launching an application, the framework libraries are loaded and executed first and pass the control to the application-specific modules. The advantage of this approach is that infrastructure services can be loaded first, which can be developed and shared among different applications.
(more…)
Posted in eclipse, enterprise systems, java, rcp | 5 Comments »
April 24th, 2009 by Simon Zambrovski
Eclipse Platform provides a help system that can be used during creation of the help content for your application. It is very convenient while used inside of the IDE, but needs a special approach if used in the RCP. This article tries to gather the information which may be useful.
Adding Help Support
Basic preparations
As discussed in Eclipse RCP Book and RCP Articles, the help system is not a part of the RCP-Runtime and should be added separately. The question arises where to add at to? If you follow the best practices for packaging of RCP applications, you should have at least one product and the top level feature defined (See Rule 1 of Chapter 23 of Eclipse Rich Client Platform). The top level feature includes the branding plug-in (containing the product definition) and refer to other features (like org.eclipse.rcp, and your functional features). In order to add the help system, you need to add the org.eclipse.help feature in this list.
Platform help buttons
There are several predefined buttons (actions) you can use for calling the help system. These are:
- Help Contents
- Help Search
- Dynamic Help
In order to activate them from your ApplicationActionBarAdvisor just call:
private IWorkbenchAction helpContentsAction;
private IWorkbenchAction helpSearchAction;
private IWorkbenchAction dynamicHelpAction;
protected void makeActions(IWorkbenchWindow window)
{
helpContentsAction = ActionFactory.HELP_CONTENTS.create(window);
dynamicHelpAction = ActionFactory.DYNAMIC_HELP.create(window);
helpSearchAction = ActionFactory.HELP_SEARCH.create(window);
register(helpContentsAction);
register(helpSearchAction);
register(dynamicHelpAction);
}
If you want to do the same declarative, you have to create commands that use the following actionDefinitionIds:
- org.eclipse.ui.help.helpContents
- org.eclipse.ui.help.helpSearch
- org.eclipse.ui.help.dynamicHelp
The same ids are required for registration of key bindings (e.G. Ctrl + F1, Shift + F1, F1 on Win32). Apparently, since these actions adjust their status depending on the state of the system and the plug-ins installed, I could not figure out how to force them to be enabled, when installed in a declarative way. Since they are still provided as ActionFactory (which is legacy due to the changes introduced by new Command Framework), they should be further activated from the ApplicationActionBarAdvisor.
Context-Sensitive Help UI Integration
The Eclipse platform provides not only the help system, but also support the so-called Context-Sensitive Help (a very confusing name, because the context is only the widget, and not the data). In the following, it is shown, how the connection between the widgets and the help system can be established.
The big picture
The content already defined in the help system can be pointed at from various places in the your application using the so-called help contexts, which on one hand point to the places in the documentation and on the other hand can be assigned to widgets in the application UI.
Establishing contexts
In order to assign the help context to a widget the invocation of the method PlatformUI.getWorkbench().getHelpSystem().setHelp(Control control, String contextId); is used. The contextId is a full-qualified string constructed from the pluginId and the local context name. The context name should be unique for this plug-in (usage of non-unique ids leads to a merge of different subjects, which is a nice feature, but may be not desired). I prefer to create the convenience method for this invocation:
public class HelpUtil
{
public static void setHelp(Control control, String localContextId)
{
if (localContext == null || control == null) return;
PlatformUI.getWorkbench().getHelpSystem().setHelp(control,
Activator.PLUGIN_ID + "." + localContextId);
}
}
There are also methods for registration of other SWT widgets (Control, IAction, Menu, or MenuItem) in the help system, which can be handled by the overloaded version of the method. The invocation of the convenenience method usually looks like: HelpUtil.setHelp(composite, "newWizardPage") and should be invoked from the createControls() of the correponding element. Please note, that the “newWizardPage” is a local name, and the pluginId is added to it inside of the conveninece method. Widgets that do not get focus should not be assigned context ids, since they will never trigger a context-sensitive help
The declarative part
As usual in Eclipse, there is a declarative part, that connects the context ids, set up in the code with the help pages. The connection is established by a special XML file. In order for the platform to know, where to find the file, there is an extension point (org.eclipse.help.contexts), that you need to contribute to:
<extension point="org.eclipse.help.contexts">
<contexts file="contexts.xml" plugin="de.techjava.rcp.ui" />
</extension>
The file attribute specifies the full path to the XML file containing the context definition. The plugin attribute is optional and declares for which plugin the context definition applies. Please note, that if the plugin attribute is ommited, the context names used in the context definition file will be seen as local to the plugin they are declared in. For example, if you want to support the context-sensitive help in plug-in de.techjava.rcp.xyz then your in-code definition of the context should define full qualified context names like de.techjava.rcp.xyz.context1. Either you use the extension point (org.eclipse.help.contexts) in the plugin.xml of the de.techjava.rcp.xyz plugin.xml, or if you put the usage of the extension point into some other plugin (e.G. central for all help), you must provide the plugin attribute with value “de.techjava.rcp.xyz”. This issue is badly discussed in the help guide and is a little confusing. In the context definition file the contexts are defined as follows:
<contexts>
<context id="context1" title="My first context">
<description>This is a test context</description>
<topic href="path/context1.htm" label="Context1"/>
</context>
...
</contexts>
Wizards and Dialogs
Wizards are used with or without dialog.
The call of the Wizard#setHelpAvailable(true) shows the Help button.
The call of the WizardDialog.setHelpAvailable(true); shows the small sexy round Question button.
References
Posted in eclipse, enterprise systems, java, rcp | 1 Comment »
February 25th, 2009 by shuron
I found strange problem running wscompile (from Sun’s Java Web Service Developer Pack 1.6) inside Ganymede (Eclipse Version 3.4.1). The run of the wscompile Ant task produce a problem. The build script execution freezes on the wscompile task. It prints the following message on console but then nothing happens.
[wscompile] wscompile ...\env\java\1.4.2_03\jre\bin\classpath-classpath D:\workspaces\general\lib\bla.bo-0.0.1.jar; ... D:\workspaces\general\lib\... jar.0.5.5
In this line, the classpath of wscompile is printed.
The build script uses configured Apache Ant in version 1.6.5. I tried to start it with Java in versions 1.4.2 und 1.6.0.10. Both works in Europa (Eclipse 3.3.x) but don’t work in Ganymede (Eclipse 3.4.x), except for the first run. It seems that Ganymede provides a different handling for Ant scripts. Every first start of an Ant build script produces new “External Tool Configuration” (if not already there). If this configuration already exists, wscompile task doesn’t work!
This means my build script with wscompile task works only once, every first time after deleting the “External Tool Configuration”. I could live with that if I wouldn’t need that configuration. But I need that configuration to use different java version that is the workspace default.
Do anyone know how to fix that?
Here is my task definiton.
<taskdef name="wscompile"
classname="com.sun.xml.rpc.tools.ant.Wscompile"
classpathref="class.path.jwsdp"
/>
and also task usage in the script
<wscompile fork="true" import="true" base="java/class" sourceBase="java/generated" verbose="true" features="documentliteral, wsi, searchschema, serializeinterfaces, explicitcontext" mapping="java/generated/META-INF/jaxrpc-mapping.xml" config="metadata/wsdl-config.xml" xSerializable="true">
<classpath>
<path refid="class.path.local" />
<path refid="class.path.ant" />
<pathelement path="${java.class.path}" />
</classpath>
</wscompile>
Comments are welcome.
Posted in eclipse, enterprise systems, java, tools | 1 Comment »
September 17th, 2008 by Simon Zambrovski


Yesterday,
the second
Adam Bien event in
Lehmanns Bookstore took place. Again, the event was a full success. I arrived half-an-hour earlier and got a seat only in the tenth row.
Adam spoke about new features of EJB 3.1 and Glassfish. He showed examples running on a developer build of Glassfish V3, promising that the features will work without exceptions…
Here are some topics, I remember:
- Singleton Beans: usefull a s a central point of the application, e.G. central cache etc…
- Async Methods: allows asynchronous execution of time-consuming methods. Especially, it is possible to abort the execution
- Deploying Beans in WARs: could be helpful for small applications
- Global JNDI-Namespace
- No interface view: simplifies the access to beans, if needed
- EJBCOntainer.getEJBContainer().getContext(): allows external initialization of bean context, which is nice for testing
Later,
Adam discussed some
Core J2EE patters, that become absolete with EJB 3.1 and others which are still valid.
After the talk, I spoke with Adam about the
OSGi as a module architecture inside JEE application, which seems interesting to me.
The pictures are as usual available in my
FlickR Gallery.
Marco published a
video on Loroma.
Posted in enterprise systems, java | No Comments »