Neat features from Firefox add-ons


Firefox has an extensible framework that enables developers to write add-ons, which provide several great features such as blocking ads, scrambling keystrokes, and blocking intrusion.

An excerpt from TechNewsWorld:

One big helper for surfing comfort and speed is provided through an add-on called “Adblock Plus.” As the name suggests, it eliminates ad banners. During installation, the user can subscribe to filter lists that are then automatically updated to recognize and block new domain Over 800,000 High Quality Domains Available For Your Business. Click Here. addresses used to transport ads.

The article talks about several more add-ons such as:

  • NoScript : Add-on that checks the running of scripts, which prevents Trojans and malware from sneaking in.
  • TrackMeNot: This one sends random queries to search engines to prevent the user’s query from being differentiated.
  • KeyScrambler: To encrypt key information and prevent key loggers from accessing keystroke data.
  • Bookmark Synchroniser: To organize bookmarks among several computers by loading them onto a server.
  • Foxy Tunes: A tool-bar to control music players.

Many more add-ons can be found at the Firefox Web site.


J2EE pattern oriented framework (Jt)

Jt1.8 has been released. Jt is a lightweight pattern oriented framework for the rapid implementation of J2EE applications. Jt has been utilized in several large mission critical systems. Jt is based on a messaging design pattern. Jt also implements many well-known patterns including Data Access Objects (DAO), GoF design patterns and J2EE patterns. This framework supports several BPM and J2EE technologies including jBPM, Struts, Java Server Pages (JSPs), AJAX, JDBC, Hibernate, Enterprise Java Beans (EJB), JMS, JavaMail, XML and Web Services.

Main Features:

Jt1.8 features integration with the Hibernate implementation of Data Access Objects (DAO). A Jt adapter provides a transparent interface between the Jt framework and Hibernate DAOs.

Additional features include:

• Jt is a pattern oriented framework. Jt implements many well-known design patterns. This includes Data Access Objects (DAO), adapters for several J2EE APIs, Gang of Four (GoF) design patterns and J2EE patterns.

• Jt implements a messaging pattern/API: framework objects are able to interchange information and perform computations by sending, receiving and processing messages. The messaging paradigm provides additional encapsulation and software simplicity. The messaging API implemented by the Jt Framework is very simple: very few calls are required to create, manipulate and destroy messages and objects. On the other hand, this API is very powerful.

• Integration with the MVC (Model View Controller) design pattern and Ajax. Universal Jt components and adapters provide a transparent interface between the Jt framework API and these technologies. The business logic (controller piece) can be implemented using Jt framework components and/or BPM business processes.

• Support for the XML API via XML helpers. Framework objects can be converted to/from the XML format.

• Built-in logging/debugging capabilities. Messages between framework objects are automatically logged. This simplifies the debugging and testing tasks.

Jt’s online documentation can be found at

New Java Framework for Cross-Platform Installers



openInstaller , a brand new project on , provides “a free and comprehensive next generation installer framework”. Talking about the background of the project, Sun Microsystem’s Vadiraj Deshpande, one of its principal engineers, says: “openInstaller came into existence to address some of the issues that we were facing during the previous version of the Java Enterprise System.”


Read full post here

Serializing Java Objects with XStream – A Short tutorial


This is a very quick introduction to XStream. Skim read it to get an idea of how simple it is to convert objects to XML and back again. I am sure you’ll have questions afterwards.XStream

Create Classes to be serialized:

Here are a couple of simple classes. XStream can convert instances of these to XML and back again.

