Synthetic Life

A historic milestone for humanity was reached when Craig Venture announced last week of his teams creation of Synthetic Life. This is the first cell in the world whose parent is a computer
Although I applaud his effort in this groundbreaking advance in science. I am concerned of patenting as mentioned in a BBC Article: Synthetic life patents ‘damaging’
The video of the announcement is embedded below

MyTop is cool

I was reading High Perfomance Mysql and in that book they mention a tool called Mytop basically it is a top clone for Mysql. Instead of running show full processlist; repetedly on the mysql console just run mytop. Helps you quite a bit.

I had an installing it. I get the foll error

Can’t locate Term/ReadKey.pm in @INC (@INC contains: /usr/lib/perl5/5.6.1/i386-linux /usr/lib/perl5/5.6.1 /usr/lib/perl5/site_perl/5.6.1/i386-linux

This is because it requires TermReadKey Perl Package. Just run

yum install perl-TermReadKey

and you are ready to go.

Jasper Reports: Java Beans as DataSource for Subreports

Today I had a problem. I had a complex bean (Bean which contained other beans) which was being sent as JRBeanCollectionDataSource (JasperReports API version 2.0.2) to a Jasper Report.
This report had to have sub reports for the inner bean. I really could not find out how to pass the bean to the subreport from my main report.
Finally I cracked the nut.
What I did was set the DataSourceExpression in the Subreport element to

<datasourceexpression>
<!–[CDATA[new net.sf.jasperreports.engine.data.JRBeanCollectionDataSource($F{taxBeanList})]]–\>
</datasourceexpression>

Where $F{taxBeanList} is a collection of Tax Beans.
In My subreport I do not have any datasource or queires. This sort of got it working.
I hope to add more to this post in future when I reread it and find some gaps.

Outer Joins Vs Inner Joins

Today I looked into Outer Joins and Inner Joins. I have never used joins (Explicit) always relied on the Implicit joins created by the where clause.

In Outer Joins we have Right Outer Joins and Left Outer Joins and Full Outer Joins. What this basically means is that if there is as foll:

Left Outer Join:
All the records in the first table will be displayed even though there is no corresponding records in the second table.

Right Outer Join:
All the records in the second table will be displayed even though there is no corresponding record in the first table.

Full Outer join.
All the records of both the table will be displayed.

A Good example is given here.
Join (SQL) – Wikipedia, the free encyclopedia

Java Security

I tried it out today. The details of Java Policy which controls what each program can and cannot do.
However there were a some grey areas which I thought I needed to jot down for further reference.

  1. It is best to put the policies in ${user.home}/.java.policy
  2. If 1 is not possible then the confusion lies as to where to put the policy
    1. You could put it in any file as long as you add it to the ${java.home}/lib/security/java.security file.
    2. The entry to be made is policy.url.3=file:/D:/JavaTest/mypolicy (windows)
    3. This works for applet viewer but not mozilla
    4. Java usually downloads the latest version of JRE and installs it. Mozilla uses the latest version so. For Mozilla it is not enough to change ${java.home}/lib/security/java.security file but the /lib/security/java.security of the latest version of JRE.

Tricky CSS

Css can be pretty tricky. In this blog I will keep appending the quirks I notice in CSS.
:
When a Div is floated the div will cut across the containing div if the containing div is smaller than the floated div.
Fix:
Create another inner div at the end of the containing div and give the Css property clear:both. This will force the containing div to be bigger than the inner div’s.

Setting up Subversion

Today I will go about Setting up subversion. I am not going to install subversion since it is already installed by fedora.
The version FC 4 installs is

svn, version 1.1.4 (r13838)
compiled Apr 13 2005, 12:20:50

Copyright (C) 2000-2004 CollabNet.
Subversion is open source software, see http://subversion.tigris.org/
This product includes software developed by CollabNet (http://www.Collab.Net/).

The following repository access (RA) modules are available:

* ra_dav : Module for accessing a repository via WebDAV (DeltaV) protocol.
– handles ‘http’ schema
– handles ‘https’ schema
* ra_local : Module for accessing a repository on local disk.
– handles ‘file’ schema
* ra_svn : Module for accessing a repository using the svn network protocol.
– handles ‘svn’ schema

After doing yum update subversion

svn, version 1.2.3 (r15833)
compiled Aug 26 2005, 03:42:45

Copyright (C) 2000-2005 CollabNet.
Subversion is open source software, see http://subversion.tigris.org/
This product includes software developed by CollabNet (http://www.Collab.Net/).

The following repository access (RA) modules are available:

* ra_dav : Module for accessing a repository via WebDAV (DeltaV) protocol.
– handles ‘http’ scheme
– handles ‘https’ scheme
* ra_svn : Module for accessing a repository using the svn network protocol.
– handles ‘svn’ scheme
* ra_local : Module for accessing a repository on local disk.
– handles ‘file’ scheme

  • Now what I have to do is set up repositories
  • Get a subversion dump from the old system.
  • Import the Subversion Dump