Blog Compass Lite 2.0 - personal blog About Me Album Bookmarks

Tuesday, February 28, 2006

Moment of Relax?

Stress handling is definitely an essential skillset everyone should possess. I start to get confused as I don’t know whether this job is too stressful, or it is me who haven’t encountered real stress until now. Or it isn’t really stress at all, just I have to brush up my stress resistance.

Every night when I am back from work, I feel so tired that I don’t want to do anything, well everyone is like that I guess. Sometimes the schedule is so tight that my engine was running at full speed during day time, and I remain that excited after work. Both phenomenons are detrimental to my mental health.

The good thing is, I can feel absorbing knowledge every day just like a sponge soaking water. Maybe I don’t have the freedom to be evangelistic, at least I can be opportunistic to learn from the surroundings. Hopefully my career path can advance along with my effort and enthusiasm. Afterall, learning broad and quick is the only way to yield values and sustainable survival in the technology industry.

Monday, February 27, 2006

ORA-01691: unable to extend lob segment

Oracle Data File Temp Tempfile Datafile.

Problem Scenario:

Storing large binary file to Oracle server as BLOB gives the following error:

[contextRoot] ERROR [ExecuteThread: '10' for queue: 'weblogic.kernel.Default'] ActionExceptionHandler.logException(148) | org.springframework.orm.hibernate3.HibernateJdbcException: JDBC exception on Hibernate data access: Could not execute JDBC batch update; nested exception is java.sql.BatchUpdateException: ORA-01691: unable to extend lob segment TABLESPACE.SYS_LOB0000059665C00009$$ by 8 in tablespace TABLESPACE

java.sql.BatchUpdateException: ORA-01691: unable to extend lob segment TABLESPACE.SYS_LOB0000059665C00009$$ by 8 in tablespace TABLESPACE


The problem was caused by insufficient space to extend a segment for the tablespace. Adding a datafile or adjusting the size of the current datafile of the tablespace can act as short-term solution.

Adding datafile:
ALTER TABLESPACE <tablespace_name> ADD DATAFILE ‘<path_of_datafile>’ SIZE 10M;

Enlarging the current datafile:
ALTER DATABASE DATAFILE ‘<path_to_datafile>’ RESIZE 10M;

(Assuming you are adding a 10MB datafile and resizing the datafile to 10MB respectively.)

You may run the following SQL statement to check the status of various datafiles:
SELECT file_name, tablespace_name, bytes/1024/1024 MB, AUTOEXTENSIBLE FROM dba_data_files;

and use the following SQL to turn on AUTOEXTEND option:

Saturday, February 25, 2006

Any consonance?

Dilbert Comic Strip Archive -

Today's Dilbert Comic

Which item will you pick?

Monday, February 20, 2006

Connectivity to backend database not verified

Problem Scenario:

Application deployed on Weblogic connected to Oracle database. Calling save() action through struts, spring and hibernate tiers gives the following exception:

