Tuesday, April 29, 2008

Preparing the new VFSJFileChooser release

VFSJFileChooser will be out soon.

Here is the changelog :
  • Sort file by names : Some patches were submitted to sort file by names.
  • The "home" button will not bring you back anymore to your local home folder if you're browsing a remote directory.
  • A details view is being added as a complement to the existing list view
There are still some issues when you choose the native look and feel with : UImanager.setlookandfeel

Saturday, April 26, 2008

A closer look at OSGI

I was reading about OSGI and I found out that it's not as complicated as it looks like. As I am not an Eclipse fan, I tried Knopflerfish and Apache Felix. I might use OSGI in my next projects if they're big enough.

After half an hour, I was able to get a simple bundle running with Apache Felix. I wrote a simple program embedding Apache Felix and created another project which provided a bundle.

My main interest in OSGI is dependencies management handling :
  • Service A is started
  • Service B depends on Service A
    • if service A is not available -> do not start service B
    • if service A is available -> start the service B and register it

Sunday, April 20, 2008

Java Enterprise Edition

Most of small companies don't use Java Enterprise Edition, even if few thousands guys need to access an application at the same time, even if the application needs to support transactions, to be scalable, etc. They already have deployed "medium to big" successful applications using Tomcat and J2SE, so why bother?

It's difficult to find very young people(less than 30) which have a J2EE knowledge. You don't learn J2EE in a technical school, you don't learn it at University and you probably won't learn it by working in a small company. IMHO, the general opinion about J2EE is that "It's interesting, looks complicated too... and I probably don't need it, (solo talking it's probably worth not my time and my salary learning it.)". When in a small company a guy has a good J2EE working knowledge, there is probably a big chance, that he's the only one who will create and deploy enterprise applications and hopefully transfer all his knowledge to others someday.

I looked only once at Java Enterprise Edition few years ago. Going by the book, and doing few examples, I was able to get started using notepad and standard Java tools. The experience was painful with Corba, RMI, etc. Few days ago, I had a look at JavaEE 5. It looks nice and quite simple. However it seems that most businesses are still using EJB 2.1 and not 3.0.

Tuesday, April 08, 2008

XPontus - Schema completion

Schema completion support has been improved... It was kind of not working in XPontus.
A schema location declaration contains most of the time one or multiple uri references(namespaces and schema locations) with some whitespaces, carriage returns, ...
Now XPontus is able to resolve each schema url locations when they end with .xsd.

Latest screenshot

Sunday, April 06, 2008

Working on XPontus 1.0.0.2

XPontus 1.0.0.2 is coming up. I've fixed few issues this week-end.

General interface problems
Sometimes the file chooser dialog can take a while to load(I only noticed that problem under Windows). That issue has been adressed lots of time to Sun. I don't think it's gonna be fixed definitely any time soon. It seems that the file chooser freezes when you have some zip files on your desktop and it can take up to 10 seconds to show on a Quad Core... Can you tell a user who reports the bug "Damn, you've got lots of zip files on your desktop, clean it up!". That would be funny...

I am not sure that I'll replace the file chooser by VFSJFileChooser. If I don't do it well, it will bloat the program(5 to 6 additional libraries). Letting the user chooser between the default file chooser(better OS integration) and VFSJFileChooser(remote files able) would involve rewriting partially many classes.


Windows vista GUI issues
The tab names are now visible under Windows Vista. The gray rectangle is still visible in the menubar. I could create a special layout for the menubar or make it a java.awt.GridLayout(ugly but no gray rectangle) to solve the issue. The menubar problem is a swing related issue, not XPontus' fault.


The code completion is more usable

Here is the new use case :

Let's say you trigger an element completion by typing "<" in a xsl stylesheet document
  • Suppose you were getting typing xsl:apply-te.
  • That would select xsl:apply-templates in the list
  • Then you change your mind and select xsl:apply-import and press enter
  • The text inserted in the document is xsl:apply-te and it will now be converted to xsl:apply-import instead of xsl:apply-teport

