Saturday, November 20, 2010

Sri Lankan president's 2nd term celebrations

It is a great day for the reigning president Mahinda Rajapaksa as he took oaths to officially start his 2nd term in office. I wish him all the best for his term.

The streets have been lit up and various festivities are organized to commemorate this occasion. I've noticed that this brought some criticism among the people that it's a waste of public funds. I think that is an unfair call. I compare this to a situation where the British monarchy celebrating theta special moments with all grandeur. When this happens we all watch in joy and the British also enjoy it thoroughly. They don't claim it to be a waste of public funds. The head of the state should celebrate special occasions and we as responsible citizens should not be so narrow minded. After all, It is the president elected by a significant majority. BlogBooster-The most productive way for mobile blogging. BlogBooster is a multi-service blog editor for iPhone, Android, WebOs and your desktop

Sunday, November 7, 2010

XACML with the WSO2 product platform

Here is an article written by me on how to configure XACML based fine grained authorization with WSO2 products - http://wso2.org/library/articles/2010/10/using-xacml-fine-grained-authorization-wso2-platform.

It shows how WSO2 provides a way to fully harness the extensibility and the power of XACML with a few clicks and without having to write a single piece of code. Do read it and provide some feedback.

Friday, October 8, 2010

Running rail road tycoon 2 on Linux

If you ran into some problems like me because your on a 64 bit system. Follow these steps:

  1. Install ia32-libs with 'sudo apt-get install ia32-libs'
  2. Run the setup file with 'linux32 bash setup.sh'
That should do the trick.

This knowledge is courtesy of someone I'd like to call Mr. Commando :) - http://www.allportal.net/posts/linux/5109592/%C2%BFLos-juegos-no-funcionan-en-64bits_-Solucion-[Linux].html

Monday, September 20, 2010

Unix/Linux network commands on iPhone terminal

Productivity on the go

Being productive on the go is a concept I could never grasp. This maybe due to me always being nit picky about everything mobile being as convenient as my laptop. Apps gave me a nice compromise. It's as close as I can get to the real thing. The only thing that bothers me is the damn keyboard. Got to get used to that (: Now it's time to sync up my office google app accounts. Hope that won't be too much noise. :S BlogBooster-The most productive way for mobile blogging. BlogBooster is a multi-service blog editor for iPhone, Android, WebOs and your desktop

Sunday, September 19, 2010

Mobile Blogging

Doing it mobile sometimes seems to be unattractive with the limited real estate on the device. But apps seemed to have solved this problem with effective use of the device real estate. One of my main problem to blogging was that I get my ideas on the go. Sometimes I really wish I had someway of putting it down. But typing in a tiny web page was just too annoying. With this blogbooster app I see myself blogging consistently. These apps really do change our lifestyles.BlogBooster-The most productive way for mobile blogging. BlogBooster is a multi-service blog editor for iPhone, Android, WebOs and your desktop

Tuesday, June 15, 2010

Solution to the VNC refresh issue

I think a few of us who tried using VNC to connect to a remote computer running on Ubuntu have faced the refresh problem. Here are the symptoms:
  • You are able to connect to the remote computer with VNC server perfectly.
  • You can even control the remote computer and if you are anywhere close see the changes in the remote computer taking place.
  • BUT WAIT! The changes are not shown in your screen. Everything works but the screen doesn't refresh! How FRUSTRATING! You can't figure it out because you can connect and control the remote computer, it's just the screen that doesn't refresh.
I found a workaround thanks to Ek0nomik's post at http://ubuntuforums.org/showthread.php?t=470306

Follow these steps on the remote computer to solve this issue:
  1. First remove any vnc software (eg: vnc4server) you've installed with the following command :
  2. sudo apt-get remove vnc4server
  3. Secondly, install x11vnc and vnc-common with the following command.
    sudo apt-get install x11vnc vnc-common
  4. Do a reboot just to be on the safe side.
  5. Start the x11vnc with the following command:
  6. x11vnc -display :0 -noxdamage