[@APPNAME@] WARN [ExecuteThread: '10' for queue: 'weblogic.kernel.Default'] SQLErrorCodesFactory.getErrorCodes(232) | Error while extracting database product name - falling back to empty error codes Error while extracting DatabaseMetaData; nested exception is java.sql.SQLException: Closed Connection
java.sql.SQLException: Closed Connection
 at oracle.jdbc.driver.DatabaseError.throwSqlException(
 at oracle.jdbc.driver.DatabaseError.throwSqlException(
 at oracle.jdbc.driver.DatabaseError.throwSqlException(

The following error is thrown when testing the connection pool in Weblogic:

Warning! Connectivity to backend database not verified. This is either because required connection pool attributes "TestConnectionsOnReserve" or "TestConnectionsOnRelease" have not been enabled, or an invalid value has been specified for attribute "TestTableName". Please check the server log for more details..


In Weblogic console, click on the relevant connection pool, select tab configuration -> connection, show Advanced Options. Check the option as shown below:

Test Reserved Connections   Specifies whether WebLogic Server tests a connection before giving it to the client. (You must specify a Test Table Name below.)

Saturday, February 18, 2006

Some Random Thoughts

Just some random thoughts for today:

  • Finally I bought a new headset, very expensive
  • I want to plan for further education, but don’t know what to study at the moment
  • I should find some ways to accumulate my CPD points
  • I need some medical and dental check ups
  • Eventually I have to start paying tax this year
  • I got some great plans in mind but too tired to think about them in detail
  • So tired every night back home, but seems like a waste of time sleeping too early
  • I should have left these personnal thoughts in my own diary.

Wednesday, February 15, 2006

The Headset Hack

Logitech Precision PC Gaming Headset.

What a pity… Last year I have bought this one for watching movie and online conferencing. It was a good one as you can’t feel any pain after wearing it for two hours.

Not until last night did I realize that it was behaving weird. During a movie all the background sound is there but the speech of the main character is missing. I began to suspect there were some broken wires within. Instead of declaring it certified I decided to dissect it first and try to locate the problem. (Just as my daily job of debugging software, it is hardware this time). 


000_0025  000_0024

You can click the above to see them closer in my flickr album. I was able to locate a nearly broken golden wire (I am not sure if it is the cause of problem). Unfortunately I don’t think I can fix it. Kinda fed up with the peripherals getting out of order one by one recently, yet again, it’s time for another replacement.

Tuesday, February 14, 2006

EJB Create failure - EJB Home has no no-arg create() method

Is the reference to the remote EJB marked as lazy-init? If not, maybe you should give that a try.
I recall reading something that preinstantiating may cause problems in such cases. I am not sure if it was about this kind of problem, but possibly it might help marking that remote bean as lazy-init.

EJB Create failure - Spring Framework Support Forums.

Problem Scenario:

When trying to deploy remote EJB with springframework on Weblogic 8.1, the following AspectException was thrown:

[EJB home [ClusterableRemoteRef(-6290068137485291364S:[7001,7001,-1,-1,7001,-1,-1,0,0]:mydomain:myserver [-6290068137485291364S:[7001,7001,-1,-1,7001,-1,-1,0,0]:mydomain:myserver/299])/299] has no no-arg create() method]

While I was pretty sure the interface, Home interface, bean class, applicationContext.xml, ejb-jar.xml and weblogic-ejb-jar.xml are quite properly configured. Most importantly, the no-arg create() method is properly in place.


The seemingly most irrelevant suggestion has solved the problem. In applicationContext.xml, set the <bean> to be lazy-init as follow:

<bean id="beanName" lazy-init="true" class="org.springframework.ejb.access.
  <property name="jndiName" value="jndi-beanName"/>
  <property name="jndiTemplate">
    <ref bean="IICJndiTemplate"/>

For jndiTemplate and introduction of kickstarting remote EJB configuration, please refer to the links listed below:

weblogic-ejb-jar.xml Deployment Descriptor Reference
Zabada Technology: Accessing A Remote EJB With Spring
Chapter 17. Accessing and implementing EJBs
EJB Tutorial

I have spent two and a half days on this issue and eventually the JNDI lookup and EJB creation are both successfully achieved. Subsequently there are runtime errors but at least it was one step forward.

Friday, February 10, 2006

Excluding sub-directory in Ant copy task

Google Groups :

Problem Scenario:

During ant <copy> task, certain sub-directory is to be excluded from the source directory.


Supposed /gen sub-directory is to be excluded, an example is as follow:

<fileset dir="src/dao" excludes="**/gen/**" includes="**/*.xml"/>

/gen/** is used instead of /gen/* as  sub-directories within /gen is represented as ** instead of *

Tuesday, February 07, 2006

Hibernate Forums - View topic - Xdoclet error, Attribute "unique" was already spec

Hibernate Forums - View topic - Xdoclet error, Attribute "unique" was already spec.

Problem scenario:

Using XDoclet 1.2.3 to generate mapping files for hibernate gives the following error messages for tag “many-to-one”:

[hibernatedoclet] (XDocletMain.start 47 ) Running

[hibernatedoclet] Generating mapping file for com.companyname.project.module.ClassName.
[hibernatedoclet] com.companyname.project.module.ClassName
[hibernatedoclet] (XDocletMain.start 53 ) Running
XDoclet failed.
[hibernatedoclet] (XDocletMain.start 54 ) < file
com/companyname/project/module/ClassName.hbm.xml:line 100] Message=[Attribute "unique" was already specified for element "many-to-one".] is not valid according to its DTD or XML Schema. This might be due to some missing tags in your source.>> [hibernatedoclet] org.xml.sax.SAXParseException: Attribute "unique" was alreadyspecified for element "many-to-one".


Given in the above link, it is a reported bug of XDoclet 1.2.3 and was solved in version 1.3 (which is not yet a stable release). Instead of upgrading XDoclet as a whole I amended the hibernate-properties.xdt in xdoclet-hibernate-module-1.2.3.jar as stated in in this page.

Monday, February 06, 2006

Google Groups : Java Web Application

Google Groups : Java Web Application

Google Groups Subscribe to Java Web Application
Browse Archives at

With more than 600 members I think it should be a nice place for discussions.

You may also subscribe to the RSS feed:
Atom 1.0 :
RSS 2.0  :

Sunday, February 05, 2006

Philips 19" SXGA LCD monitor LightFrame? DR

Philips Consumer Products - Product Details.

19Finally I bought this one. Just go to the computer mall and maybe you will be amazed by the price decrease of LCD monitors. Some days before I have posted about my target monitor was 190X5FB for $3680, but today I bought 190X6 at a price of $2940, with a dedcution of supermarket coupons and old monitor trade-in I just need around $2000 for the entire replacement.

Technology can really get people excited, with a new monitor I can have higher resolution and more convenience in my programming work. Better program can, as much as I hope, bring more convenience to other people in the future.

Thursday, February 02, 2006

IBM spearheads AJAX tools at Eclipse

IBM spearheads AJAX tools at Eclipse | Tech News on ZDNet.

Eclipse LogoYet another development for better web applications. There have been quite a number of java libraries abound in the market for AJAX development. The technology makes the products more user-friendly, but certainly not more developer-friendly.

Hopefully a tool based on Eclipse can happen to make AJAX development easier. For more information visit the following links:

EJB Deployment Error under Weblogic

Problem Scenario:

Deploy an EJB under weblogic environment and encountered the following exception:

[Deployer:149033]preparing application iic2 on Server1
[Deployer:149033]failed application iic2 on Server1
[Deployer:149034]An exception occurred for task [Deployer:149026]Deploy application iic2 on Server1.: prepare failed for iic-ejb.jar
Module: iic-ejb.jar Error: Exception preparing module: EJBModule(iic-ejb.jar,status=NEW)
Unable to deploy EJB: iic-ejb.jar from iic-ejb.jar:
Class not found: Lorg/apache/commons/logging/Log;
java.lang.NoClassDefFoundError: Class not found: Lorg/apache/commons/logging/Log;
at weblogic.ejb20.compliance.EJBComplianceChecker.check(
at weblogic.ejb20.compliance.EJBComplianceChecker.checkDeploymentInfo(

In EJB statelessSession, the stateless session bean class must define a single ejbCreate method that takes no parameters.
at weblogic.ejb20.compliance.EJBComplianceChecker.check(
at weblogic.ejb20.compliance.EJBComplianceChecker.checkDeploymentInfo(


Even though there is no error or warning during compilation you must manual add an ejbCreate() method in EJB bean class like the following:

 public void ejbCreate() throws CreateException {
  if (log.isDebugEnabled()) {