XPath improvements

  • The xpath plugin couldn't display a boolean value or a number value. For example count(//node) would throw an exception and now it returns the number of node found as text.
  • XPath 2.0 support has been added

Architecture

I didn't fix the architecture problems. I will address that matter when the version 1.0.0 of XPontus will be considered as stable. Rewrite things here and there, without breaking too much code.

What's next

I will think about the plugins manager next week and give myself sometimes to do it well. I don't it to be complicated, I just want it to work as well as possible for the next release.

Friday, April 04, 2008

Random talk[SPECIAL]

Nowadays, I tend to think a lot about that Albert Einstein quote
You have to learn the rules of the game. And then you have to play better than anyone else.

It seems to very true in most circumstances...(work, girls, normal life stuff...) Programmer with real skills or programmer which seems to have great skills...?

It's all about that they think you are and what they think you know... That's what a guy told me during my first year at university. The guy didn't know anything but he truely believed that he deserved a great income....

XPontus 1.0.0.2 will be available soon

I'll release a 1.0.0.2 version of XPontus XML Editor sometime in May. I got a copy of Windows Vista installed and I've been doing some bug fixes for Windows Vista.

I'll try to dedicate 3 days to complete and test the plugins manager(Install/Uninstall). I believe it's possible. If I come up with a good strategy, the rest will be easy.

The roadmap for 1.0.02 :
  • Install/Uninstall features in the plugins manager
  • Tab names visibility in Windows Vista
  • Printing isssues on windows vista
  • Fix indentation which is sometimes crashing the editor when the XML is not well-formed
  • VFSJFileChooser integration
  • A minor rewrite of the XSL transformation to specify a transformation type(XQuery for example)
  • file extensions registration to mime types
  • XPath 2.0 plugin
  • file encoding issues
  • Update the user guide and the developer guide

Friday, March 28, 2008

Fixing bugs and design errors in XPontus

I made lots of design errors in the last release of XPontus XML Editor. I didn't have time to rewrite many parts of the application, it would have delayed the 1.0.0.1 release. I'll try to fix all reported bugs for the 1.0.0.2 version. In the next release, I'll switch from Maven to Apache Ivy for dependencies management. Ivy is simple and anyone will be able to open XPontus if the ivyIDE plugin is installed in Eclipse.

I've been thinking about the plugin manager lately. I might finish it sooner than expected.

Lots of people have been asking me if I wrote the plugin framework that XPontus is using. I didn't. Yes, I could have wrote one, but there are more and more plugin frameworks available now. Lots of projects have developed their own plugin framework, made it evolve over the years, and they have been happy with it. As OSGI is more popular among common Java developers, guys are looking at Eclipse equinox implementation or Apache Felix.

Wednesday, March 26, 2008

Multi-platform deployment

Java is multi-platform but Java applications don't behave the same on different OS. I was disappointed to see that XPontus is ugly on Vista. The tab names are in white color, while Windows Vista use translucent windows so... the tab names are almost invisible...

Is it reasonable to build installers for platforms I can't even test on??When a user is telling me, on windows vista I see that... On Vista, multiple pages printing doesn't work... what can I do?? Most of the time I run Linux, I do have Windows installed to perform XPontus tests but I don't really use Windows that often...

Sometimes I have an idea about what a problem is related to, on Vista or Mac but still... I don't have a Mac, I don't have Vista(which seems to be used a lot now)... I can't test on it

So basically I'm running Debian Linux all the time, building installers for OS which can run Java without testing it on those platforms.

I should probably add a notice on the XPontus homepage NEVER BEEN TESTED ON WINDOWS VISTA AND MAC

Tuesday, March 25, 2008

What build tool to use for java development?

People who checkout the XPontus XML Editor's code in the subversion repository expect to open it as a simple Java project in their Java IDE. Well, it's not a simple Java project, it's a Java maven based project.

I use Netbeans and I don't have any problems with Maven. Eclipse and IDEA plugins for Maven are "ALMOST USELESS" compared to what Netbeans provides in terms of usability and flexibility...