Now try to connect to this computer as before. Now, hopefully, everything should get refreshed perfectly! A big thanks to Ek0nomik for saving the day.

Monday, June 7, 2010

Tip on Check in client

The check in client is a neat tool to import and export data from the Registry to the File system. I ran into a small issue when working with it on a H2 database.

For some Databases (specially H2) the check-in client of the WSO2 Governance Registry reports a certain error:

"Error in initializing the Realm Service. Some databases like h2, derby in file mode, doesn't allow to have multiple connections. In such case, Please make sure no other is connected to the database. If you running the script in separate place, please make sure you have given absolute paths to the file-based database urls."

This problem by running the check-in client from the GREG_HOME folder. GREG_HOME is the location where the distribution was extracted to.

So now instead of,

GREG_HOME/bin > sh checkin-client.sh co / -u admin -p admin

run the command like this:

GREG_HOME> sh bin/checkin-client.sh co / -u admin -p admin

Hope this work around helps you folks out there who uses this neat tool.

Wednesday, May 12, 2010

Spring Factory Beans explained

If your looking into using Spring for your applications you should definitely check the following link. It's an excellent guide on using Spring Factory Beans, includes use cases as well as an indepth look :

http://blog.arendsen.net/index.php/2005/07/03/using-factorybeans-to-create-the-uncreatable/

Monday, April 26, 2010

Quick Fix for wsdls generated by Axis2 to run on IBM JDK

Some of you may have come across the problem. WSDLs generated from Axis2 has a problem of malfunctioning with the IBM JDK. (I'm not sure whether this occurs with other JDKs or other environments).

There's a quick fix that can be done so that these WSDLs function without a glitch on any JDK.

If a <xs:complex> tag has a name attribute, then replace the <xs:sequence> tag it has it's immediate child by <xs:all>.

ex:

Before fix:
<xs:complexType name="ServiceBean">
<xs:sequence>
<xs:element minOccurs="0" name="id" nillable="true" type="xs:string" />
<xs:element minOccurs="0" name="path" nillable="true" type="xs:string" />
<xs:element maxOccurs="unbounded" minOccurs="0" name="policyBeans" nillable="true" type="ax2100:PolicyBean" />
<xs:element minOccurs="0" name="qName" nillable="true" type="xs:string" />
<xs:element maxOccurs="unbounded" minOccurs="0" name="schemaBeans" nillable="true" type="ax2100:SchemaBean" />
<xs:element maxOccurs="unbounded" minOccurs="0" name="wsdlBeans" nillable="true" type="ax2100:WSDLBean" />
</xs:sequence>
</xs:complexType>

After fix:
<xs:complexType name="ServiceBean">
<xs:all>
<xs:element minOccurs="0" name="id" nillable="true" type="xs:string" />
<xs:element minOccurs="0" name="path" nillable="true" type="xs:string" />
<xs:element maxOccurs="unbounded" minOccurs="0" name="policyBeans" nillable="true" type="ax2100:PolicyBean" />
<xs:element minOccurs="0" name="qName" nillable="true" type="xs:string" />
<xs:element maxOccurs="unbounded" minOccurs="0" name="schemaBeans" nillable="true" type="ax2100:SchemaBean" />
<xs:element maxOccurs="unbounded" minOccurs="0" name="wsdlBeans" nillable="true" type="ax2100:WSDLBean" />
</xs:all>
</xs:complexType>


Now you're wsdl should work on any jdk/server without a problem. Do leave a comment if this works. :)

Friday, March 26, 2010

Super online JSON tester!

For everyone who's doing some crazy Javascript, JSON tools would definitely be handy.

This online JSON parser (http://json.parser.online.fr/) saved me hours of tedious work of figuring out the inconsistencies of my JSON data.

I recommend it as a super tool to anyone who's going to work with JSON.