Archive for November 2008

Salutes to Indian Jawans – Mumbai Rescue Operations

lamp

The nation salutes the Indian military, commando force and Mumbai police for their successful rescue operations. If the terrorism is a shame, attacking innocent people is inhuman. This is not the first attack in this year. It is very sad to have a government which is unable to avoid these circumstances. Shame on them.

Many innocent people, jawans and employees lost their lives. Let their soul rest in peace.

Passing Struts values to Javascript

yureka

This another day to get into struts. See, I have an input type as image and onclick function.

<input type=”image” name=”" src=”/teller/images/close.gif” onclick=”del(200);”>

The 200 given as parameter should be passed from struts form bean. Different type of combinations lead to error. finally defining a variable helped as follows.

<bean:define id=”myID” name=”resultI” property=”id”></bean:define>

<html:image src=”/teller/images/close.gif”  onclick=”<%=”del(“+myID+”);” %>”></html:image>

Java MP3 tag reader

veena

I found an interesting library today. Java ID3, http://www.dusbabek.org/~garyd/id3/ a useful library to read the tags of mp3 files. I was doing some experiment with music folder today. It helped me a lot. very simple api and fast rendering of tags. Good one! It has some problems while reading UTF based tags. I have written a mail to the enthusiastic developer. Hope he will get back to me!

Way to Struts 1.2 DataSource

hurray

Today I had downloaded struts 1.2.7 and tried to write an application. (I know I am selecting a bit old.) I configured the datasource in struts. Alas. When I tried to start my server, tomcat 6.0, I got the error saying "java.lang.ClassNotFoundException: org.apache.commons.dbcp.BasicDataSource". With Googling I found struts-legacy.jar need to downloaded and copied to lib folder of Tomcat. (I couldnt get the recent version of struts-legacy. I found something in archive). Happily restarted the server. I saw java.lang.NoClassDefFoundError: org/apache/commons/pool/impl/GenericObjectPool.. oof.. again I need to download commons-dbcp-1.2.2.jar and commons-pool.jar.

My search come to an end :) It is working fine now.

Oracle listener configuration after changing machine name

I was not able to start my oracle instance today. The start and stop server scripts dint show any error, instead they said server started/stopped without any problem. Windows System event log had a error entry saying “The OracleXETNSListener service terminated unexpectedly. It has done this 8 time(s).”Oracle listener issue screenshotwhen I run lsnrctl start I found the issue.D:\Documents and Settings\pandian> lsnrctl startLSNRCTL for 32-bit Windows: Version 10.2.0.1.0 - Production on 23-NOV-2008 01:08:40Copyright (c) 1991, 2005, Oracle. All rights reserved.Starting tnslsnr: please wait...TNSLSNR for 32-bit Windows: Version 10.2.0.1.0 - ProductionSystem parameter file is D:\oraclexe\app\oracle\product\10.2.0\server\network\admin\listener.oraLog messages written to D:\oraclexe\app\oracle\product\10.2.0\server\network\log\listener.logListening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\EXTPROC_FOR_XEipc)))Error listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=acs-59abc34f442)(PORT=1521)))TNS-12545: Connect failed because target host or object does not existTNS-12560: TNS:protocol adapter errorTNS-00515: Connect failed because target host or object does not exist32-bit Windows Error: 1001: Unknown errorListener failed to start. See the error message(s) above...There is the issue. I renamed my host name. So listener is not able to start. I edited the listener.ora found at oraclexe\app\oracle\product\10.2.0\server\NETWORK\ADMIN folder. I changed the host to localhost. It is working now! :)