I've been more than happy with Maven( manage multiple projects and their dependencies, compile, run , test the applications, generate some websites, etc.)

I do believe that simple Java projects or simple multi-projects ("with few projects as dependencies") don't require an advanced build tool : use your IDE to manage the java classpath or create a simple Ant build file and you're done.

Lately, I've been looking at Apache Ivy as a replacement for Maven to build XPontus. Maven is preventing new members to get started quickly(learn maven, understand its usage in XPontus, etc.). I don't want to have to say all the time something like "Use Netbeans to ease the pain if you never used Maven..."

I don't mind using IVY or Apache Ant when starting a Java project. However if the project is already entirely built using Maven, it sucks to switch to another build system.

Personally, I think about switching toIvy as a regression at the moment:
  • Most IDEs don't have a "fantastic IVY support". It does work but that's it.
  • If most Java developers don't use Maven, do they use Ivy? I don't think so... The learning curve is shorter than Maven but still...
  • Ivy won't do the Maven black magic :-( ... (build some website pages, etc.)
  • Multiproject support?? Will I have to go back to the standard way of creating multi-projects in popular Java IDES?? I'll need to read about that.
The creator of IVY made some intersting comments on IVY vs Maven :
http://xhab.blogspot.com/2006/09/antivy-vs-maven-my-biased-opinion.html

New members of XPontus team will probably be able to use Apache Ivy easily. I guess I'll need to add in capital letters "YOU NEED THE IVY IDE PLUGIN TO OPEN THE PROJECT". I don't really expect lots of people to read it or to read instructions on how to open a XPontus as a Java project. Most developers know how to open a standard Java Project in an IDE, so they'll probably think "yeah must be some newbie stuff..."

Thursday, March 20, 2008

What happen when new users join a team??

As some users are joining XPontus XML Editor project, I have to write quickly a readable and simple documentation.
Who will bother read 500 pages of text before programming? Not me at least!! I have used Hibernate but never read the whole manual. Same goes with other technologies I have used(Apache Cocoon, Wicket, JSF, etc...)

I assumed that most people in the industry use Maven which is not true. I work for a non lucrative company and we use maven a lot. Most people don't use Maven at all, they know about it, they know what some guys have been doing with it, but that's all. Well, I can understand them, why bother with a tool if you feel you don't need it?

I have been using Maven for about 4 years. It has its pros and cons. I think that a simple Java project don't require Maven. It's just overkill.

With XPontus new members, I got to fill the gap between what I know and what others don't:
  • The learning curve of newcomers shouldn't be high.
  • The unfinished developer guide should be done and should almost make it look easy

Basically, I use Maven at 10% of its capabilities. With Apache Maven I do the following steps :
  • Compile and run the program(manage dependencies too)
  • Generate the website
  • Generate the java web start installer and sign the jar files
I could also commit to subversion, deploy the website using SFTP, all that with maven, but I don't.

I noticed that Eclipse has a poor maven support. I use Eclipe time to time but that's it. I switched to Netbeans 2 years ago. Netbeans has great maven support compared to others IDEs.
So when a guy, is telling me "what do I do in Eclipse to do...", in Netbeans it would be a simple click... I might need to switch to Eclipse to come up with good answers as most people are using Eclipse.


I am very excited that some guys are showing interest in XPontus. So what I though was clear in my mind, I have to explain to others and be patient. They have to be patient with themselves too!

XPontus is not like Eclipse, but I don't think average guys could code it in a week. I made some choices which are sometimes good, but sometimes they have limitations. I will rewrite some parts of XPontus when I'll feel that the team has a good understanding of XPontus architecture.

Wednesday, March 19, 2008

XPontus XML Editor 1.0.0.1 is out

I released XPontus XML Editor yersterday night. I didn't release it on monday as planned. I was very tired. I was like don't test like a blind man, don't write bullshit to announce the release, anything can happen if I'm too worn out.

Now is the time to complete the documentation(user guide, developer guide), keep on testing, etc. Can I write a comprehensive developer guide?

