Analytic module in latest SmartClient releases provides charting feature, but its not available under LGPL license. In this post we will discuss about how to integrate third party javascript charting API with smartclient.

Following are the key objectives:

Component Based Approach: Charting feature must be designed using component based approach, so that charting component can be reused at several places. We will call this component as 'SmartChart' in rest of this post.

Data integration: Smartclient's DataSource provides data integration capability which can be plugged in at ease. Smartchart uses datasource for integrating with server.

Third Party Charting JS API: We are using DOJO charting API for now, but later we will try to integrate other opensource charting APIs.

We have been using JManage in our development environment since few months and wefound it to be an excellent web based JMX client for managing and monitoring Java applications. It is opensourced, the code is very well written, easy to understand and change.

Few notable features that it provides

It can send Email Alerts when your application goes down or you need to watch a MBean attribute.

Dojo fails in its online documentation. JQuery seems to do a much better job with documentation and examples. Dojo is must more robust than JQuery. Development using JQuery is much faster than as compared to Dojo. JQuery is an extenstion of Javascript and programming model is the same. While Dojo is a kinda toolkit and learning programming model needs an extra effort.

This post is about, how to generate Cobertura Coverage Reports with some insides of Cobertura. In the later section we will discuss steps to report generation for a  web application deployed on Tomcat container.

Code Coverage

Code coverage is a measure used in software testing. It describes the degree to which the source code of a program has been tested. It is a form of testing that inspects the code directly and is therefore a form of white box testing.

Overview

In our application we used RBAC approach for implementing the authorization in our security data layer. User roles and permissions were modeled as separate entities. We had a requirement of providing sub-roles to a given role, with which a user assigned super role will be permitted for permissions associated to that particular role and all sub roles as well.

To store this hierarchical data we modeled a rolesubrole entity which stores subroles associated to a given role.

About JOSSO:

JOSSO (Java Open Single Sign-On) is an open source J2EE and Spring-based SSO infrastructure aimed to provide a solution for centralized, platform neutral, user authentication and authorization. The Single Sign-On Gateway is responsible of the centralized authentication of web users using the configured authentication scheme and credential store. We used JOSSO( version 1.6) at the time of integration.

Problem Statement

This problem is in context with development of GUI using Smartclient from Isomorphic. We were using RestDataSource which is used to post form data on the server. At server end, request processing service was taking too long (~6 minutes) to process the data. We were overriding transform response method to post process the response. And expected it to get called, but after 6 minutes when server is done processing, transform response method was never called.

Comparison of different open source cache implementations:

I have explored and analyzed a few open source cache implementations (Oscache, Ehcache , Jboss Cache and JCS) and I found that there are various features which are common to all of them while there are a few features that specifically characterize a particular implementation. For instance, JBoss provides Tree Cache implementation that gives the user liberty to organize data, to be stored in cache.

Problem

We have a jsp page that has a HTML table and an applet.

Both components have the same source of data which is an MBean on the server. Table data is same as the data used by the applet for plotting a graph. Both components refresh themselves after an interval of time.

Since data is already fetched by the table we needed a way to avoid the call that is made by the applet.

Solution

If we set the table data in a html element (of type hidden) and somehow our applet is able to access it.

While exporting a Remote Object into JVM's RMI system using UnicastRemoteObject#exportObject(remoteObj); do not forget to unexport the remote object when you have finished and want to shutdown the VM. This is because RMI keeps tracks of objects being exported ; it spawns a Reaper Thread that tracks the live objects exported into RMI. It is non-daemon thread that keeps alive the VM until all objects have been unexported from JRMP.
Loading