public class Person{

private String firstName;
private String lastName;
private PhoneNumber phone;
private PhoneNumber fax;

public Person(String firstName, String lastName){




public String getFirstName(){ return firstName; }

public void setFirstName(String firstName){ this.firstName = firstName; }

public String getLastName(){ return lastName; }

public void setLastName(String lastName){ this.lastName = lastName; }

public PhoneNumber getPhone(){ return phone; }

public void setPhone(PhoneNumber phone){ = phone; }

public PhoneNumber getFax(){ return fax; }

public void setFax(PhoneNumber fax){ this.fax = fax; }



public class PhoneNumber{

private int code; private String number;

public PhoneNumber(int code, String number){

this.code = code; this.number = number;




Note: Notice that the fields are private. XStream doesn’t care about the visibility of the fields. No getters or setters are needed. Also, XStream does not limit you to having a default constructor.

Initializing XStream:

To use XStream, simply instantiate the XStream class.

XStream xstream = new XStream();

You require xstream-[version].jar and xpp3-[version].jar in the classpath. XPP3 is a very fast XML pull-parser implementation. If you do not want to include this dependency, you can use the standard JAXP DOM parser instead.

XStream xstream = new XStream(new DomDriver());

Now, to make the XML outputted by the XStream more concise, you can create aliases for your custom class names to XML element names. This is only type of mapping required to use XStream and also this is optional.

xstream.alias(“person”, Person.class);

xstream.alias(“phone-number”, PhoneNumber.class);

Note: This step is optional. Without it XStream would work fine, but the XML element names would contain the fully qualified name of each class (including package) which would bulk up the XML a bit.


Serializing an object to XML:

Lets write a test class, in which we create a Person class and populate its fields:

Person sam = new Person(”Syed”, “Aslam”);

sam.setPhone(new PhoneNumber(95, “253265″));

sam.setFax(new PhoneNumber(95, “423140″));

Now, to convert it to XML, all you have to do is make a call to XStream:

XStream xstream = new XStream();String xml = xstream.toXML(sam);

And that’s it. The test class would look like this:


import com.thoughtworks.xstream.*;

public class XStreamTest{

public static void main(String[] args){

XStream xstream = new XStream();

Person sam = new Person(”Syed”, “Aslam”);

sam.setPhone(new PhoneNumber(95, “253265″));

sam.setFax(new PhoneNumber(95, “423140″));

String xml = xstream.toXML(sam);





The resulting XML would look like this:


It’s that simple. Look how clean the XML is.

Deserializing an object back from XML

To reconstruct an object, purely from XML:

Person newPerson = (Person) xstream.fromXML(xml);






Microsoft Releases New JDBC Driver for SQLServer


Microsoft released an update to its freely distributable JDBC driver for the SQLServer database engine. Microsoft released a new version of the JDBC driver for its SQLServer database engine. The new driver provides a Type 4 JDBC interface to the latest version of SQLServer, and supports JDK releases above 1.4:

“In this release we re-architected the communication stack resulting in significant performance and scalability improvements, as well as minimizing the driver memory footprint usage, especially with multiple active connections and result sets. These enhancements are most visible when the “responseBuffering=adaptive” connection property is used. The driver now supports SQL Server SSL encryption as part of our continual commitment to security.”

Original article here.

What do you think of SQLServer as a database for enterprise Java applications?

Server-side scripting


Server-side scripting is a web server technology in which a user’s request is fulfilled by running a script directly on the web server to generate dynamic HTML pages. It is usually used to provide interactive web sites that interface to databases or other data stores. This is different from client-side scripting where scripts are run by the viewing web browser, usually in JavaScript. The primary advantage to server-side scripting is the ability to highly customize the response based on the user’s requirements, access rights, or queries into data stores.


VisualVM : A New Visual JVM Tool

Note that a new JVM tool has been made available. VisualVM is a tool that provides detailed information about Java applications while they are running. It provides an intuitive graphical user interface that allows you to easily see information about multiple Java applications. Java applications are run by a Java Virtual Machine, or VM.

Visual VM

If you are running Java SE 6 – VisualVM provides an overview, system properties, monitor, profiler, thread dump, heap dump and more. The name VisualVM comes from the fact that VisualVM provides VM information visually. VisualVM is a project which you can get an article providing a visual tour here. You can download it from here.