I'll take a short break(1 week or less) to look at XPontus from a distance. What did I miss? Is it as stable as I thought it was when releasing? Are there too many bugs? Is it usable? What can be done to improve the architecture....?

Sunday, March 16, 2008

Too many bugs in XPontus

Will I release, should I release now? I've been delaying it forever...

I found so many bugs in XPontus today.... Lots of people have been helping me test the software. There are lots of usability issues. I know that XPontus is not at the same level than XML Spy for example, but still... There are some obvious problems I didn't see. Instead of testing the application all the time by myself, I should ask lots of people to help me test it... Couple of guys have been trying the Java Web Start snapshots, but they don't always fit with the "normal user profile" because :
- They understand or can evaluate the amount of work behind XPontus features and architecture. They may have already encountered the issues that I face.
- They are used to XML technologies

Here's what was done today:
  • I tested few installers. I had a silly mistake in the user settings , preventing the application to start even when the installation was successful.
  • I've been fixing bugs in the schema generator/converter plugin. That plugin takes XML or a Schema/DTD as input and generate a schema(relax ng, dtd or xml schema). Because it can perform generation or conversion between DTD and other schemas, I used the name "schema generator/converter plugin". It can be unintuitive for lots of people.
  • The find/replace dialog was too buggy. I took it from Groovy's code. I replaced it today by some SOAPGui code. I adapted it for usability a little bit. It's not perfect, but it does work!
  • I added a keyboard shortcut to switch between opened documents. "Alt W" will switch between windows(select next document).
  • The XPATH textbox has history support. It remembers up to 10 expressions you type in the textbox. The history is cleared when you close the application. Now you can execute an XPATH expression by pressing the "ENTER" key instead of having to click on the "Evaluate button" all the time.
  • When you click on the "insert comment" button or "insert cdata section" button, the editor get the focus back, no need to click again on the document to be able to insert some text.
I'll release tomorrow and the version will be called 1.0.0pre1-alpha. I added "alpha" to let the users know it's not a mature version. Things don't always work as expected. There are more features, but with features come bugs.

I'll keep on fixing bugs, updating the website and the developer guide until tomorrow.

Friday, March 14, 2008

Under pressure for the new XPontus release

I am getting ready to release XPontus XML Editor next monday : looking here and there, for simple bugs I can fix or forgot to fix, looking at the plugins manager, etc.

Until next monday, I'll be busy to make sure the software is enough usable and stable so I'll be :
  • Creating and testing installers for windows, linux, mac os, bsd, unix
  • Updating the website
  • Coding utility scripts to automate the release announcement in some forums and mailing lists.
  • Fixing bugs time to time
I'll ship all the plugins that I have written and tested enough. So basically, you'll get a big fat and "features-full" version of XPontus. I cannot make a light installer of XPontus as the plugins manager is not enough stable yet. I won't ask all users to open a hidden folder, to copy some zip files and to handle the plugins dependencies logic by themselves.

I'll also have a java webstart version of XPontus but you'll have to install plugins by hand like in the snapshot version. I hope to come with ideas for the plugins manager soon.

I feel happy to release, I've been saying "next week, next month" for too long. I would have wanted to do more for that release but it would have taken few others months to achieve some significant improvements.

Stay tuned!

Tuesday, March 11, 2008

Them "viagra boys", Them "here's the money man"

I didn't know that I would get that much spam on my blog or my sourceforge email account... To those doing that, if you're reading this post :
  • I don't need viagra, I'm in a great shape, still young, still full of energy, no issues...
  • I won some money...??? Well, I could use that cash only if it's real. Trying to lure me is kind of playing with yourself. It's 2008 baby... I guess I haven't seen it all but I think I saw most of it... But why not try? Short answer : it's a waste of your time and mine.

Sunday, March 09, 2008

Releasing next week

Next week, I'll start intensive testing of XPontus XML Editor. I will try to release at the end of the week if possible.

