Trying out Vaadin

Spent some time today trying Vaadin In general it’s a GWT-based solution which makes work with GWT more comfortable. It’s not another GWT component library like ExtGWT or SmartGWT. It dives deeper into the layer up to the JPA layer. There’s a book available for free which can be used to study Vaadin at http://vaadin.com/download/current/docs/book-of-vaadin.pdf So the first thing I liked so much – was debug console. You can call it by specifying “?debug” parameter at the end It’s way…
Improvement of building process
We have one big project. And as all big projects it’s build takes long time – it is the problem, because it is wasting time 🙁 First some words about project architecture. It is based on Java EE 5 (we use EJB, JPA, JMS, etc.) and we use GWT for building rich user interface. Also, for static pages, we use Magnolia CMS. And as result building of it is not quick. After some analysis I found obvious. At the same…
Localization in GWT via cookie
If you’ll search for the term “Localization in GWT” – you’ll find numerous articles about using META tag with gwt:property name, like <meta name=”gwt:property” content=”locale=de”>But sometimes it’s not very convenient. For example we have an iframe with reference to some another GWT module and this module bypasses META tag written for the parent document. In this case cookie is the easiest choice. So in the combo selecting the language you specify a cookie with any name you like, for example…
GWT migration
We’re using GWT 2.0.3 on one of our projects. Today we’ve noticed a very strange defect in IE8 and decided to upgrade to the latest version which is now 2.2.0. So initially we’ve got three modules with four languages specified. All this stuff was referencing GWT 2.0.3 and gwt-maven-plugin of version 1.2 was used for compilation. During upgrade the following changes were done: Referenced GWT version was changed to 2.2.0 gwt-maven-plugin version was changed to 2.1.0-1 Scope of the com.google.gwt.gwt-dev…
Migration to Maven 3
I’ve read a number of articles which say about new cool features like parallel builds and performance speed-ups. Sounds rather sweet. So I’ve taken the current project I’m working at and migrated it to Maven 3 to check if it’s possible to get any compilation speed-up. The only thing which was changed in the root pom.xml was replacing http://download.java.net/maven/1 repository with http://maven.glassfish.org/content/groups/public. This has been done because legacy layouts are no longer supported in Maven 3 The project contains about…
Developing using GWT Hosted Mode remotely

Lets say you are running Linux. And of course you want to support IE browsers in your GWT application. So you have tested the application in Firefox which works perfectly with the GWT Development plugin. So you’ve decided to test application in the running IE browser of the Windows guest and you observe a very strange behavior in IE. Lets assume that initially you have the following command to run GWT application in the hosted mode:java -Xmx512M -XX:MaxPermSize=256m -Xdebug -Xrunjdwp:transport=dt_socket,address=8786,server=y,suspend=n…
Improving GWT compilation speed
Yesterday we have moved one of our projects from GWT 1.7 to GWT 2.0. And GWT compilation appeared to run slower on my host. So I’ve started looking for a way to make this process faster. The initial compilation of the project took 207 seconds and permutation compilation 170 seconds The main idea of speeding up compilation is to reduce the number of the compiled permutations. Permutation is a combination of the supported browser and locale. By default permutations for…
Model – View – Controller (MVC)
MVC is very old and very famous design pattern. It is used in web and desktop applications, in different programming languages (C++, Java, .NET, Python, etc.). First I read about it in Design Patterns. Elements of Reusable Object-Oriented Software and since that time I have heart a lot of things about it and see a lot of realization of this pattern. I decide to write this post thanks to statement of my good friend – he said that MVC is…
Localization in GWT
In simple Java application you have a standard approach to read the localized string:Locale currentLocale = new Locale(“fr”, “CA”, “UNIX”)ResourceBundle labels = ResourceBundle.getBundle(“ButtonLabel”, currentLocale);You can easily get the localized stringString buttonLabel = ButtonLabel.getString(“buttons.OK”);The bad thing here is that you manipulate with string and such a string can probably do not exist in the properties file and you’ll be able to see it only after running application. You can’t detect this problem in the compile time. The good thing here is…
ExtGWT: NullPointerException in case of adding items into TreePanel
We’re using ExtGWT(GXT) of version 2.0.1 as an addition to the standard GWT capabilities. So we have a tree panel(com.extjs.gxt.ui.client.widget.treepanel.TreePanel) which is used to display hierarchy. Everything worked fine until the recent changes. The interesting things began happening once we’ve moved sorting of data to the UI layer. Once we were trying to add more than one node – internal ExtGWT exception occurred:
1 2 3 4 5 6 7 8 9 10 | java.lang.NullPointerException: null at com.extjs.gxt.ui.client.widget.treepanel.TreePanel.getChildModel(TreePanel.java:963) ... at com.extjs.gxt.ui.client.widget.treepanel.TreePanel.update(TreePanel.java:1406) at com.extjs.gxt.ui.client.widget.treepanel.TreePanel.onAdd(TreePanel.java:1031) at com.extjs.gxt.ui.client.widget.treepanel.TreePanel$1.storeAdd(TreePanel.java:280) ... at com.extjs.gxt.ui.client.store.TreeStore.doInsert(TreeStore.java:792) at com.extjs.gxt.ui.client.store.TreeStore.insert(TreeStore.java:493) at com.extjs.gxt.ui.client.store.TreeStore.add(TreeStore.java:163) |
After trying to understand why this happens – I have detected the source of the problem….