Some issues persist but I think that the snapshot version is better than the stable one. If I keep on coding and testing, writing documentation, creating new plugins, I guess I'll never be able publish a new version of XPontus. I've been planning the upcoming release for at least 8 months. I guess now is the time.

I expect plenty of bug reports, constructive comments, nasty critics, but it's all good, it's all fair. It'll help the development of XPontus XML Editor. If you want to contribute, leave me a message at yveszoundi at users dot sf dot net. I try to take my time to write good software, but I could use some help.

I'll try to find a way to get a hand on a Mac OSX pc to build a dmg installer.

There will be 5 installers : Windows(standard exe), Linux(rpm, tgz, deb), MacOSX(dmg), Unix(sh) and a crosss-platform installer.

Saturday, March 08, 2008

Code completion might be in next release of XPontus!

Code completion seems to be working well enough even though there are few bugs. Here is the complete status of the XML code completion plugin.

Code completion creation
I need to find a way to check if the schema(dtd/xml schema) location of the document is relative or absolute. For the moment, the code completion database is only created if the schema location is absolute.

Intelligent completion
I am now able to get an "almost reliable" suggestion list for code completion based on element insertion location. The suggestion list is sorted by name.

The completion window
It is very buggy. I get"nasty stuff" inserted when I try to select a suggested element. Sometimes, text is inserted twice or more. The completion doesn't have a scroller to view elements if their name are too long.

Completion database caching
I don't know how to do it correctly. I could serialize the completion database for now and store it in a folder.

Thursday, March 06, 2008

Bug fixes day

I will get the list of bugs which were mentionned in earlier in previous versions of XPontus XML Editor and fix them one by one.

In the new version of XPontus the following features are not well working yet :
  • XML validation
  • Code completion(should I remove it?)
  • Grammar caching is not reused by plugins
  • Maybe the save actions

Wednesday, March 05, 2008

XPontus platform developer guide

I started writing the developer guide of XPontus XML Editor today. I'll update it on a daily basis. The developer guide shows how XPontus XML Editor is written and provides a tutorial on how to build and devploy plugins.

I uploaded the initial version of the developer guide on the website. You can download it at the following address : http://xpontus.sourceforge.net/dev_guide.pdf

Tuesday, March 04, 2008

New release at the end of march

The first alpha of XPontus XML Editor 1.0.0 pre1 (End of March)

I've been working hard on XPontus for the last 6 months. It is very different than the previous versions in terms of usability and architecture. Now the software has more features and is more extensible. XPontus has plugins, XPath, an "immature" code completion, etc. Thank you everybody for the bugs reports, the tests and the suggestions. I'll release a new release candidate of 1.0.0 every month until I think that the software is enough stable. The stable version will be called 1.0.0(probably june).

I need to release, so I have to remove incomplete features :
  • The plugins manager(the core of the application) : I was planning to have a complete plugins manager with auto-updates, dependency checking/autoselection, etc. I cannot achieve that goal in a small amount of time. To install a plugin the user must download it for now. I can add a version checking feature to notify the user that a new version is out, but that's it at least for now.
  • Perspectives(Tree Editing, Text editing). Sometimes you want to edit an XML document in a simple window. But when your document is big, you might want to have some drag and drop(elements) features, cut and paste node quickly. I started implement perspectives in xpontus but it involved rewriting lots of code. The big issue with perspectives is how(or how often) you synchronize the text of the source view and other kind of views(Tree view, diagram view for example). I associated persectives to file content types(text/xml, text/xquery, etc.) and file modes(docbook, ant, etc.). When a document needs to be created, the perspective matching the document content type creates the appropriate view to display the document.
So what's the plan?
  • Finish the plugins manager. Find a strategy to uninstall completely a plugin. I cannot do it when the application is running : I can unregister the plugin, but I am not able to delete the plugin installation directory.
  • Ensure that the core features are working well : save, save as , print, validation, etc.
  • Fix previous versions bugs
  • Update code comments and write a developer guide
  • Write the software's architecture manual
  • Update the user's guide
  • Release